4 2009-09-25 Nick Kledzik <kledzik@apple.com>
6 <rdar://problem/7200658> 'unknown DWARF EH encoding' message logged to console with clang-50
11 2009-07-28 Nick Kledzik <kledzik@apple.com>
13 <rdar://problem/7099040> make better no-PIC branch island to thumb1
14 * Add kBranchIslandNoPicToThumb1 as 8-byte no-PIC island
17 2009-07-20 Nick Kledzik <kledzik@apple.com>
19 <rdar://problem/7075703> section$start$__DATA$__bss can fail
20 * In SectionBoundaryAtom constructor make __bss and __common be zero-fill
21 * In AtomSorter, make sure end kSectionEnd sort after kTentativeDefinition
22 * unit-tests/test-cases/section-labels-zero-fill: add test cases
27 2009-07-13 Nick Kledzik <kledzik@apple.com>
29 <rdar://problem/7049478> empty dylib should have subtype from command line
30 In Linker::writeOutput() for ARM, set initial fCurrentCpuConstraint to be command line subtype
33 2009-07-09 Nick Kledzik <kledzik@apple.com>
35 <rdar://problem/7043920> crash when using -dead_strip and LTO with unresolved intrinsic
36 * In Linker::optimize() after final deadStripResolve() call checkUndefines() one last time
39 2009-07-09 Nick Kledzik <kledzik@apple.com>
41 <rdar://problem/7043256> ld64 can not find a -e entry point from an archive
42 * src/ld/ld.cpp: add searchArchives parameter to entryPoint() for use by deadStripResolve()
43 * unit-tests/test-cases/dead_strip-entry-archive: added test case
46 2009-07-08 Nick Kledzik <kledzik@apple.com>
48 <rdar://problem/6702217> __objc_classrefs section could be coalesced
49 * In machoReader, chop up __objc_classrefs section into pointer size atoms
50 and make each weak and hidden with a name based on its target name.
53 2009-06-26 Nick Kledzik <kledzik@apple.com>
55 <rdar://problem/6715874> "ld: symbol dyld_stub_binding_helper not defined" for xnu built with clang for x86_64
56 * Fix relocationNeededInFinalLinkedImage() to say weak-defs don't require indirection in static executables
57 * Added unit-tests/test-cases/static-executable-weak-defines
60 2009-06-26 Nick Kledzik <kledzik@apple.com>
62 <rdar://problem/7012016> Error msg for missing -init symbol is misleading/unclear
63 * In Linker::checkUndefines() check all ways that the command line could add an undefined
64 and then search for close matches/typos.
67 2009-06-25 Nick Kledzik <kledzik@apple.com>
69 <rdar://problem/5725900> We need ld-symbol-moving-symbols for ARM/Embedded
70 * In mach_o::dylib::Reader::addSymbol() parse iPhoneOS version strings
71 * Update IPhoneVersionMin
74 2009-06-25 Nick Kledzik <kledzik@apple.com>
76 <rdar://problem/6933931> Linker makes subtype-zero file from empty subtype-nonzero file.
77 * In Linker::writeOutput() set inittal fCurrentCpuConstraint to be command line subtype
78 * Fix fArchitectureName to have arm sub-types
81 2009-06-24 Nick Kledzik <kledzik@apple.com>
83 <rdar://problem/6955021> ld should do a better job of reporting attempts to link directories
84 * In Options::buildSearchPaths() sanity check -L and -F options
87 2009-06-24 Nick Kledzik <kledzik@apple.com>
89 <rdar://problem/6974647> better error message when libLTO.dylib not loadable
90 * in Linker::createReader() provide detail error messages
93 ----- Tagged ld64-96.10
95 2009-08-31 Nick Kledzik <kledzik@apple.com>
97 <rdar://problem/7182988> empty dylib has been __mh_dylib_header n_sect
98 * rework patch to use MinimalTextAtom to ensure there is always a __text section
101 ----- Tagged ld64-96.9
103 2009-08-31 Nick Kledzik <kledzik@apple.com>
105 <rdar://problem/7182988> empty dylib has been __mh_dylib_header n_sect
106 * suppress __mh_dylib_header from symbol table if there is no __text section
108 Implicitly add dyld_stub_binder to libSystem.dylib so iPhone clients can build
109 against SnowLeopard libSystem.dylib.
112 ----- Tagged ld64-96.8
114 2009-08-30 Nick Kledzik <kledzik@apple.com>
116 <rdar://problem/7049478> SWB: gcc-5577.1 fails to build vecLib
119 ----- Tagged ld64-96.7
121 2009-08-29 Nick Kledzik <kledzik@apple.com>
123 <rdar://problem/6933931> Linker makes subtype-zero file from empty subtype-nonzero file.
126 ----- Tagged ld64-96.6
128 2009-07-30 Nick Kledzik <kledzik@apple.com>
130 <rdar://problem/7103437> ld: ldr 12-bit displacement out of range on SnowLeopard with gcc-5648
131 * in Section::Section() set fIndex to ensure __symbolstub1 sorts to end of __TEXT segment
134 ----- Tagged ld64-96.5
136 2009-07-28 Nick Kledzik <kledzik@apple.com>
138 <rdar://problem/7073626> Thumb mode compilation isn't working on 3.1 beta 2
139 * Fix instructions used in kBranchIslandToThumb1 case
142 ----- Tagged ld64-96.4
144 2009-06-22 Nick Kledzik <kledzik@apple.com>
146 <rdar://problem/6992387> platform linker should use platform ld_classic
147 * Fix Options::gotoClassicLinker() to use realpath()s
150 2009-06-22 Nick Kledzik <kledzik@apple.com>
152 * Fix Options::setIPhoneVersionMin() to handle 2.x through 9.x
155 ----- Tagged ld64-96.3
157 2009-06-17 Nick Kledzik <kledzik@apple.com>
159 * Change section sorting so that arm and ppc stub section is immediately after __text section
162 2009-06-17 Nick Kledzik <kledzik@apple.com>
164 <rdar://problem/6975041> don't use no-PIC stubs in any dylibs - it might conflict with codesigning
165 * In StubAtom<arm>::StubAtom() don't use kStubNoPIC for OS dylibs
168 ----- Tagged ld64-96.2
170 2009-06-09 Nick Kledzik <kledzik@apple.com>
172 * Back out page-cross branch work around
175 ----- Tagged ld64-96.1
177 2009-06-05 Nick Kledzik <kledzik@apple.com>
179 * Fix "duplicate symbol cache-line-crossing-stub" error by giving placeholders unique names
180 * Fix -pie by allowing relocs in x86 stubs and stub helpers
185 2009-06-04 Nick Kledzik <kledzik@apple.com>
187 * Darwin x86_64 static codegen is really dynamic code gen, so use LTO_CODEGEN_PIC_MODEL_DYNAMIC
190 2009-06-03 Nick Kledzik <kledzik@apple.com>
192 <rdar://problem/6945923> use lto_codegen_set_assembler_path()
195 2009-06-03 Nick Kledzik <kledzik@apple.com>
197 * In src/ld/LTOReader.hpp, move where -save-temps .bc file is saved to be after code model set
200 2009-06-01 Nick Kledzik <kledzik@apple.com>
202 <rdar://problem/6806033> Link Time Optimization error with 'dead code strip' + hidden symbol
203 * scan newAtoms returned from optimize() looking for ones already in the symbol table
204 * add test case unit-tests/test-cases/lto-dead_strip-all-hidden
207 2009-05-19 Nick Kledzik <kledzik@apple.com>
209 <rdar://problem/6881656> make dyld stubs smaller/faster
210 * Add new addSynthesizedAtoms() method to Writer, called before atoms are sorted
211 * Fix throwf() and warning() to check printf types
212 * Add arm::kPointerDiff12 to support fast arm stubs
213 * Add new ContentType values for stubs and (non)lazy pointers
214 * Add new variant of arm stub this is one instruction
217 2009-05-13 Nick Kledzik <kledzik@apple.com>
219 * ld64.xcodeproj/project.pbxproj: add warnings to dyldinfo target
220 * src/other/dyldinfo.cpp: support classic LINKEDIT format
223 2009-05-12 Nick Kledzik <kledzik@apple.com>
225 * src/ld/MachOWriterExecutable.hpp: fix optimization to skip branch islands with ARM bl instructions
228 2009-05-12 Nick Kledzik <kledzik@apple.com>
230 <rdar://problem/6836647> creation of __unwind_info section can fail if hundreds of functions cannot be compact encoded
231 * src/ld/MachOWriterExecutable.hpp: fix when to make regular vs compressed pages
234 2009-05-08 Nick Kledzik <kledzik@apple.com>
236 * src/ld/ld.cpp: enhance -save-temps to also write out optimized bitcode file
239 2009-05-08 Nick Kledzik <kledzik@apple.com>
241 * src/ld/ld.cpp: fix -order_file_statistics to print each symbol not found and correct total
244 2009-05-08 Nick Kledzik <kledzik@apple.com>
246 <rdar://problem/6870522> linker should be able to coalesce UTF16 strings
247 * src/ld/MachOReaderRelocatable.hpp: parse __ustring section by labels but synthesize an
248 atom name based on the content. Leverage for __cfstring section
249 * unit-tests/test-cases/cfstring-utf16: update test case
252 2009-05-07 Nick Kledzik <kledzik@apple.com>
254 * src/ld/MachOWriterExecutable.hpp: put branch islands further apart if there is no thumb code
257 2009-05-07 Nick Kledzik <kledzik@apple.com>
259 <rdar://problem/6331300> LINKEDIT optimizations for iPhone
260 * src/ld/ObjectFile.h: Recognize iPhoneOS 3.1
261 * src/ld/Options.cpp: iPhoneOS 3.1 => use compressed LINKEDIT
262 * src/ld/MachOWriterExecutable.hpp: support generating compressed LINKEDIT for arm
265 2009-05-04 Nick Kledzik <kledzik@apple.com>
267 <rdar://problem/5716715> Add linker support for ARM branch islands
268 <rdar://problem/5253691> Add labels to linker synthesized jump islands
269 * src/ld/MachOWriterExecutable.hpp: reworked BranchIslandAtom and createBranchIslands to support arm/thumb
270 * src/ld/ObjectFile.h: added kBranchIsland
271 * unit-tests/test-cases/branch-islands: updated test case to check arm/thumb
274 2009-04-30 Nick Kledzik <kledzik@apple.com>
276 * src/ld/Options.cpp: fix custom stack base address for arm
279 2009-04-30 Nick Kledzik <kledzik@apple.com>
281 <rdar://problem/6818272> likely incorrect warning about common symbols
282 * src/ld/Options.cpp: ignore LD_WARN_COMMONS in -r mode
285 ----- Tagged ld64-95.8.3
287 2009-03-31 Nick Kledzik <kledzik@apple.com>
289 <rdar://problem/6719270> ld might set MH_WEAK_DEFINES when it should not
290 * src/ld/MachOWriterExecutable.hpp: rescan fRegularDefAtomsThatOverrideADylibsWeakDef and only consider global ones
293 ----- Tagged ld64-95.8.2
295 2009-03-18 Nick Kledzik <kledzik@apple.com>
297 * src/ld/MachOReaderRelocatable.hpp: back out -force_cpusubtype_ALL changes
300 ----- Tagged ld64-95.8.1
302 2009-03-17 Nick Kledzik <kledzik@apple.com>
304 <rdar://problem/6578416> -dead_strip inhibits weak coalescing in no_dead_strip section
305 * src/ld/ld.cpp: in markDead() remove from fLiveRootAtoms
308 2009-03-17 Nick Kledzik <kledzik@apple.com>
310 <rdar://problem/6671072> libgcc fails to build in with ld64-95.8
311 * src/ld/MachOReaderRelocatable.hpp: interpret CPU_SUBTYPE_ARM_ALL as CPU_SUBTYPE_ARM_V4T
312 * src/ld/Options.cpp: interept -force_cpusubtype_ALL as -arch armv4t
315 ----- Tagged ld64-95.8
317 2009-02-09 Nick Kledzik <kledzik@apple.com>
319 <rdar://problem/6569316> ld64-95.7 crashes building Foundation-678.39 in side build
320 * src/ld/MachOReaderRelocatable.hpp: handle a zero length section with a label before __cstring section
323 ----- Tagged ld64-95.7
325 2009-02-06 Nick Kledzik <kledzik@apple.com>
327 * src/ld/ObjectFile.h: make fAddCompactUnwindEncoding false by default
330 2009-02-06 Nick Kledzik <kledzik@apple.com>
332 <rdar://problem/6537210> ER: add linker option to zero fill empty DATA sections on disk
333 * src/ld/Options.cpp: add support for -no_zero_fill_sections
334 * src/ld/MachOReaderRelocatable.hpp: isZeroFill() is only true if fOptimizeZeroFill
335 * doc/man/man1/ld.1: document -no_zero_fill_sections
336 * unit-tests/test-cases/no_zero_fill_sections: add test case
339 2009-02-05 Nick Kledzik <kledzik@apple.com>
341 <rdar://problem/6497366> label getting resolved to the wrong address.
342 * src/ld/MachOWriterExecutable.hpp: add findAtomAndOffsetForSection() and use it to disambiguate
343 * unit-tests/test-cases/label-on-end-of-section: added test case
346 2009-01-27 Nick Kledzik <kledzik@apple.com>
348 <rdar://problem/6517393> Warn -force_cpusubtype_ALL is not supported
349 * src/ld/Options.cpp: warn if fForceSubtypeAll and fArchitecture is CPU_TYPE_ARM
352 ----- Tagged ld64-95.6
354 2009-01-25 Nick Kledzik <kledzik@apple.com>
356 <rdar://problem/6439020> Add support for section start/end labels
357 * src/ld/ObjectFile.h: add kSectionStart and kSectionEnd
358 * src/ld/MachOReaderRelocatable.hpp: create SectionBoundaryAtoms as needed
359 * src/ld/ld.cpp: sort SectionBoundaryAtoms correctly
360 * src/ld/MachOWriterExecutable.hpp: allow all relocations in preload images
363 ----- Tagged ld64-95.5
365 2009-01-15 Nick Kledzik <kledzik@apple.com>
367 * src/ld/MachOWriterExecutable.hpp: in hasPageCrossingBranches() ignore branches preceeded by a branch
370 ----- Tagged ld64-95.4
372 2009-01-15 Nick Kledzik <kledzik@apple.com>
374 * src/ld/Options.cpp: handle -kext and -r the same for fPreventPageCrossingBranches
377 ----- Tagged ld64-95.3
379 2009-01-14 Nick Kledzik <kledzik@apple.com>
381 <rdar://problem/6497574> linker should alter layout to prevent armv7 page crossing branches
382 * src/ld/Options.cpp: set fPreventPageCrossingBranches
383 * src/ld/MachOWriterExecutable.hpp: adjust layout of __text so there are not page crossing branches
384 * src/ld/MachOReaderRelocatable.hpp: support new ARM_THUMB_32BIT_BRANCH reloce
387 ----- Tagged ld64-95.2.10
389 2009-04-02 Nick Kledzik <kledzik@apple.com>
391 <rdar://problem/6805002> corrupt metaclass entry in dynamic library
392 * src/ld/ld.cpp: change Section constructor to copy segment and section names
395 ----- Tagged ld64-95.2.9
397 2009-04-02 Nick Kledzik <kledzik@apple.com>
399 <rdar://problem/6744267> Update ld64 for new triples introduced in 6654669 to support ARM LLVM
400 * src/ld/LTOReader.hpp: change "arm-" to "arm" so matching works for new triples
403 ----- Tagged ld64-95.2.8
405 2009-03-24 Nick Kledzik <kledzik@apple.com>
407 <rdar://problem/6713931> anonymous functions have the compact unwind info computed wrong
408 * ld/MachOReaderRelocatable.hpp: use new compact unwind function in AnonymousAtom
411 ----- Tagged ld64-95.2.7
413 2009-03-11 Nick Kledzik <kledzik@apple.com>
415 <rdar://problem/6670421> AddressBook incorrectly gets _objc_msgSend from WebKit
416 * src/ld/MachOReaderDylib.hpp: fix processIndirectLibraries() to not force a private re-export of a dylib
417 that is already explictly or implicitly linked.
418 * unit-tests/test-cases/re-export-optimizations-indirect: add test case
421 2009-03-10 Nick Kledzik <kledzik@apple.com>
423 <rdar://problem/6665853> dyld weak linking optimization leaves some symbols unbound
424 * src/ld/MachOWriterExecutable.hpp: be sure to create bind entry for a reference
425 to a symbol in a dylib that is a weak definition
426 * unit-tests/test-cases/coalesce_weak_def_in_dylib: add test case
429 2009-03-10 Nick Kledzik <kledzik@apple.com>
431 <rdar://problem/6666004> many OS i386 OS dylibs still have __IMPORT segment
432 * ld/MachOReaderRelocatable.hpp: moved where __IMPORT/__pointer is changed to __DATA/__nl_symbol_ptr
433 * unit-tests/test-cases/stripped-indirect-symbol-table: updated to test for this problem
436 ----- Tagged ld64-95.2.6
438 2009-02-27 Nick Kledzik <kledzik@apple.com>
440 <rdar://problem/6633530> ld might set MH_WEAK_DEFINES when it should not
441 * src/ld/MachOWriterExecutable.hpp: only consider atoms in fRegularDefAtomsThatOverrideADylibsWeakDef
442 that will be exported when computing MH_WEAK_DEFINES
443 * unit-tests/test-cases/operator-new: updated to reproduce issue
446 ----- Tagged ld64-95.2.5
448 2009-02-24 Nick Kledzik <kledzik@apple.com>
450 <rdar://problem/6605499> x86_64 obj-c runtime confused when static lib is stripped
451 * src/ld/MachOWriterExecutable.hpp: in setLocalNlist() don't use 'l' labels for x86_64 strings
452 * unit-tests/test-cases/objc-literal-pointers-strip: added test case
455 ----- Tagged ld64-95.2.4
457 2009-02-23 Nick Kledzik <kledzik@apple.com>
459 * src/ld/MachOReaderRelocatable.hpp: ignore ARM_THUMB_32BIT_BRANCH relocs
462 2009-02-18 Nick Kledzik <kledzik@apple.com>
464 <rdar://problem/6583555> Writer<A>::symbolIndex() uses a linear search and does not scale
465 * src/ld/MachOWriterExecutable.hpp: build a std::map so symbolIndex() scales better
468 2009-02-18 Nick Kledzik <kledzik@apple.com>
470 <rdar://problem/6312070> Use new compact encodings that handle all register permutations
471 * src/ld/Architectures.hpp: add kSectionOffset24
472 * src/ld/ObjectFile.h: add getFDE()
473 * src/ld/MachOReaderRelocatable.hpp: use new libunwind functions to get new compact encoding
474 * src/ld/MachOWriterExecutable.hpp: use new compact encoding which includes offset in dwarf if needed
475 * src/other/unwinddump.cpp: update unwinddump output to display register save set
478 2009-02-16 Nick Kledzik <kledzik@apple.com>
480 <rdar://problem/6511619> runtime error with bundle for 10.5 that has weak external symols
481 * src/ld/ld.cpp: fix hybrid (10.5) compressed linkedit info for data pointing to weak definitions
484 2009-02-15 Nick Kledzik <kledzik@apple.com>
486 <rdar://problem/6583757> i386 relocation error with negative offsets from local labels
487 * src/ld/MachOReaderRelocatable.hpp: handle when base addr of scattered relocation does not point to a label
488 * unit-tests/test-cases/relocs-neg-from-local: add test case
491 2009-02-12 Nick Kledzik <kledzik@apple.com>
493 <rdar://problem/6578360> -dead_strip inhibits weak coalescing in no_dead_strip section
494 * src/ld/ld.cpp: remove atoms coalesced away from fLiveRootAtoms
495 * unit-tests/test-cases/dead_strip-weak-coalesce: added test case
498 2009-02-12 Nick Kledzik <kledzik@apple.com>
500 <rdar://problem/6581809> x86_64 weak_import broken for initialized data
501 * src/ld/MachOReaderRelocatable.hpp: use isWeakImportSymbol() in Reader<x86_64>::addRelocReference()
502 * src/other/dyldinfo.cpp: update to display weak_import attribute
503 * unit-tests/test-cases/weak_import: updated test case
506 2009-02-06 Nick Kledzik <kledzik@apple.com>
508 <rdar://problem/6541812> ld parsing of __eh_frame unwind information is slow
509 * src/ld/MachOReaderRelocatable.hpp: build a std::map of all __eh_frame relocations for x86_64
512 ----- Tagged ld64-95.2.3
514 2009-02-04 Nick Kledzik <kledzik@apple.com>
516 <rdar://problem/6545406> ld: warning: can't add line info to anonymous symbol
517 * src/ld/MachOReaderRelocatable.hpp: don't warn about line info in dyld stubs
520 ----- Tagged ld64-95.2.2
522 2009-02-02 Nick Kledzik <kledzik@apple.com>
524 <rdar://problem/6548268> ld -r does not preserve the N_NO_DEAD_STRIP bit
525 * src/ld/MachOWriterExecutable.hpp: set N_NO_DEAD_STRIP based on dontDeadStrip()
526 * unit-tests/test-cases/dead_strip-r_symbol_desc: added test case
529 ----- Tagged ld64-95.2.1
531 ----- Tagged ld64-95.2.10
533 2009-04-02 Nick Kledzik <kledzik@apple.com>
535 <rdar://problem/6805002> corrupt metaclass entry in dynamic library
536 * src/ld/ld.cpp: change Section constructor to copy segment and section names
539 ----- Tagged ld64-95.2.9
541 2009-04-02 Nick Kledzik <kledzik@apple.com>
543 <rdar://problem/6744267> Update ld64 for new triples introduced in 6654669 to support ARM LLVM
544 * src/ld/LTOReader.hpp: change "arm-" to "arm" so matching works for new triples
547 ----- Tagged ld64-95.2.8
549 2009-03-24 Nick Kledzik <kledzik@apple.com>
551 <rdar://problem/6713931> anonymous functions have the compact unwind info computed wrong
552 * ld/MachOReaderRelocatable.hpp: use new compact unwind function in AnonymousAtom
555 ----- Tagged ld64-95.2.7
557 2009-03-11 Nick Kledzik <kledzik@apple.com>
559 <rdar://problem/6670421> AddressBook incorrectly gets _objc_msgSend from WebKit
560 * src/ld/MachOReaderDylib.hpp: fix processIndirectLibraries() to not force a private re-export of a dylib
561 that is already explictly or implicitly linked.
562 * unit-tests/test-cases/re-export-optimizations-indirect: add test case
565 2009-03-10 Nick Kledzik <kledzik@apple.com>
567 <rdar://problem/6665853> dyld weak linking optimization leaves some symbols unbound
568 * src/ld/MachOWriterExecutable.hpp: be sure to create bind entry for a reference
569 to a symbol in a dylib that is a weak definition
570 * unit-tests/test-cases/coalesce_weak_def_in_dylib: add test case
573 2009-03-10 Nick Kledzik <kledzik@apple.com>
575 <rdar://problem/6666004> many OS i386 OS dylibs still have __IMPORT segment
576 * ld/MachOReaderRelocatable.hpp: moved where __IMPORT/__pointer is changed to __DATA/__nl_symbol_ptr
577 * unit-tests/test-cases/stripped-indirect-symbol-table: updated to test for this problem
580 ----- Tagged ld64-95.2.6
582 2009-02-27 Nick Kledzik <kledzik@apple.com>
584 <rdar://problem/6633530> ld might set MH_WEAK_DEFINES when it should not
585 * src/ld/MachOWriterExecutable.hpp: only consider atoms in fRegularDefAtomsThatOverrideADylibsWeakDef
586 that will be exported when computing MH_WEAK_DEFINES
587 * unit-tests/test-cases/operator-new: updated to reproduce issue
590 ----- Tagged ld64-95.2.5
592 2009-02-24 Nick Kledzik <kledzik@apple.com>
594 <rdar://problem/6605499> x86_64 obj-c runtime confused when static lib is stripped
595 * src/ld/MachOWriterExecutable.hpp: in setLocalNlist() don't use 'l' labels for x86_64 strings
596 * unit-tests/test-cases/objc-literal-pointers-strip: added test case
599 ----- Tagged ld64-95.2.4
601 2009-02-23 Nick Kledzik <kledzik@apple.com>
603 * src/ld/MachOReaderRelocatable.hpp: ignore ARM_THUMB_32BIT_BRANCH relocs
606 2009-02-18 Nick Kledzik <kledzik@apple.com>
608 <rdar://problem/6583555> Writer<A>::symbolIndex() uses a linear search and does not scale
609 * src/ld/MachOWriterExecutable.hpp: build a std::map so symbolIndex() scales better
612 2009-02-18 Nick Kledzik <kledzik@apple.com>
614 <rdar://problem/6312070> Use new compact encodings that handle all register permutations
615 * src/ld/Architectures.hpp: add kSectionOffset24
616 * src/ld/ObjectFile.h: add getFDE()
617 * src/ld/MachOReaderRelocatable.hpp: use new libunwind functions to get new compact encoding
618 * src/ld/MachOWriterExecutable.hpp: use new compact encoding which includes offset in dwarf if needed
619 * src/other/unwinddump.cpp: update unwinddump output to display register save set
622 2009-02-16 Nick Kledzik <kledzik@apple.com>
624 <rdar://problem/6511619> runtime error with bundle for 10.5 that has weak external symols
625 * src/ld/ld.cpp: fix hybrid (10.5) compressed linkedit info for data pointing to weak definitions
628 2009-02-15 Nick Kledzik <kledzik@apple.com>
630 <rdar://problem/6583757> i386 relocation error with negative offsets from local labels
631 * src/ld/MachOReaderRelocatable.hpp: handle when base addr of scattered relocation does not point to a label
632 * unit-tests/test-cases/relocs-neg-from-local: add test case
635 2009-02-12 Nick Kledzik <kledzik@apple.com>
637 <rdar://problem/6578360> -dead_strip inhibits weak coalescing in no_dead_strip section
638 * src/ld/ld.cpp: remove atoms coalesced away from fLiveRootAtoms
639 * unit-tests/test-cases/dead_strip-weak-coalesce: added test case
642 2009-02-12 Nick Kledzik <kledzik@apple.com>
644 <rdar://problem/6581809> x86_64 weak_import broken for initialized data
645 * src/ld/MachOReaderRelocatable.hpp: use isWeakImportSymbol() in Reader<x86_64>::addRelocReference()
646 * src/other/dyldinfo.cpp: update to display weak_import attribute
647 * unit-tests/test-cases/weak_import: updated test case
650 2009-02-06 Nick Kledzik <kledzik@apple.com>
652 <rdar://problem/6541812> ld parsing of __eh_frame unwind information is slow
653 * src/ld/MachOReaderRelocatable.hpp: build a std::map of all __eh_frame relocations for x86_64
656 ----- Tagged ld64-95.2.3
658 2009-02-04 Nick Kledzik <kledzik@apple.com>
660 <rdar://problem/6545406> ld: warning: can't add line info to anonymous symbol
661 * src/ld/MachOReaderRelocatable.hpp: don't warn about line info in dyld stubs
664 ----- Tagged ld64-95.2.2
666 2009-02-02 Nick Kledzik <kledzik@apple.com>
668 <rdar://problem/6548268> ld -r does not preserve the N_NO_DEAD_STRIP bit
669 * src/ld/MachOWriterExecutable.hpp: set N_NO_DEAD_STRIP based on dontDeadStrip()
670 * unit-tests/test-cases/dead_strip-r_symbol_desc: added test case
673 ----- Tagged ld64-95.2.1
675 2009-01-29 Nick Kledzik <kledzik@apple.com>
677 <rdar://problem/6532377> gcc DejaGnu failure: building longcall/dylib library
678 * src/ld/MachOWriterExecutable.hpp: if no __DATA sections insert non-lazy pointers at end of __TEXT segment
679 * unit-tests/test-cases/no-data-bundle: added test case
682 ----- Tagged ld64-95.2
684 2009-01-06 Nick Kledzik <kledzik@apple.com>
686 <rdar://problem/6476760> strip -S fails with "new trie is larger than original"
687 * src/other/PruneTrie.cpp: don't align trie more than original trie was aligned
690 ----- Tagged ld64-95.1
692 2008-12-21 Nick Kledzik <kledzik@apple.com>
694 * src/ld/MachOWriterExecutable.hpp: in new linkedit format, make sure only exported symbols
695 make it into weak binding info
700 2008-12-18 Nick Kledzik <kledzik@apple.com>
702 * src/ld/Options.cpp: move check for fSharedRegionEligible until fPrebind has stabilized
705 2008-12-18 Nick Kledzik <kledzik@apple.com>
707 <rdar://problem/6305021> Generate new compressed LINKEDIT when targeting 10.6
708 * src/ld/Options.cpp: turn on compressed LINKEDIT by default
711 ----- Tagged ld64-94.1
713 2008-12-16 Nick Kledzik <kledzik@apple.com>
715 * src/ld/Options.cpp: Fix -F handling in buildSearchPaths()
720 2008-12-15 Nick Kledzik <kledzik@apple.com>
722 * doc/man/man1/ld.1: document new options
725 2008-12-15 Nick Kledzik <kledzik@apple.com>
727 <rdar://problem/6134468> linker should enforce all .o files have same sub-type, and ignore sub-type of dylibs
728 * doc/man/man1/ld.1: update man page about -allow_sub_type_mismatches
729 * src/ld/ld.cpp: call validFile() with new arguments
730 * src/ld/MachOReaderRelocatable.hpp: add new arguments to validFile()
731 * src/ld/Options.cpp: Support LD_ALLOW_CPU_SUBTYPE_MISMATCHES and -allow_sub_type_mismatches
734 2008-12-15 Nick Kledzik <kledzik@apple.com>
736 <rdar://problem/6438270> -syslibroot should skip standard search paths not in the SDK
737 * src/ld/Options.cpp: in buildSearchPaths() if an SDK is specified don't add
738 standard search paths not in the SDK.
741 2008-12-15 Nick Kledzik <kledzik@apple.com>
743 <rdar://problem/6406609> ld: remove "can't make compact unwind encoding" warning
744 * src/ld/ObjectFile.h: add fWarnCompactUnwind
745 * src/ld/Options.cpp: -warn_compact_unwind --> fWarnCompactUnwind
746 * src/ld/MachOReaderRelocatable.hpp: test fWarnCompactUnwind before warning
749 2008-12-15 Nick Kledzik <kledzik@apple.com>
751 <rdar://problem/6442926> Add dtrace usdt support for arm to ld64
752 * src/ld/MachOWriterExecutable.hpp: handle arm::kDtraceIsEnabledSite
753 * unit-tests/test-cases/dtrace-static-probes: use is-enabled in test case
758 2008-12-11 Nick Kledzik <kledzik@apple.com>
760 * src/ld/ObjectFile.h: add fIPhoneVersionMin to track min iPhoneOS version
761 * src/ld/Options.cpp: use fIPhoneVersionMin
764 2008-12-11 Nick Kledzik <kledzik@apple.com>
766 <rdar://problem/6431277> non-lazy pointer to non-global tentative definition encoded wrong
767 * src/ld/MachOWriterExecutable.hpp: don't use INDIRECT_SYMBOL_LOCAL for tentative definitions
768 * unit-tests/test-cases/non-lazy-r: updated test case
771 2008-12-11 Nick Kledzik <kledzik@apple.com>
773 <rdar://problem/6437667> kernel fails to boot when ld64 used for intermediate ld -r step
774 * src/ld/MachOWriterExecutable.hpp: in -r mode when generating a scattered sect-diff reloc for
775 i386/arm, special case when from target is not the atom
776 the relocation is in.
777 * unit-tests/test-cases/relocs-asm: update test case
780 2008-12-11 Nick Kledzik <kledzik@apple.com>
782 * src/ld/ld.cpp: handle new __program_vars section
783 * src/ld/MachOWriterExecutable.hpp: handle inserting synthesized sections when there is no __dyld section
786 2008-12-11 Nick Kledzik <kledzik@apple.com>
788 * src/ld/MachOReaderRelocatable.hpp: Fix getDescription() to work when direct reference is to anonymous atom
791 2008-12-10 Nick Kledzik <kledzik@apple.com>
793 * src/ld/Options.cpp: enable LD_FORCE_NO_PREBIND to be used with arm
796 2008-12-10 Nick Kledzik <kledzik@apple.com>
798 <rdar://problem/6258169> Developer tool to print the new compressed LINKEDIT information
799 * src/other/dyldinfo.cpp: fix typo in usage()
802 2008-12-05 Nick Kledzik <kledzik@apple.com>
804 <rdar://problem/6308882> SnowLeopard kernel should compile warning free
805 * src/ld/MachOReaderRelocatable.hpp: correct parse two global labels at end of section and make one an alias
806 * unit-tests/test-cases/end-label: update test case
809 2008-12-04 Nick Kledzik <kledzik@apple.com>
811 <rdar://problem/6342245> Better warning than "PPC_RELOC_JBSR should not be using an external relocation"
812 * src/ld/MachOReaderRelocatable.hpp: issue warning with .o path if it was compiled with -mlong-branch
815 2008-12-04 Nick Kledzik <kledzik@apple.com>
817 <rdar://problem/6408832> linker should not map __pointers -> __nl_symbol_ptr unless actually making new LINKEDIT
818 * src/ld/ObjectFile.h: add fMakeCompressedDyldInfo for readers to see
819 * src/ld/Options.cpp: set fMakeCompressedDyldInfo for readers to see
820 * src/ld/MachOReaderRelocatable.hpp: check fMakeCompressedDyldInfo
823 2008-12-02 Nick Kledzik <kledzik@apple.com>
825 * src/ld/debugline.c: fix error handling in line_open()
828 2008-11-26 Nick Kledzik <kledzik@apple.com>
830 <rdar://problem/6401277> vtable with thumb entries broke after ld -r
831 * src/ld/MachOReaderRelocatable.hpp: if target of reloc is thumb, mask thumb bit off addend
832 * unit-tests/test-cases/thumb-pointer: added test case
835 2008-11-26 Nick Kledzik <kledzik@apple.com>
837 * src/ld/Option.cpp: Fix how crashreporterBuffer is created to not miss some arguments
840 2008-11-24 Nick Kledzik <kledzik@apple.com>
842 <rdar://problem/6398605> Security.framework has some duplicate FDEs for some functions
843 * src/ld/ld.cpp: remove fDeadAtoms from fLiveAtoms when there are weak atoms overriden by late loads
844 * unit-tests/test-cases/dead_strip-archive-eh: added test case
849 2008-11-21 Nick Kledzik <kledzik@apple.com>
851 * src/ld/MachOReaderDylib.hpp: if export_size is zero, no need to parse trie
852 * src/abstraction/MachOTrie.hpp: gracefully handle empty trie
855 2008-11-21 Nick Kledzik <kledzik@apple.com>
857 <rdar://problem/6257854> strip(1) support for new compressed LINKEDIT information
858 * ld64.xcodeproj/project.pbxproj: build and install new libprunetrie.a
859 * src/other/prune_trie.h: added
860 * src/other/PruneTrie.cpp: implements prune_trie()
863 2008-11-21 Nick Kledzik <kledzik@apple.com>
865 * src/ld/ld.cpp: if an export file is used and all weak symbols are masked, don't set WEAK_DEFINES
866 * unit-tests/test-cases/weak-def-flag: added test case
869 2008-11-20 Nick Kledzik <kledzik@apple.com>
871 <rdar://problem/6305021> Generate new compressed LINKEDIT when targeting 10.6
872 * src/ld/MachOWriterExecutable.hpp: support generating new compressed format
873 * src/ld/MachOReaderRelocatable.hpp: new compress format implies non-lazy pointers in __DATA for i386
874 * src/ld/MachOReaderDylib.hpp: support linking aginst new format
875 * src/ld/Options.cpp: suppport -exported_symbols_order and -no_compact_linkedit
876 * src/ld/ld.cpp: track which atoms have weak counter parts in dylibs
877 * src/other/dyldinfo.cpp: added tool to display new LINKEDIT format
878 * ld64.xcodeproj/project.pbxproj: add dyldinfo tool
879 * unit-tests/*: lots of fixes to work with new format
882 2008-11-20 Nick Kledzik <kledzik@apple.com>
884 <rdar://problem/6389316> ld64 should preserve N_WEAK_REF when linking MH_KEXT_BUNDLEs
885 * src/ld/MachOWriterExecutable.hpp: set up fWeakImportMap in synthesizeKextGOT()
888 2008-11-19 Nick Kledzik <kledzik@apple.com>
890 <rdar://problem/6342406> VideoToolbox.framework has bad __TEXT.__eh_frame info
891 * src/ld/Options.cpp: add -no_eh_labels option for use with -r
892 * src/ld/MachOWriterExecutable.hpp: generate correct x86_64 labeless relocs in -r mode
893 * src/ld/MachOReaderRelocatable.hpp: now ignore all labels and relocations in
894 __TEXT/__eh_frame section and rely on getCFIs() from libunwind
895 * unit-tests/test-cases/eh-coalescing-no-labels: add test case
898 2008-11-19 Nick Kledzik <kledzik@apple.com>
900 <rdar://problem/6378110> LTO doesn't like dtrace symbols
901 * src/ld/LTOReader.hpp: ignore __dtrace_probe undefines in bitcode files
904 2008-11-14 Nick Kledzik <kledzik@apple.com>
906 * src/abstraction/MachOFileAbstraction.hpp: fix to work with 10.5 headers
911 2008-11-07 Nick Kledzik <kledzik@apple.com>
913 Remove COMPACT_UNWIND_SUPPORT conditionalizing
916 2008-11-06 Nick Kledzik <kledzik@apple.com>
918 Reorganize source layout. ld sources are now in "ld",
919 and other tools are in "other".
922 2008-11-05 Nick Kledzik <kledzik@apple.com>
924 * ld64.xcodeproj/project.pbxproj: start installing unwinddump tool
925 * src/UnwindDump.cpp: support -arch option
926 * doc/man/man1/unwinddump.1: create man page
929 2008-11-05 Nick Kledzik <kledzik@apple.com>
931 <rdar://problem/6337329> linker should put cpusubtype in n_sect field of nlist entry for N_OSO debug note entries
932 * src/ld.cpp: in synthesizeDebugNotes() set other field of OSO to be subtype
935 2008-11-05 Nick Kledzik <kledzik@apple.com>
937 <rdar://problem/3738966> Need a linker option to load all objects from one library
938 * src/Options.cpp: support -force_load option
939 * src/ArchiveReader.hpp: Add fForceLoad ivar
940 * doc/man/man1/ld.1: update man page with -force_load option
941 * unit-tests/test-cases/archive-force-load: add test case
944 2008-11-05 Nick Kledzik <kledzik@apple.com>
946 <rdar://problem/6308882> Dtrace Probe Warnings: SnowLeopard kernel should compile warning free
947 * src/ld.cpp: don't generate GSYM stabs for old style __dtrace_probe
948 * src/MachOReaderRelocatable.hpp: fix test for deciding if a symbol is an alias
951 2008-11-04 Nick Kledzik <kledzik@apple.com>
953 <rdar://problem/6294378> ADOBE: XCODE: ld: duplicate typeinfo in executable
954 * src/ld.cpp: in dead-strip mode, record overriden symbols and later rebind all uses
955 * unit-tests/test-cases/dead_strip-archive-weak: add test case
958 2008-11-03 Nick Kledzik <kledzik@apple.com>
960 <rdar://problem/6254202> support increased branch range in Thumb-2
961 * src/MachOReaderRelocatable.hpp: handle full branch range in addRelocReference()
962 * unit-tests/test-cases/branch-distance: added test case
964 2008-10-31 Devang Patel <dpatel@apple.com>
966 <rdar://problem/5725712> Sqlite 3.5.4 built with lvm-gcc-4.2 -O4 fails regression test
967 * src/LTOReader.hpp: Use real atom scope when real atom is available.
968 Preserve globals while optimizing an executable.
970 2008-10-30 Nick Kledzik <kledzik@apple.com>
972 * src/MachOReaderRelocatable.hpp: support all encodings in getEncodedP()
977 2008-10-30 Nick Kledzik <kledzik@apple.com>
979 <rdar://problem/6327584> icc has dwarf unwind info that is different than gcc
980 * src/MachOReaderRelocatable.hpp: support more encodings in getEncodedP()
983 2008-10-23 Nick Kledzik <kledzik@apple.com>
985 <rdar://problem/6088653> build ld64 for x86_64
986 * ld64.xcodeproj/project.pbxproj: add X86_64 to valid archs
989 2008-10-23 Nick Kledzik <kledzik@apple.com>
991 * ld64.xcodeproj/project.pbxproj: use generated @$(DERIVED_FILE_DIR)/linker_opts for extra
992 linker options. This allows linker to be built if LTO headers and libs are missing.
995 2008-10-23 Nick Kledzik <kledzik@apple.com>
997 <rdar://problem/6273617> Linker warning not shown in the Xcode build log
998 * src/Options.cpp: add colon to format string in warning()
1001 ----- Tagged ld64-89.3
1003 2008-10-24 Nick Kledzik <kledzik@apple.com>
1005 <rdar://problem/6317985> ld64-89 broke TOT OpenGL libProgrammability x86_64 build
1006 * src/MachOReaderRelocatable.hpp: add cast in getEncodedP()
1009 ----- Tagged ld64-89.2
1011 2008-10-23 Nick Kledzik <kledzik@apple.com>
1013 <rdar://problem/6312895> SnowLeopard: Libsystem built with ld64-89.1 causes crashes
1014 * src/MachOReaderRelocatable.hpp: when FDE information causes __text atom to be split, make the
1015 atoms follow-on pairs.
1018 ----- Tagged ld64-89.1
1020 2008-10-22 Nick Kledzik <kledzik@apple.com>
1022 * src/MachOReaderRelocatable.hpp: for x86_64 __eh_frame force direct references
1025 2008-10-21 Nick Kledzik <kledzik@apple.com>
1027 * src/ObjectDump.cpp: Use getContentType() to see if content type is a cstring
1030 ----- Tagged ld64-89
1032 2008-10-21 Nick Kledzik <kledzik@apple.com>
1034 <rdar://problem/6253171> 10A180 with QT-1119 roots: iTunes and QuickTime cannot play back purchased videos
1035 <rdar://problem/5950453> linker should not need .eh labels
1036 * src/MachOWriterExecutable.hpp: use kCFIType to set section attributes
1037 * src/MachOReaderRelocatable.hpp: use libunwind's CFITuple to parse __eh_frame content
1038 * src/ld.cpp: Add adjustScope() phase instead of demoting scope within symboltable.add()
1039 * unit-tests/test-cases/eh-stripped-symbols: added test case
1042 ----- Tagged ld64-88.1
1044 2008-10-16 Nick Kledzik <kledzik@apple.com>
1046 * src/MachOReaderRelocatable.hpp: Fix uses of COMPACT_UNWIND_SUPPORT
1047 * src/MachOWriterExecutable.hpp: Fix uses of COMPACT_UNWIND_SUPPORT
1050 2008-09-30 Nick Kledzik <kledzik@apple.com>
1052 <rdar://problem/6255983> OBJC2: Reorder __DATA,__objc_* sections by writedness
1053 * src/ld.cpp: change sorting order of Sections
1056 2008-09-29 Nick Kledzik <kledzik@apple.com>
1058 <rdar://problem/6159479> Executable produced by XCode 3.2 on 10.6 crashes on 10.3.9
1059 * src/MachOWriterExecutable.hpp: set objc_module_info_addr field of module table
1062 ----- Tagged ld64-88
1064 2008-09-25 Nick Kledzik <kledzik@apple.com>
1066 <rdar://problem/5935708> kexts need to be built as MH_BUNDLE mach-o files
1067 * src/ld.cpp: use getUndefinedProxyAtom() with kKextBundle
1068 * src/MachOFileAbstraction.hpp: add MH_KEXT_BUNDLE
1069 * src/Options.cpp: support -kext for all architectures
1070 * src/MachOWriterExecutable.hpp: support kKextBundle to make a bundle like kext
1071 * unit-tests/test-cases/kext-basic: added test case
1074 2008-09-25 Nick Kledzik <kledzik@apple.com>
1076 <rdar://problem/6052546> ld invoking wrong ld_classic
1077 * src/Options.cpp: first look for ld_classic relative to ld itself
1080 2008-09-25 Nick Kledzik <kledzik@apple.com>
1082 <rdar://problem/5855588> ld fails to link references from 32 bit code into 64 bit code
1083 <rdar://problem/5955200> Desired 32-bit absolute relocation
1084 * src/Architectures.hpp: add x86_64::kPointer32
1085 * src/MachOReaderRelocatable.hpp: support X86_64_RELOC_UNSIGNED with length=2
1086 * src/MachOWriterExecutable.hpp: support x86_64::kPointer32
1087 * unit-tests/test-cases/relocs-asm/relocs-asm.s: added 32-bit pointer tests
1090 2008-09-25 Nick Kledzik <kledzik@apple.com>
1092 <rdar://problem/6075323> Should be able to mark dylibs as auto-dead-dylib-strip
1093 * src/Options.h: add fMarkDeadStrippableDylib
1094 * src/MachOReaderDylib.hpp: check MH_DEAD_STRIPPABLE_DYLIB
1095 * src/ObjectFile.h: add deadStrippable()
1096 * src/MachOFileAbstraction.hpp: add MH_DEAD_STRIPPABLE_DYLIB
1097 * src/Options.cpp: support -mark_dead_strippable_dylib
1098 * src/MachOWriterExecutable.hpp: test reader->deadStrippable(), set MH_DEAD_STRIPPABLE_DYLIB
1099 * doc/man/man1/ld.1: update man page
1100 * unit-tests/test-cases/dead_strippable_dylib: added test case
1103 2008-09-25 Nick Kledzik <kledzik@apple.com>
1105 <rdar://problem/6197601> ER: Add -seg_page_size option
1106 * src/Options.cpp: add -seg_page_size option
1107 * src/MachOWriterExecutable.hpp: use new page size info when laying out segments
1108 * doc/man/man1/ld.1: update man page
1111 2008-09-24 Nick Kledzik <kledzik@apple.com>
1113 <rdar://problem/5798786> -arch_errors_fatal not working
1114 * src/ld.cpp: check fOptions.errorOnOtherArchFiles()
1115 * src/Options.cpp: turn -arch_errors_fatal into fOptions.errorOnOtherArchFiles()
1118 2008-09-24 Nick Kledzik <kledzik@apple.com>
1120 <rdar://problem/6161215> CrashTracer: [USER] 1 crash in ld at ld: 0x5ce02
1121 * src/ld.cpp: abort if resolve() finds an unresolved reference, rather than allow a future crash
1124 2008-09-24 Nick Kledzik <kledzik@apple.com>
1126 <rdar://problem/6157989> linker crashes linking X86-64 with -fwritable-strings
1127 * src/MachOReaderRelocatable.hpp: handle unbound cfstring references
1128 * unit-tests/test-cases/cfstring-coalesce: update test case
1131 2008-09-24 Nick Kledzik <kledzik@apple.com>
1133 <rdar://problem/6213035> ld64: bl out of range (-17147704 max is +/-16M) on ppc
1134 * src/MachOWriterExecutable.hpp: tweak branch island regions to be every 14MB instead of 15MB
1137 2008-09-24 Nick Kledzik <kledzik@apple.com>
1139 <rdar://problem/5907981> -filelist fails with comma in path
1140 * src/Options.cpp: in loadFileList() first try without special comma meaning
1141 * unit-tests/test-cases/filelist/Makefile: update test case
1144 2008-09-23 Nick Kledzik <kledzik@apple.com>
1146 <rdar://problem/6203068> nop not used when aligning functions in -r mode
1147 * src/MachOWriterExecutable.hpp: change check for when to pad with nops to not test segment's name
1150 2008-09-23 Nick Kledzik <kledzik@apple.com>
1152 <rdar://problem/6238329> "-pie can only be used when linking a main executable" should be a warning, not an error
1153 * src/Options.cpp: make -pie on a dylib or bundle be a warning instead of an error
1156 2008-09-23 Nick Kledzik <kledzik@apple.com>
1158 * src/MachOReaderRelocatable.hpp: add warning if dwarf cannot be encoded as compact unwind
1161 2008-09-18 Nick Kledzik <kledzik@apple.com>
1163 * src/LTOReader.hpp: re-enable use of lto_codegen_debug_options()
1166 2008-09-16 Nick Kledzik <kledzik@apple.com>
1168 <rdar://problem/6219054> ld does not always set S_CSTRING_LITERALS on __TEXT,__cstring
1169 * src/MachOReaderRelocatable.hpp: add getContentType() to SymbolAtom
1170 * src/MachOWriterExecutable.hpp: for x86_64 don't override named cstrings with LC* name
1173 2008-09-10 Nick Kledzik <kledzik@apple.com>
1175 * Options.cpp: add __crashreporter_info__ to communicate command line to crash reporter
1176 * ld64.xcodeproj/project.pbxproj: leave local symbols in ld to provide better crash reports
1179 2008-09-08 Nick Kledzik <kledzik@apple.com>
1181 <rdar://problem/6126637> 161569 GCC 4.2 - breakpoints no longer work for a large number of functions
1182 * src/MachOReaderRelocatable.hpp: support DW_FORM_strp out-of-line strings when parsing line table
1185 2008-09-02 Nick Kledzik <kledzik@apple.com>
1187 * src/MachOReaderRelocatable.hpp: fix compact unwind personality for dyld and -slow_stubs
1190 2008-08-29 Nick Kledzik <kledzik@apple.com>
1192 <rdar://problem/6186838> -weak_library no longer forces uses to be weak_import
1193 * src/MachOWriterExecutable.hpp: use fWeakImport on dylib to force proxy atoms into fWeakImportMap
1194 * unit-tests/test-cases/weak_import-force: added test case
1197 2008-08-29 Nick Kledzik <kledzik@apple.com>
1199 <rdar://problem/6061558> linker should order __DATA segment to reduce dyld dirtied pages
1200 * src/Options.cpp: add fOrderData and support -no_data_order
1201 * src/ld.cpp: modify tweakLayout() to sort atoms with relocations to start of __data section
1204 2008-08-27 Nick Kledzik <kledzik@apple.com>
1206 * src/Options.cpp: back out <rdar://problem/6174493>
1209 ----- Tagged ld64-87.5
1211 2008-08-26 Nick Kledzik <kledzik@apple.com>
1213 <rdar://problem/6174493> some projects show _Unwind_Resume coming from libSystem.B.dylib
1214 * src/Options.cpp: swap any early symlinks to libSystem with libgcc_s
1217 ----- Tagged ld64-87.4
1219 2008-08-25 Nick Kledzik <kledzik@apple.com>
1221 <rdar://problem/6174493> some projects show _Unwind_Resume coming from libSystem.B.dylib
1222 * src/Options.cpp: swap any early libSystem with libgcc_s
1225 2008-08-15 Nick Kledzik <kledzik@apple.com>
1227 <rdar://problem/5898326> Unable to build ppc debug builds (linker out of range error)
1228 * src/MachOWriterExecutable.hpp: in addPPCBranchIslands() look ahead so large atoms don't push out branch islands
1231 ----- Tagged ld64-87.3.1
1233 2008-09-08 Nick Kledzik <kledzik@apple.com>
1235 <rdar://problem/6204202> i386 dylibs have incorrect personality pointers when put in dyld shared cache
1236 * src/MachOWriterExecutable.hpp: in addCrossSegmentRef() handle kImageOffset32 to __IMPORT segment
1239 ----- Tagged ld64-87.3
1241 2008-08-09 Nick Kledzik <kledzik@apple.com>
1243 <rdar://problem/6125381> work around compiler gcc_except_table alignment
1244 * src/ObjectFile.h: change getLSDA() to return a reference instead of an atom
1245 * src/MachOReaderRelocatable.hpp: special case __eh_frame 64-bit pointer diff relocations
1246 * src/MachOWriterExecutable.hpp: track lsda offset when creating __unwind_info section
1247 * src/UnwindDump.cpp: log when LDSA content does not start with 0xFF
1249 ----- Tagged ld64-87.2
1251 2008-08-07 Nick Kledzik <kledzik@apple.com>
1253 <rdar://problem/6131559> 10A141: libuwind falls back to dwarf and makes whole system super slow
1254 * src/MachOWriterExecutable.hpp: Fix sign extension bug with x86_64::kPointerDiff24
1255 * src/UnwindDump.cpp: warn about mangled LSDA entries when dumping unwind section
1258 ----- Tagged ld64-87.1
1260 2008-08-03 Nick Kledzik <kledzik@apple.com>
1262 * src/LTOReader.hpp: Don't use lto_codegen_debug_options until newer libLTO.dylib is available
1265 ----- Tagged ld64-87
1267 2008-07-21 Nick Kledzik <kledzik@apple.com>
1269 * src/Options.cpp: Always set fAutoOrderInitializers=false for dyld
1272 2008-07-21 Nick Kledzik <kledzik@apple.com>
1274 * src/MachOWriterExecutable.hpp: fix when regular vs compressed __unwind_info pages are generated
1275 * src/UnwindDump.cpp: fix function name decoding in regular pages
1278 2008-07-21 Nick Kledzik <kledzik@apple.com>
1280 * ld64.xcodeproj/project.pbxproj: don't allow ld to build for x86_64 until libdtrace.dylib is available
1283 2008-07-18 Nick Kledzik <kledzik@apple.com>
1285 * src/MachOReaderRelocatable.hpp: don't crash if debug_line section has no line table
1288 2008-07-18 Nick Kledzik <kledzik@apple.com>
1290 <rdar://problem/5628149> Duplicate probe firings in Security.framework
1291 * src/LTOReader.hpp: optimize() now returns atoms optimized away
1292 * src/ObjectFile.h: optimize() should return if it did anything
1293 * src/ArchiveReader.hpp: pass through optimize() result
1294 * src/ld.cpp: rework dtrace probe processing as a new pass to prevent double counting
1297 2008-07-15 Nick Kledzik <kledzik@apple.com>
1299 <rdar://problem/6061904> automatically order initializers to start of __TEXT
1300 * src/Options.cpp: add -no_order_inits option
1301 * src/MachOReaderRelocatable.hpp: merge __StaticInit into __text
1302 * src/ObjectFile.h: add fAutoOrderInitializers
1303 * src/ld.cpp: sort initializer to start of __text and terminators to end
1304 * doc/man/man1/ld.1: add doc about -no_order_inits
1305 * unit-tests/test-cases/init-order: add test case
1307 2008-07-15 Nick Kledzik <kledzik@apple.com>
1309 <rdar://problem/6073697> Only add LC_SEGMENT_SPLIT_INFO to dylibs that might be in the shared cache
1310 * src/MachOWriterExecutable.hpp: re-layout load commands after split-seg data computed
1311 * src/Options.cpp: non-public install name will disable split-seg load command
1314 2008-07-14 Nick Kledzik <kledzik@apple.com>
1316 <rdar://problem/6069861> ld -r for x86_64 is changing visibility of cstring constants
1317 * src/MachOWriterExecutable.hpp: force x86_64 cstring labels to be local in -r mode
1318 * unit-tests/test-cases/cstring-label: added test case
1321 2008-07-11 Nick Kledzik <kledzik@apple.com>
1323 <rdar://problem/6070190> ld not adding updating LC_SEGMENT_SPLIT_INFO with __unwind_info section
1324 * src/MachOWriterExecutable.hpp: run createSplitSegContent() after __unwind_info section is created
1326 2008-07-10 Nick Kledzik <kledzik@apple.com>
1328 * src/LTOReader.hpp: improve missing symbol error message
1331 2008-07-09 Nick Kledzik <kledzik@apple.com>
1333 <rdar://problem/6061558> linker should order __DATA segment to reduce dyld dirtied pages
1334 * src/ld.cpp: first phase, order sections
1337 2008-07-08 Nick Kledzik <kledzik@apple.com>
1339 * src/MachOReaderRelocatable.hpp: remove "coal" sections when creating a final linked image
1342 2008-07-08 Nick Kledzik <kledzik@apple.com>
1344 <rdar://problem/6054476> ld: add support for mllvm LTO options
1345 * src/Options.cpp: support -mllvm option
1346 * src/LTOReader.hpp: call lto_codegen_debug_options() with -mllvm options
1347 * src/ld.cpp: pass llvmOptions to optimize()
1348 * src/Options.h: add fLLVMOptions
1349 * src/ArchiveReader.hpp: add llvmOptions parameter to optimize()
1350 * src/ObjectFile.h: add llvmOptions parameter to optimize()
1351 * unit-tests/test-cases/lto-llvm-options: add test case
1354 2008-07-07 Nick Kledzik <kledzik@apple.com>
1356 <rdar://problem/6054296> Linker fails with: 24-bit pointer diff out of range in unwind info in unwind info from...
1357 * src/MachOWriterExecutable.hpp: fix when to fallback to uncompressed unwind info
1360 2008-07-03 Nick Kledzik <kledzik@apple.com>
1362 <rdar://problem/6001472> ld crash with gcc-4.0 code that uses a zero sized array
1363 * src/MachOReaderRelocatable.hpp: handle zero size atom in a zero sized section
1366 2008-07-03 Nick Kledzik <kledzik@apple.com>
1368 <rdar://problem/6016809> ld crashes when bad ppc relocs are found
1369 * src/MachOReaderRelocatable.hpp: change all missing PAIR warnings to errors
1372 2008-07-02 Nick Kledzik <kledzik@apple.com>
1374 <rdar://problem/5881324> when linking a kext the static linker should leave a pad in the headers to allow code signing
1375 * src/MachOWriterExecutable.hpp: add padding for load commands in object files
1376 * unit-tests/test-cases/code-signed-object-file: added test case
1379 2008-07-02 Nick Kledzik <kledzik@apple.com>
1381 <rdar://problem/6048484> LC_SEGMENT_64 filesize incorrect for MH_OBJECT filetype
1382 * src/MachOWriterExecutable.hpp: correctly set segment size info in object files
1383 * unit-tests/test-cases/no-object-symbols: add test case
1386 2008-06-26 Nick Kledzik <kledzik@apple.com>
1388 * ld64.xcodeproj/project.pbxproj: enable ld and rebase targets to build for x86_64
1389 * src/rebase.cpp: remove unused fRelocBase field that was not 64-bit clean
1390 * src/MachOReaderRelocatable.hpp: fix getEncodedP() to be 64-bit clean
1393 ----- Tagged ld64-86.3
1395 2008-06-17 Nick Kledzik <kledzik@apple.com>
1397 * src/ld.cpp: fix loadUndefines() to double check undefine symbol was not already loaded
1400 ----- Tagged ld64-86.2
1402 2008-06-14 Nick Kledzik <kledzik@apple.com>
1404 * srd/ld.cpp: Add NULL check in getTentativesNames()
1407 ----- Tagged ld64-86.1
1409 2008-06-06 Nick Kledzik <kledzik@apple.com>
1411 * src/MachOWriterExecutable.hpp: fix header padding calculation for dyld
1414 ----- Tagged ld64-86
1416 2008-06-04 Nick Kledzik <kledzik@apple.com>
1418 * src/LTOReader.hpp: if lto_codegen_add_module() fails, add explanation to error message
1421 2008-06-04 Nick Kledzik <kledzik@apple.com>
1423 * src/ObjectFile.h: add deadAtoms parameter to optimize()
1425 * src/ArchiveReader.hpp: ditto
1426 * src/MachOReaderRelocatable.hpp: handle llvm use of 0x1B pointer encodings in CIEs
1427 * src/LTOReader.hpp: make sure libLTO.dylib knows about any llvm symbol coalesced away
1428 * unit-tests/test-cases/lto-weak-native-override: add test case
1431 2008-06-04 Nick Kledzik <kledzik@apple.com>
1433 <rdar://problem/5935600> LTO : 176.gcc and 177.mesa build failure at -O4
1434 * src/LTOReader.hpp: make sure internal is returned by getAtoms()
1435 * unit-tests/test-cases/lto-archive-dylib: update test case
1438 2008-06-03 Nick Kledzik <kledzik@apple.com>
1440 <rdar://problem/5894163> fix for 5613343 need to search for definitions for common symbols is broken
1441 * src/ld.cpp: modify loadUndefines() to check for undefines in all files and tentative definitions but only in archives
1442 * src/machochecker.cpp: check for undefine symbols and external symbols with same name
1443 * unit-tests/test-cases/tentative-and-archive: update test case
1446 2008-06-03 Nick Kledzik <kledzik@apple.com>
1448 <rdar://problem/5935237> linker produces wrong result for 16-bit call relocations
1449 * src/MachOReaderRelocatable.hpp: properly parse i386 scattered relocs for word sized pc-rel vanilla
1450 * src/MachOWriterExecutable.hpp: propery compute displacement for x86::kPCRel16
1451 * unit-tests/test-cases/relocs-asm: update test case with callw instructions
1454 2008-06-03 Nick Kledzik <kledzik@apple.com>
1456 <rdar://problem/5905900> Building kext x86_64 with unexported symbols file causes linking problems
1457 * src/MachOWriterExecutable.hpp: better check when creating undefined proxy atoms
1458 * unit-tests/test-cases/unexported_symbols_list-r: added test case
1461 2008-06-02 Nick Kledzik <kledzik@apple.com>
1463 <rdar://problem/5659338> S_CSTRING_LITERALS section type not preserved in executable
1464 * src/ObjectFile.h: added ContentType
1465 * src/MachOReaderRelocatable.hpp: set ContentType for anonymous string literals
1466 * src/MachOWriterExecutable.hpp: set S_CSTRING_LITERALS if ContentType is kCStringType
1467 * unit-tests/test-cases/cstring-custom-section: added test case
1470 2008-06-02 Nick Kledzik <kledzik@apple.com>
1472 <rdar://problem/5980194> linker should produce __unwind_info section in final linked images
1473 * src/ld.cpp: sort __unwind_info then __eh_frame section to end of __TEXT
1474 * src/Architectures.hpp: add kImageOffset32 and kPointerDiff24
1475 * src/ObjectFile.h: add compact unwind info support
1476 * src/MachOReaderRelocatable.hpp: add compact unwind info support
1477 * src/MachOFileAbstraction.hpp: add C++ wrappers for unwind section layout
1478 * src/UnwindDump.cpp: new tool for dumping __unwind_info section
1479 * src/MachOWriterExecutable.hpp: create __unwind_info section when needed
1480 * src/ObjectDump.cpp: print unwind info
1483 2008-06-02 Nick Kledzik <kledzik@apple.com>
1485 * unit-tests/test-cases/llvm-integration: split out some test cases
1486 * unit-tests/test-cases/lto-preload-pie: added
1487 * unit-tests/test-cases/lto-archive-dylib: added
1490 2008-05-30 Nick Kledzik <kledzik@apple.com>
1492 * unit-tests: fixes to build all tests with with gcc-4.2 on SnowLeopard
1495 2008-05-30 Nick Kledzik <kledzik@apple.com>
1497 <rdar://problem/5536348> support -preload option to generate MH_PRELOAD binaries compatible with mtoc(1) and EFI
1498 * src/ld.cpp: add entryPoint parameter to optimize()
1499 * src/ArchiveReader.hpp: ditto
1500 * src/ObjectFile.h: ditto
1501 * src/LTOReader.hpp: use entryPoint parameter to optimize()
1502 * src/Options.h: add kPreload and segment alignment
1503 * src/Options.cpp: support -preload and -segalign
1504 * src/MachOWriterExecutable.hpp: support kPreload and non-page aligned segments
1507 2008-05-30 Nick Kledzik <kledzik@apple.com>
1509 <rdar://problem/4431008> ld should warn if passed -r and also dylibs
1510 * src/ld.cpp: check for spurious dylibs in Linker::addDylib()
1513 ----- Tagged ld64-85.6
1515 2008-11-01 Nick Kledzik <kledzik@apple.com>
1517 <rdar://problem/6254202> support increased branch range in Thumb-2
1518 * src/MachOWriterExecutable.hpp: in fixUpReferenceFinal() support new longer branch range
1521 2008-11-01 Nick Kledzik <kledzik@apple.com>
1523 <rdar://problem/6104368> ld warning: unknown option to -iphoneos_version_min, not 1.x or 2.x
1524 * src/Options.cpp: In setIPhoneVersionMin() support 3.x
1527 ----- Tagged ld64-85.5
1529 2008-09-17 Nick Kledzik <kledzik@apple.com>
1531 <rdar://problem/6162415> vtable pointers can be missing thumb bit
1532 * src/MachOWriterExecutable.hpp: Writer<arm>::fixUpReferenceFinal() OR in the 1 bit if the target
1533 of a arm::kReadOnlyPointer is thumb.
1536 ----- Tagged ld64-85.4
1538 2008-08-11 Nick Kledzik <kledzik@apple.com>
1540 <rdar://problem/6138961> ld should ignore LD_PREBIND when processing a static archive
1541 * src/MachOWriterExecutable.hpp: in setImportNlist() never use N_PBUD for object files
1543 ----- Tagged ld64-85.3
1545 2008-07-14 Nick Kledzik <kledzik@apple.com>
1547 <rdar://problem/6060912> Prebinding busted in DTSB
1548 * src/Options.cpp: check for libstdc++.6.0.[49] in seg_addr_table
1551 ----- Tagged ld64-85.2
1553 2008-05-06 Nick Kledzik <kledzik@apple.com>
1555 <rdar://problem/5905889> ARM ld should take W bit off of maxprot for __TEXT segment
1556 * src/MachOWriterExecutable.hpp: for iPhone always set maxprot to be initprot in all segments
1559 2008-05-06 Nick Kledzik <kledzik@apple.com>
1561 <rdar://problem/5914343> encryptable images may not be signable
1562 * src/MachOWriterExecutable.hpp: use minimum header padding when aligning __text section
1565 ----- Tagged ld64-85 (Xcode 3.1)
1567 2008-04-29 Nick Kledzik <kledzik@apple.com>
1569 * ld64.xcodeproj/project.pbxproj: <llvm-c/lto.h> is moving from /usr/local/include to /Developer/usr/local/include
1572 2008-04-29 Nick Kledzik <kledzik@apple.com>
1574 <rdar://problem/5829579> ld doesn't honor "rightmost" -syslibroot argument
1575 * src/Options.cpp: if last -syslibroot is /, then ignore all syslibroots
1578 2008-04-29 Nick Kledzik <kledzik@apple.com>
1580 <rdar://problem/5866582> GLRendererFloat has bad __eh_frame section caused by mixing llvm-gcc and gcc object files
1581 * src/MachOReaderRelocatable.hpp: make all atoms in __eh_frame section have 1-byte alignment
1582 * src/MachOWriterExecutable.hpp: make __eh_frame section have pointer sized alignment
1585 2008-04-17 Nick Kledzik <kledzik@apple.com>
1587 * src/MachOReaderRelocatable.hpp: better cpu subtype support
1590 2008-04-14 Nick Kledzik <kledzik@apple.com>
1592 <rdar://problem/5733759> ld64 has bad ARM branch island check
1593 * src/MachOWriterExecutable.hpp: in addBranchIslands() don't force large arm programs to fail
1596 2008-04-10 Nick Kledzik <kledzik@apple.com>
1598 * src/MachOWriterExecutable.hpp: fix stubs used with lazy dylibs
1601 ----- Tagged ld64-84.4
1603 2008-04-10 Nick Kledzik <kledzik@apple.com>
1605 <rdar://problem/5847206> SPEC2000/eon built with -mdynamic-no-pic won't run
1606 * src/Architectures.hpp: added arm::kReadOnlyPointer
1607 * src/MachOReaderRelocatable.hpp: generate arm::kReadOnlyPointer
1608 * src/MachOWriterExecutable.hpp: use arm::kReadOnlyPointer
1609 * src/machochecker.cpp: allow MH_PIE bit
1610 * unit-tests/test-cases/switch-jump-table: added test cases
1613 ----- Tagged ld64-84.3
1615 2008-04-09 Nick Kledzik <kledzik@apple.com>
1617 <rdar://problem/5852023> -undefined dynamic_lookup busted
1618 * src/ld.cpp: don't create proxy atom when scanning for dylib duplicates
1619 * unit-tests/test-cases/tentative-and-archive: use -undefined dynamic_lookup
1622 ----- Tagged ld64-84.2
1624 2008-04-04 Nick Kledzik <kledzik@apple.com>
1626 * src/ld.cpp: don't add .eh symbols to symbol table in -r mode
1627 * unit-tests/test-cases/eh-coalescing-r: update to test out of order coalescing
1630 ----- Tagged ld64-84.1
1632 2008-03-28 Nick Kledzik <kledzik@apple.com>
1634 <rdar://problem/5720961> ld should prefer architecture-specific variant over generic in fat object file
1635 * src/Options.cpp: fully process -arch arguments into fArchitecture and fSubArchitecture
1636 * src/ld.cpp: when -arch with a subtype is used, try to find the exact subtype from fat files
1637 * unit-tests/test-cases/cpu-sub-types-preference: added test cases for arm and ppc
1640 ----- Tagged ld64-84
1642 2008-03-28 Nick Kledzik <kledzik@apple.com>
1644 * src/LTOReader.hpp: don't print lto version, if lto is unavailable
1647 2008-03-26 Nick Kledzik <kledzik@apple.com>
1649 <rdar://problem/5575399> Add LD_WARN_COMMONS to BigBear builds
1650 * src/Options.cpp: Add support for LD_WARN_FILE which copies all warnings to a side file
1653 2008-03-26 Nick Kledzik <kledzik@apple.com>
1655 <rdar://problem/5797713> Need encryption tag in mach-o file
1656 <rdar://problem/5811920> linker should adjust arm final linked images so __text is never on the same page as the load commands
1657 * src/MachOFileAbstraction.hpp: add support for encryption_info_command
1658 * src/Options.cpp: add support for LD_NO_ENCRYPT and -no_encryption
1659 * src/MachOWriterExecutable.hpp: add EncryptionLoadCommandsAtom
1660 * src/machochecker.cpp: validate LC_ENCRYPTION_INFO
1663 2008-03-25 Nick Kledzik <kledzik@apple.com>
1665 <rdar://problem/5712533> ld64 does not recognize LLVM bitcode archive files
1666 * src/MachOReaderArchive.hpp: renamed to src/ArchiveReader.hpp
1667 * src/ArchiveReader.hpp: sniff each member and instantiate correct reader
1668 * src/ld.cpp: rename mach_o::archive::Reader to archive::Reader
1669 * ld64.xcodeproj/project.pbxproj: rename MachOReaderArchive.hpp to ArchiveReader.hpp
1670 * unit-tests/test-cases/llvm-integration: added test case
1673 2008-03-25 Nick Kledzik <kledzik@apple.com>
1675 <rdar://problem/5771658> ld64 should switch to new libLTO.dylib interface
1676 <rdar://problem/5675690> Produce llvm bc file in 'ld -r' mode if all .o files are llvm bc
1677 * src/LTOReader.hpp: rewrite from LLVMReader.hpp to use new lto_* C interface
1678 * unit-tests/test-cases/llvm-integration: update and comment
1679 * ld64.xcodeproj/project.pbxproj: update to lazy load libLTO.dylib
1680 * src/ld.cpp: rework and simplify Linker::optimize()
1681 * src/ObjectDump.cpp: Add -nm option
1684 2008-03-25 Nick Kledzik <kledzik@apple.com>
1686 * src/MachOReaderRelocatable.cpp: Fix some .objc_class_name_ off by one problem
1687 * src/MachOWriterExecutable.cpp: Fix some .objc_class_name_ off by one problem
1690 2008-03-24 Nick Kledzik <kledzik@apple.com>
1692 <rdar://problem/5814613> Xcode 3.1 breaks linkage of libgcj.9.dylib from gcc 4.3.0
1693 * src/MachOWriterExecutable.cpp: Make sure all ivars in Writer are initialized.
1696 2008-03-21 Nick Kledzik <kledzik@apple.com>
1698 * src/Options.cpp: warn if -seg1addr value is not page aligned
1701 2008-03-21 Nick Kledzik <kledzik@apple.com>
1703 <rdar://problem/5806437> Move ARM support outside of __OPEN_SOURCE__
1704 * src/ld.cpp: remove __OPEN_SOURCE__ around arm support
1705 * src/LLVMReader.hpp: remove __OPEN_SOURCE__ around arm support
1706 * src/MachOReaderDylib.hpp: remove __OPEN_SOURCE__ around arm support
1707 * src/ObjectFile.h: remove __OPEN_SOURCE__ around arm support
1708 * src/MachOReaderRelocatable.hpp: remove __OPEN_SOURCE__ around arm support
1709 * src/OpaqueSection.hpp: Cover arm support inside __OPEN_SOURCE__ macro check
1710 * src/MachOWriterExecutable.hpp: remove __OPEN_SOURCE__ around arm support
1711 * src/ObjectDump.cpp: remove __OPEN_SOURCE__ around arm support
1712 * ld64.xcodeproj/project.pbxproj: remove ARM_SUPPORT from config.h
1715 ----- Tagged ld64-83.2
1717 2008-03-15 Nick Kledzik <kledzik@apple.com>
1719 <rdar://problem/5801620> ld64-83 removes OBJC_CLASS_$ symbols from projects, causes catastrophic results
1720 * src/Options.cpp: restore "case CPU_TYPE_ARM" in switch statement for .objc_class symbols in .exp files
1721 * unit-tests/test-cases/objc-exported_symbols_list: added test case
1724 ----- Tagged ld64-83.1
1726 2008-03-14 Nick Kledzik <kledzik@apple.com>
1728 <rdar://problem/5800466> -iphone_version_min ==> -iphoneos_version_min
1729 * src/Options.cpp: support -iphoneos_version_min as well
1732 ----- Tagged ld64-83
1734 2008-03-10 Nick Kledzik <kledzik@apple.com>
1736 <rdar://problem/5791543> ld needs to strip iphone_version_min option if invoking ld_classic
1737 * src/Options.cpp: suppress -iphone_version_min from being passed to ld_classic
1740 2008-03-04 Nick Kledzik <kledzik@apple.com>
1742 <rdar://problem/4171253> ADOBE XCODE: Linker option to lazy load frameworks (cause dyld is too slow)
1743 * src/MachOWriterExecutable.hpp: create lazy stubs and LC_LAZY_LOAD_DYLIB for lazy load dylibs
1744 * src/Options.cpp: support -lazy-l, -lazy_library, and -lazy_framework
1745 * src/MachOFileAbstraction.hpp: add LC_LAZY_LOAD_DYLIB and S_LAZY_DYLIB_SYMBOL_POINTERS until in cctools
1746 * src/MachOReaderDylib.hpp: add isLazyLoadedDylib()
1747 * src/ld.cpp: pass lazy helper atom to writer
1748 * doc/man/man1/ld.1: document new options
1749 * unit-tests/test-cases/lazy-dylib-objc: add test case
1750 * unit-tests/test-cases/lazy-dylib: add test case
1753 ----- Tagged ld64-82.7
1755 2008-03-07 Nick Kledzik <kledzik@apple.com>
1757 <rdar://problem/5787149> duplicate symbol literal-pointer@__OBJC@__message_refs@...
1758 * src/MachOReaderRelocatable.hpp: AnonymousAtom from S_LITERAL_POINTERS section should be weak
1759 * unit-tests/test-cases/objc-selector-coalescing: added test case
1762 ----- Tagged ld64-82.6
1764 2008-03-04 Nick Kledzik <kledzik@apple.com>
1766 <rdar://problem/5779681> ld crashes building XsanFS for Snow Leopard Builds
1767 * src/ld.cpp: add bool dylibsOnly parameter to addJustInTimeAtoms()
1768 * unit-tests/test-cases/tentative-and-archive: added test case
1770 2008-03-04 Nick Kledzik <kledzik@apple.com>
1772 <rdar://problem/5775822> ld64 should not force building with gcc 4.0
1773 * ld64.xcodeproj/project.pbxproj: change rules to use "system" compiler instead of 4.0
1776 2008-02-29 Nick Kledzik <kledzik@apple.com>
1778 <rdar://problem/5774730> Simulator frameworks are being build split-seg and not prebound
1779 * src/Options.cpp: only splitseg if prebound
1782 2008-02-29 Nick Kledzik <kledzik@apple.com>
1784 <rdar://problem/5774231> Linker should not make GSYM debug note for .objc_category_* symbols
1785 * src/ld.cpp: suppress GSYM debug notes for absolute symbols
1786 * unit-tests/test-cases/objc-category-debug-notes: added test case
1789 2008-02-29 Nick Kledzik <kledzik@apple.com>
1791 <rdar://problem/5768970> non-ASCII CFString support is broken
1792 * src/MachOReaderRelocatable.hpp: only name and coalesce cfstring constants if they use a __cstring
1793 * unit-tests/test-cases/cfstring-utf16: add test case
1796 2008-02-25 Nick Kledzik <kledzik@apple.com>
1798 <rdar://problem/5366363> ld -r -x
1799 * doc/man/man1/ld.1: update man page to explain -r -x produces auto-stripped labels
1802 ----- Tagged ld64-82.5
1804 2008-02-12 Nick Kledzik <kledzik@apple.com>
1806 <rdar://problem/5738023> x86_64: -stack_size failure when large __bss is used
1807 * src/ld.cpp: only move section already in __DATA segment to new __huge section
1808 * unit-tests/test-cases/stack_size_no_addr: updated test case to add large bss section
1811 ----- Tagged ld64-82.4
1813 2008-02-06 Nick Kledzik <kledzik@apple.com>
1815 <rdar://problem/5726215> comdat warnings with ld -r of C++ .o files
1816 * unit-tests/test-cases/eh-coalescing-r: added test case
1817 * src/ld.cpp: in ld -r mode don't warn about if .eh symbols are not static
1820 2008-02-06 Devang Patel <dpatel@apple.com>
1822 <rdar://problem/5724990> LTO of Bom framework with -dead_strip causes ld(1) crash
1823 * src/LLVMReader.hpp: Check fAtom while determining LLVMReference target binding.
1824 * unit-tests/test-cases/llvm-integration/Makefile: Add new test case.
1825 * unit-tests/test-cases/llvm-integration/a15.c: New.
1826 * unit-tests/test-cases/llvm-integration/b15.c: New.
1827 * unit-tests/test-cases/llvm-integration/c15.c: New.
1829 2008-02-05 Nick Kledzik <kledzik@apple.com>
1831 * src/ld.cpp: fix for -arch ppc -mdynamic-no-pic -pie so PPC_RELOC_HA16 reloc is used
1833 ----- Tagged ld64-82.3
1835 2008-02-04 Nick Kledzik <kledzik@apple.com>
1837 <rdar://problem/5721186> ld doesn't seem to understand $ld$add$os... and $ld$hide$os... for 10.6 moves
1838 * src/ObjectFile.h: add 10.6
1839 * src/Options.cpp: add 10.6 support
1840 * src/MachOReaderDylib.hpp: recognize $os10.6$
1843 ----- Tagged ld64-82.2
1845 2008-01-30 Devang Patel <dpatel@apple.com>
1847 <rdar://problem/5714833> Can't build 64-bit Intel binaries with LTO
1848 <rdar://problem/5714787> ld64 fails to build with llvm-gcc-4.2
1849 * src/LLVMReader.hpp: Fix character count typo in strncmp call.
1850 Use const char * to initialize temp. string.
1851 * ld64.xcodeproj/project.pbxproj: use $(DEVELOPER_DIR) in header search construction
1852 instead of hard coding /Developer.
1854 ----- Tagged ld64-82.1
1856 2008-01-23 Nick Kledzik <kledzik@apple.com>
1858 * src/MachOReaderRelocatable.hpp: don't bus error if S_LITERAL_POINTERS is missing relocs
1861 2008-01-22 Nick Kledzik <kledzik@apple.com>
1863 <rdar://problem/5695496> ld uses 32-bits in some places to hold addresses when parsing 64-bit mach-o files
1864 * src/MachOReaderRelocatable.hpp: use AddrToAtomMap type that switch address to 64-bits for 64-bit archs
1865 * src/MachOWriterExecutable.hpp: verify BR14 does not overflow for external relocs
1866 * unit-tests/test-cases/relocs-c: update test case to slide addresses to verify x86_64 .o files
1869 ----- Tagged ld64-82
1871 2008-01-18 Nick Kledzik <kledzik@apple.com>
1873 <rdar://problem/5694612> Bad grammar used in ld warning: cannot exported hidden symbol
1874 * src/ld.cpp: fix typo in warning string
1877 2008-01-16 Nick Kledzik <kledzik@apple.com>
1879 <rdar://problem/5565074> Bundle Loader does not work anymore when loader is a bundle
1880 <rdar://problem/5590203> ld warns of incorrect architecture when linking a bundle to a bundle
1881 * src/MachOReaderDylib.hpp: support linking against bundles via -bundle_loader. Clean up error messages
1882 * unit-tests/test-cases/bundle_loader: update test case
1885 2008-01-16 Nick Kledzik <kledzik@apple.com>
1887 <rdar://problem/5366363> ld -r -x creates debug notes (stabs) when it should not with -x (keep only global symbols)
1888 * src/Options.cpp: in reconfigureDefaults() if -r and -x then -S
1891 2008-01-16 Nick Kledzik <kledzik@apple.com>
1893 <rdar://problem/5566068> if ld crashes while writing output file, it should delete the half written file
1894 * src/MachOWriterExecutable.hpp: wrap open/write/close in try block and add signal handlers all to delete
1895 output file on failure.
1898 2008-01-16 Devang Patel <dpatel@apple.com>
1900 * src/LLVMReader.hpp: Use __gnu_cxx::hash_map instead of hash supported by LLVM.
1903 2008-01-16 Nick Kledzik <kledzik@apple.com>
1905 <rdar://problem/5593537> GC-supported library can't be linked into GC-required executable
1906 * src/ld.cpp: loosen constraint that all objc code must be compiled with same GC settings and
1907 allow gc-compatible code to be linked into anything.
1908 * unit-tests/test-cases/objc-gc-checks: update test case
1911 2008-01-15 Nick Kledzik <kledzik@apple.com>
1913 <rdar://problem/5687976> no debug notes for custom named data
1914 * src/ld.cpp: in synthesizeDebugNotes() check getSymbolTableInclusion() instead of for leading underscore
1915 * unit-tests/test-cases/dwarf-debug-notes: update test case
1917 ----- Tagged ld64-81.5
1919 2008-01-14 Devang Patel <dpatel@apple.com>
1921 <rdar://problem/5683813> llvm-gcc-4.2 fails to build Sqlite 3.5.4 with -O4
1922 * src/LLVMReader.hpp: Resolve proxy references. Collect new unbounded references
1924 * src/ld.cpp: Resolve additional unbounded references after optimization.
1927 2008-01-14 Nick Kledzik <kledzik@apple.com>
1929 <rdar://problem/5655246> PPC Leopard (Xcode 3.0) linker ld gets "Bus error" sometimes
1930 * src/MachOReaderRelocatable.hpp: use same code as x86 to parse ppc and arm sect-diff relocs
1931 * src/MachOWriterExecutable.hpp: use same code as x86 to write ppc and arm sect-diff relocs
1934 2008-01-11 Nick Kledzik <kledzik@apple.com>
1936 <rdar://problem/5637618> PPC Leopard (Xcode 3.0) linker ld reports "unknown scattered relocation type 4"
1937 * src/MachOReaderRelocatable.hpp: add PPC_RELOC_HI16 to scattered reloc parsing
1938 * unit-tests/test-cases/relocs-asm/relocs-asm.s: added tests for scattered hi/lo instructions
1941 2008-01-11 Nick Kledzik <kledzik@apple.com>
1943 * doc/man/man1/ld.1: add doc for -no_implicit_dylibs, -read_only_stubs, -slow_stubs, -interposable_list
1946 2008-01-11 Nick Kledzik <kledzik@apple.com>
1948 <rdar://problem/4800212> ld64(1) man page uses ambiguous term "suffix"
1949 * doc/man/man1/ld.1: make meaning of "suffix" more explicit
1952 2008-01-11 Nick Kledzik <kledzik@apple.com>
1954 <rdar://problem/5633081> Obj-C Symbols in Leopard Can't Be Weak Linked
1955 * src/MachOWriterExecutable.hpp: set weak and lazy attributes on dummy .objc_class_name undefines
1956 to dylibs to support Mac OS X 10.3.x dyld
1959 2008-01-11 Nick Kledzik <kledzik@apple.com>
1961 <rdar://problem/5669751> Unknown error with linker (dyld: unknown external relocation type)
1962 * src/ld.cpp: fix crash when SO stabs are not balanced
1965 2008-01-11 Devang Patel <dpatel@apple.com>
1967 <rdar://problem/5667433> LTO does not work if expected output is a dynamic library
1968 * src/LLVMReader.hpp: Supply arguments describing output kind to optimizer. Communicate
1971 2000-01-10 Nick Kledzik <kledzik@apple.com>
1973 <rdar://problem/5680988> __cls_refs section is losing S_LITERAL_POINTERS section type
1974 * src/MachOWriterExecutable.hpp: special case __cls_refs section
1975 * unit-tests/test-cases/objc-literal-pointers: add test case
1978 2008-01-03 Nick Kledzik <kledzik@apple.com>
1980 <rdar://problem/5667688> wrong EH information might be used
1981 Created new kGroupSubordinate reference kind to model group comdat. The "signature" atom
1982 has kGroupSubordinate references to the other atoms in the group. If the signature atom
1983 is coalesced away, the linker follows kGroupSubordinate references and throws away the
1984 other members of the group.
1985 * unit-tests/test-cases/eh-coalescing: added test case
1986 * src/ld.cpp: added markDead() and use propagate to subordinates
1987 * src/Architectures.hpp: added kGroupSubordinate
1988 * src/MachOReaderRelocatable.hpp: add kGroupSubordinate reference from a function to its .eh atom
1989 and if used, from .eh atom to its LSDA atom.
1990 * src/MachOWriterExecutable.hpp: handle kGroupSubordinate like kNoFixUp
1992 ----- Tagged ld64-81.4.1
1994 2007-12-19 Devang Patel <dpatel@apple.com>
1996 * src/LLVMReader.hpp: Add LLVM_LTO_VERSION #ifdef check.
1998 2007-12-19 Devang Patel <dpatel@apple.com>
2000 * src/LLVMReader.hpp: Add fOptimizer NULL check before calling printVersion().
2002 2007-12-19 Devang Patel <dpatel@apple.com>
2004 <rdar://problem/5655956> print LLVM LTO version number in verbose mode
2005 * src/LLVMReader.hpp: Add printLLVMVersion() to print llvm version string in verbose mode.
2006 * src/Options.cpp: Use printLLVMVersion() in verbose mode.
2008 2007-12-19 Devang Patel <dpatel@apple.com>
2010 <rdar://problem/5655956> print LLVM LTO version number in verbose mode
2011 * src/Options.h: Add verbose() method to check fVerbose flag.
2012 * src/LLVMReader.hpp: Print LLVM version string in verbose mode.
2014 ----- Tagged ld64-81.4
2016 2007-12-18 Devang Patel <dpatel@apple.com>
2018 * src/LLVMReader.hpp: Invalidate input architecture when optimizer is not available.
2020 ----- Tagged ld64-81.3
2022 2007-12-17 Nick Kledzik <kledzik@apple.com>
2024 * ld64.xcodeproj/project.pbxproj: remove extraneous header search paths
2027 2007-12-17 Devang Patel <dpatel@apple.com>
2029 * src/LLVMReader.hpp: Do not throw exception if LLVMReader is not able to
2030 dlopen LTO library. Instead just flag input file as an invalid LLVM bitcode file.
2033 2007-12-14 Nick Kledzik <kledzik@apple.com>
2035 <rdar://problem/5645908> gcc DejaGnu failure: gcc.dg/20020312-2.c (test for excess errors) (-fstack-protector-all)
2036 * src/MachOWriterExecutable.hpp: fix Writer<x86>::generatesExternalTextReloc() to allow text relocs
2037 * unit-tests/test-cases/read-only-relocs: updated test case to link a dynamic main executable compiled with -static
2040 2007-12-14 Devang Patel <dpatel@apple.com>
2042 <rdar://problem/5648438> Enable Link Time Optimization in Opal
2043 * src/LLVMReader.hpp: Locate LLVMlto.dylib relative to ld location in Developer folder.
2044 * ld64.xcodeproj/project.pbxproj: Add {DEVELOPER_DIR}/usr/include in header search path.
2045 * unit-tests/run-all-unit-tests: Set DYLD_FALLBACK_LIBRARY_PATH to find LLVMlto.dylib during unit testing.
2046 * unit-tests/testcases/llvm-integration/Makefile: Point LLVMGCC and LLVMGXX to llvm-gcc-4.2 in Developer folder during unit testing.
2049 2007-12-13 Nick Kledzik <kledzik@apple.com>
2051 <rdar://problem/5645446> SWB: failures due to ld: pointer in read-only segment not allowed in slidable image, used in ...
2052 * src/MachOReaderRelocatable.hpp: in Reader<x86>::addRelocReference() handle weak pc-rel 32-bit vanilla relocs properly
2054 ----- Tagged ld64-81.2
2058 2007-12-07 Nick Kledzik <kledzik@apple.com>
2060 <rdar://problem/5615298> support 8-bit relocations for i386
2061 * src/Architectures.hpp: add kPCRel8
2062 * src/MachOReaderRelocatable.hpp: support 8-bit pc-rel relocations for intel
2063 * src/MachOWriterExecutable.hpp: support 8-bit pc-rel relocations for intel
2064 * unit-tests/test-cases/relocs-asm: add test cases
2067 ----- Tagged ld64-81.1
2069 2007-12-06 Nick Kledzik <kledzik@apple.com>
2071 * src/MachOReaderDylib.hpp: rework cycle detection to remove some false positives
2074 2007-12-05 Nick Kledzik <kledzik@apple.com>
2076 <rdar://problem/5628149> Duplicate probe firings in Security.framework
2077 * src/ld.cpp: check dtrace probe sites are not in fDeadAtoms before using
2078 * unit-tests/test-cases/dtrace-static-probes-coalescing: add test case
2081 2007-12-05 Nick Kledzik <kledzik@apple.com>
2083 * src/MachOReaderRelocatable.hpp: fix CFString coalescing to work with -fwritable-strings
2084 * unit-tests/test-cases/cfstring-coalesce: add -fwritable-strings to test case
2087 ----- Tagged ld64-81
2089 2007-11-15 Nick Kledzik <kledzik@apple.com>
2091 <rdar://problem/4196067> ld64 should support runtime text relocations
2092 * src/MachOWriterExecutable.hpp: add generatesLocalTextReloc() and generatesExternalTextReloc()
2093 * src/Options.cpp: process -read_only_relocs option
2094 * src/Options.h: add allowTextRelocs() and warnAboutTextRelocs()
2095 * src/MachOReaderRelocatable.hpp: add hasLongBranchStubs()
2096 * src/machochecker.cpp: allow relocs in read only segments, if section flags are set
2097 * unit-tests/test-cases/read-only-relocs: update test case
2100 2007-11-08 Devang Patel <dpatel@apple.com>
2102 * ld64.xcodeproj/project.pbxproj: add new build phase "build configure.h" for
2104 * src/ld.cpp: Include "configure.h"
2107 ----- Tagged ld64-80.11
2109 2008-02-12 Nick Kledzik <kledzik@apple.com>
2111 <rdar://problem/5741312> Wrong section name for objc info for ARM when OBJC2 is used
2112 * src/MachOWriterExecutable.hpp: switch segment/section name for ARM objc2 image info
2114 ----- Tagged ld64-80.10
2116 2008-02-11 Nick Kledzik <kledzik@apple.com>
2118 <rdar://problem/5733578> ld64 does not support -aspen_version_min 2.0
2119 * src/Options.cpp: allow 2.x for -aspen_version_min
2122 2008-02-11 Nick Kledzik <kledzik@apple.com>
2124 <rdar://problem/5733575> ld_classic: unknown flag: -aspen_version_min
2125 * src/Options.cpp: change -aspen_version_min x.x to -macosx_version_min 10.5 when invoking ld_classic
2128 ----- Tagged ld64-80.9
2130 2008-01-29 Nick Kledzik <kledzik@apple.com>
2132 <rdar://problem/5713054> -iphone_version_min ==> -aspen_version_min
2133 * src/Options.cpp: support -aspen_version_min
2136 ----- Tagged ld64-80.8
2138 2008-01-10 Nick Kledzik <kledzik@apple.com>
2140 * src/Options.cpp: support transition to new objc ABI for ARM by allowing old .objc_class_name_*
2141 style names in export files and map them to new _OBJC_CLASS_$_ style names.
2144 ----- Tagged ld64-80.7
2146 2008-01-02 Nick Kledzik <kledzik@apple.com>
2148 <rdar://problem/5572168> BigBear5A18 isn't fully prebound
2149 * src/Options.cpp: make fNeedsModuleTable true for arm
2151 ----- Tagged ld64-80.6
2153 2007-11-30 Nick Kledzik <kledzik@apple.com>
2155 <rdar://problem/5620976> -iphone_version_min
2156 * src/Options.cpp: handle -iphone_version_min option
2159 ----- Tagged ld64-80.5
2161 2007-11-26 Nick Kledzik <kledzik@apple.com>
2163 <rdar://problem/5601142> need to special case some dylibs in seg_addr_table
2164 * src/Options.cpp: retry seg_add_table lookup for a couple of unusual dylibs
2167 ----- Tagged ld64-80.4
2169 2007-11-06 Nick Kledzik <kledzik@apple.com>
2171 * src/MachOReaderRelocatable.hpp: fix parsing of external and scattered thumb branch22 relocs
2172 * unit-tests/test-cases/thumb-blx: add test case to keep blx issues from coming back
2174 ----- Tagged ld64-80.3
2176 2007-11-03 Nick Kledzik <kledzik@apple.com>
2178 * src/MachOReaderRelocatable.hpp: remove recalc of dstAddr which could cause thumb branches to be +2
2179 * src/MachOWriterExecutable.hpp: remove incorrect test for relocateableExternal
2181 ----- Tagged ld64-80.2
2183 2007-11-01 Nick Kledzik <kledzik@apple.com>
2185 * src/ld.cpp: hack my own prototype for log2() until math.h is cleaned up
2188 ----- Tagged ld64-80.1
2190 2007-11-01 Nick Kledzik <kledzik@apple.com>
2192 * ld64.xcodeproj/project.pbxproj: add HEADER_SEARCH_PATHS for cross builds
2193 * src/ld.cpp: temporarily disable LLVM_SUPPORT
2194 * src/MachOWriterExecutable.hpp: Don't use CC_MD5() directly
2197 2007-10-26 Nick Kledzik <kledzik@apple.com>
2199 <rdar://problem/5556038> Cannot build with libm_static.a statically linked
2200 * src/MachOWriterExecutable.hpp: Fix makesExternalRelocatableReference() for -r -d case
2201 * unit-tests/test-cases/tentative-to-real-hidden: add test case
2204 ----- Tagged ld64-80
2206 2007-10-24 Nick Kledzik <kledzik@apple.com>
2208 <rdar://problem/4222696> linker should probably warn about trying to export a hidden symbol
2209 * src/ld.cpp: if using -exported_symbols_list check each hidden atom as it is added to symbol table
2210 * src/Options.h,.cpp: add hasExportMaskList()
2211 * unit-tests/test-cases/exported_symbols_list-hidden: added test case
2214 2007-10-24 Nick Kledzik <kledzik@apple.com>
2216 * src/MachOWriterExecutable.hpp: keep old style dtrace probes externel for kernel builds
2219 2007-10-23 Nick Kledzik <kledzik@apple.com>
2221 <rdar://problem/4556199> unify error and warning messages
2222 <rdar://problem/5546450> -w should suppress warnings
2223 * src/ld.cpp: use warning() function
2224 * src/Options.h: remove emitWarnings()
2225 * src/MachOReaderDylib.hpp: use warning() function
2226 * src/MachOReaderRelocatable.hpp: use warning() function
2227 * src/Options.cpp: use and implement warning()
2228 * src/MachOWriterExecutable.hpp: use warning() function
2229 * unit-tests/test-cases/visibility-warning: verify -w suppresses warnings
2232 2007-10-23 Devang Patel <dpatel@apple.com>
2234 * src/ld.cpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2235 * src/LLVMReader.hpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2236 * src/MachOReaderDylib.hpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2237 * src/ObjectFile.h: Cover arm support inside __OPEN_SOURCE__ macro check.
2238 * src/MachOReaderRelocatable.hpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2239 * src/OpaqueSection.hpp: Cover arm support inside __OPEN_SOURCE__ macro check
2240 * src/MachOWriterExecutable.hpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2241 * src/ObjectDump.cpp: Cover arm support inside __OPEN_SOURCE__ macro check.
2244 2007-10-22 Nick Kledzik <kledzik@apple.com>
2246 * src/Options.cpp: add support for LD_DEAD_STRIP and LD_WARN_COMMONS
2247 * src/MachOReaderRelocatable.hpp: fix problem with -dead_strip of ObjC literal pointers
2250 2007-10-22 Nick Kledzik <kledzik@apple.com>
2252 * src/Options.cpp: have -static arm code link with ld_classic (for now)
2255 2007-10-22 Nick Kledzik <kledzik@apple.com>
2257 <rdar://problem/5396826> Recognize all arm architectures
2258 * src/MachOReaderRelocatable.hpp: add support for all ARM sub-types
2259 * unit-tests/test-cases/cpu-sub-types: add test cases for all combinations of ARM sub-types
2262 2007-10-19 Nick Kledzik <kledzik@apple.com>
2264 * src/*: merge in arm support
2265 * unit-tests/test-cases/*: fix to work for arm and thumb
2267 ----- Tagged ld64-79
2269 2007-10-16 Nick Kledzik <kledzik@apple.com>
2271 * src/MachOWriterExecutable.hpp: if -r mode, always set custom alignment (SET_COMM_ALIGN) on common symbols
2272 * unit-tests/test-cases/visibility-warning-dylib-v-archive/Makefile: fix warning
2273 * unit-tests/test-cases/static-executable/Makefile: fix spurious failure
2276 2007-10-16 Nick Kledzik <kledzik@apple.com>
2278 * src/MachOWriterExecutable.hpp: fix edge case in branch island generation
2281 2007-10-12 Nick Kledzik <kledzik@apple.com>
2283 <rdar://problem/5323449> Add option to create old, slow stubs for i386
2284 * src/ObjectFile.h/.cpp: support -read_only_stubs
2285 * src/MachOWriterExecutable.hpp: enhance StubAtom<x86> to support old style __symbol_stub/__la_symbol_ptr stubs
2286 * unit-tests/test-cases/slow-x86-stubs: add test case
2289 2007-10-12 Nick Kledzik <kledzik@apple.com>
2291 <rdar://problem/5427952> ld64's re-export cycle detection logic prevents use of X11 libGL on Leopard
2292 * src/Options.cpp: in findFileUsingPaths() don't search for embedded dylibs
2293 * unit-tests/test-cases/indirect-path-search/Makefile: added case for a dylib embedded in a framework
2296 2007-10-11 Nick Kledzik <kledzik@apple.com>
2298 <rdar://problem/5451987> add option to disable implicit load commands for indirectly used public dylibs
2299 * src/Options.cpp: add support for -no_implicit_dylibs
2300 * src/ObjectFile.h: add fImplicitlyLinkPublicDylibs
2301 * src/MachOReaderDylib.hpp: test fImplicitlyLinkPublicDylibs before hoisting an implicitly linked dylib
2302 * unit-tests/test-cases/implicit_dylib: add test case
2305 2007-10-11 Nick Kledzik <kledzik@apple.com>
2307 <rdar://problem/5254413> -interposable_list
2308 * src/Options.h/cpp: Add fInterposeList and fInterposeMode to support -interposable_list
2309 * src/MachOWriterExecutable.hpp: pass symbol name to fOptions.interposable()
2310 * unit-tests/test-cases/interposable_list: add test case
2313 2007-10-10 Nick Kledzik <kledzik@apple.com>
2315 <rdar://problem/5529626> If only weak_import symbols are used, linker should use LD_LOAD_WEAK_DYLIB
2316 * src/MachOWriterExecutable.hpp: automatically use LC_LOAD_WEAK_DYLIB if all symbols used from a dylib are weak_import
2317 * unit-tests/test-cases/weak_dylib: added test case
2320 2007-10-10 Nick Kledzik <kledzik@apple.com>
2322 <rdar://problem/5504954> linker does not error when dylib ordinal exceeds 250
2323 * src/MachOWriterExecutable.hpp: error out if ordinals exceed max allowed
2326 2007-10-10 Nick Kledzik <kledzik@apple.com>
2328 <rdar://problem/4067110> overriding 'operator new' or 'operator delete' fails if no weak symbols are present
2329 * src/ld.cpp: at end of checkUndefines() search dylibs for weak versions of any global external symbols
2330 * src/ObjectFile.h: add hasWeakExternals() method to Reader
2331 * src/MachOReaderDylib.hpp: implement hasWeakExternals() method in Reader
2332 * src/ExecutableFile.h: add overridesDylibWeakDefines parameter to write()
2333 * src/MachOWriterExecutable.hpp: use overridesDylibWeakDefines parameter to write()
2334 * unit-tests/test-cases/operator-new: add test case
2337 2007-10-05 Nick Kledzik <kledzik@apple.com>
2339 <rdar://problem/5048861> No warning about tentative definition conflicting with dylib definition
2340 <rdar://problem/5132652> .comm variables in shared library, worked with XCode 2.4.1, broken with XCode 3?
2341 * src/ld.cpp: at end of checkUndefines() verify if any remaining commons conflict with dylibs
2342 * doc/man/man1/ld.1: document -commons and -warn_commons options
2343 * unit-tests/test-cases/tentative-and-dylib: added test case
2346 2007-10-05 Nick Kledzik <kledzik@apple.com>
2348 <rdar://problem/5346331> NS/CFString constants are not dead strippable
2349 * src/MachOReaderRelocatable.hpp: break up __cfstring section into one atom per cfstring, make them coalesable
2350 * unit-tests/test-cases/cfstring-coalesce: added test case
2353 2007-10-05 Nick Kledzik <kledzik@apple.com>
2355 <rdar://problem/5524973> Dead stripping + exported symbols list using wildcards doesn't seem to do the right thing
2356 * src/Options.cpp/h: add hasWildCardExportRestrictList()
2357 * src/ld.cpp: if dead stripping code and have wildcard exports, add all global atoms matching wildcards as roots
2358 * unit-tests/test-cases/exported-symbols-wildcards-dead_strip: added test case
2361 2007-10-04 Nick Kledzik <kledzik@apple.com>
2363 <rdar://problem/5433882> ld shouldn't search /Network/Library/Frameworks by default
2364 * src/Options.cpp: remove /Network/Library/Frameworks/ from default search path
2365 * doc/man/man1/ld.1: document the change
2368 2007-10-04 Nick Kledzik <kledzik@apple.com>
2370 <rdar://problem/5341567> all binaries should get LD_UUID load commands, not just those with DWARF symbols
2371 * src/ld.cpp: default fCreateUUID to be true for non object file output types
2372 * unit-tests/test-cases/no-uuid/Makefile: update test case to match new rules
2375 ----- Tagged ld64-78
2377 2007-09-27 Nick Kledzik <kledzik@apple.com>
2379 <rdar://problem/5476313> range check load commands
2380 * src/MachOReaderDylib.hpp: check that load commands all fit in load command size from header
2381 * src/MachOReaderRelocatable.hpp: check that load commands all fit in load command size from header
2384 2007-09-27 Nick Kledzik <kledzik@apple.com>
2386 <rdar://problem/5433355> Xc8M2540a: ld64 crashes when linking Pascal program
2387 * src/ld.cpp: fix findAtomAndOffset() to handle where there are no function atoms
2390 2007-09-27 Nick Kledzik <kledzik@apple.com>
2392 <rdar://problem/5241179> ADOBE Xcode 3: ld -dead_strip does not work with -init from an archive
2393 * src/ld.cpp: add bool parameter to entryPoint() so -init atom not looked for too soon
2394 * unit-tests/test-cases/dead_strip-init-archive: added test case
2397 2007-09-26 Nick Kledzik <kledzik@apple.com>
2399 <rdar://problem/5459546> Spurious link warnings for inline members of C++ template classes
2400 * src/ld.cpp: check definition kinds before warning about visibility mismatches
2401 * unit-tests/test-cases/visibility-warning: added test case
2404 2007-09-26 Nick Kledzik <kledzik@apple.com>
2406 <rdar://problem/5394172> an empty .o file with zero load commands will crash linker
2407 * src/MachOReaderRelocatable.hpp: have Reader constructor return early of no load commands
2408 * unit-tests/test-cases/empty-object: added test case
2411 2007-09-26 Nick Kledzik <kledzik@apple.com>
2413 <rdar://problem/5453384> 9a527: ppc64 branch islands fail with 4GB pagezeo
2414 * src/MachOWriterExecutable.hpp: start range calculations at start of __text not at zero.
2417 ----- Tagged ld64-77 (Xcode 3.0)
2419 2007-07-23 Nick Kledzik <kledzik@apple.com>
2421 <rdar://problem/5351380> Kernel is linked with some global symbols unsorted
2422 * src/MachOWriterExecutable.hpp: Add NListNameSorter to allow global atoms and extra labels to be sorted
2425 2007-07-20 Nick Kledzik <kledzik@apple.com>
2427 <rdar://problem/5254468> Can't do objc_msgSendSuper dispatches after loading a Fix&Continue bundle
2428 * src/MachOWriterExecutable.hpp: when calculating what kind of reloc to use, never use an
2429 external reloc to reference 32-bit ObjC symbols.
2432 2007-07-20 Nick Kledzik <kledzik@apple.com>
2434 <rdar://problem/5349847> Runtime crash with ICC math library on Leopard
2435 * src/MachOReaderRelocatable.hpp: detect if section starts with a symbol that is not
2436 aligned to section and correct it.
2439 ----- Tagged ld64-76
2441 2007-06-29 Nick Kledzik <kledzik@apple.com>
2443 <rdar://problem/5303718> export hiding does not work for frameworks
2444 * src/MachOReaderDylib.hpp: fix checks in isPublicLocation()
2445 * unit-tests/test-cases/symbol-moving: update to test frameworks as well as dylibs
2448 2007-06-27 Nick Kledzik <kledzik@apple.com>
2450 <rdar://problem/5299907> linker should use undefines from flat dylibs when linking a main flat
2451 * src/ObjectFile.h: added fLinkingMainExecutable
2452 * src/Options.cpp: set up fLinkingMainExecutable
2453 * src/MachOReaderDylib.hpp: when linking a main executable for flat namespace, the reader for
2454 any loaded flat namespace dylib will have a new atoms that has references to all undefined
2455 symbols in the dylib
2456 * unit-tests/test-cases/flat-indirect-undefines: added test case
2457 * doc/man/man1/ld.1: update man page to describe when dylib undefines are used
2460 2007-06-27 Nick Kledzik <kledzik@apple.com>
2462 <rdar://problem/5277857> OpenGL.framework and X11 both have a libGL.dylib which can cause ld to segfault if both are found
2463 * src/MachOReaderDylib.hpp: add assertNoReExportCycles() method
2464 * unit-tests/test-cases/dylib-re-export-cycle: added test case
2467 2007-06-27 Nick Kledzik <kledzik@apple.com>
2469 <rdar://problem/5286462> ld64 has slightly different warning message formats than the old ld
2470 * src/ld.cpp: standardize all warning messages to start with "ld: warning"
2471 * src/MachOWriterExecutable.hpp: ditto
2472 * src/MachOReaderRelocatable.hpp: ditto
2473 * src/MachOReaderDylib.hpp:ditto
2476 2007-06-26 Nick Kledzik <kledzik@apple.com>
2478 <rdar://problem/5297034> -dead_strip can cause duplicate external commons
2479 * src/ld.cpp: don't use discarded coalesced global atoms as dead strip roots
2480 * src/machochecker.cpp: error if duplicate external symbols
2481 * unit-tests/test-cases/commons-coalesced-dead_strip: added test case
2484 2007-06-26 Nick Kledzik <kledzik@apple.com>
2486 <rdar://problem/4135857> update man page that linker does not search indirect libraries with two-level namespace
2487 * doc/man/man1/ld.1: add new "Indirect dynamic libraries" section to man page
2490 2007-06-26 Nick Kledzik <kledzik@apple.com>
2492 <rdar://problem/5285473> Xc9A466: Exports file cannot use Mac line ends
2493 * src/Options.cpp: check for \r or \n when parsing .exp files
2494 * unit-tests/test-cases/exported_symbols_list-eol: added test case
2497 ----- Tagged ld64-75
2499 2007-05-31 Nick Kledzik <kledzik@apple.com>
2501 <rdar://problem/4607755> Simplier, generalized way to re-export dylibs: LC_REEXPORT_DYLIB
2502 * src/MachOWriterExecutable.hpp: Use LC_REEXPORT_DYLIB when targetting 10.5
2505 ----- Tagged ld64-74.5
2507 2007-05-31 Nick Kledzik <kledzik@apple.com>
2509 <rdar://problem/5241902> set OSO timestamp to zero for when building in buildit
2510 * src/ld.cpp: check for RC_RELEASE and if exists set all OSO timestamps to zero
2513 2007-05-30 Nick Kledzik <kledzik@apple.com>
2515 <rdar://problem/5224676> BUILD_STABS now causes ld of xnu to bus error
2516 * src/ld.cpp: Change || to && in collectStabs()
2519 ----- Tagged ld64-74.4
2521 2007-05-18 Nick Kledzik <kledzik@apple.com>
2523 <rdar://problem/5211667> static probes don't work with libraries in dyld shared cache
2524 * src/OpaqueSection.hpp: the __TEXT segment is executable
2527 ----- Tagged ld64-74.3
2529 2007-05-16 Nick Kledzik <kledzik@apple.com>
2531 <rdar://problem/5201463> ppc: linker adds stubs to cstring references
2532 * src/MachOWriterExecutable.hpp: update ppc stubableReference() to only allow high/low references
2533 to be stubed if they reference a symbol in some other dylib.
2534 * unit-tests/test-cases/stub-generation: added test case
2537 2007-05-16 Nick Kledzik <kledzik@apple.com>
2539 <rdar://problem/5008421> ppc64: need to make LOCAL indirect symbol table entry for now local symbol
2540 * src/MachOWriterExecutable.hpp: factored local tests into indirectSymbolIsLocal()
2541 * unit-tests/test-cases/non-lazy-r: added test case
2544 2007-05-15 Nick Kledzik <kledzik@apple.com>
2546 <rdar://problem/5198807> ld64 drops fix&continue bit in __OBJC, __image_info.
2547 * src/MachOReaderRelocatable.hpp: implement objcReplacementClasses()
2550 2007-05-15 Nick Kledzik <kledzik@apple.com>
2552 <rdar://problem/5066152> support __image_info in __DATA segment for 64-bits
2553 * src/MachOReaderRelocatable.hpp: use strncmp() for __objc_imageinfo since it is 16 bytes long
2554 * src/MachOWriterExecutable.hpp: specialize segment/section names for synthesized objc image info section
2557 2007-05-15 Nick Kledzik <kledzik@apple.com>
2559 * unit-tests/include/common.makefile: set COMPILER_PATH so harness works with latest compiler
2562 ----- Tagged ld64-74.2
2564 2007-05-11 Nick Kledzik <kledzik@apple.com>
2566 <rdar://problem/5195447> ld64-74.1 breaks libstdc++ DejaGnu test (G5 only)
2567 * src/MachOWriterExecutable.hpp: don't stub a reference if the target offset is non-zero
2570 ----- Tagged ld64-74.1
2572 2007-05-09 Nick Kledzik <kledzik@apple.com>
2574 * src/Options.h: add emitWarnings()
2575 * src/Options.cpp: wire up -w to emitWarnings()
2578 2007-05-09 Nick Kledzik <kledzik@apple.com>
2580 <rdar://problem/5137285> ld64 won't link wine (regression from Tiger)
2581 * src/Architectures.hpp: add x86::kPointerDiff16 and x86::kPCRel16
2582 * src/MachOReaderRelocatable.hpp: add support to parse new relocs
2583 * src/MachOWriterExecutable.hpp: add support fo new relocs
2586 2007-05-08 Nick Kledzik <kledzik@apple.com>
2588 <rdar://problem/5182537> need way for ld and dyld to see different exported symbols in a dylib
2589 * src/MachOReaderDylib.hpp: update parse and use $ld$ symbols
2590 * src/Options.h: move VersionMin to ReaderOptions
2591 * src/ObjectFile.h: move VersionMin to ReaderOptions
2592 * src/Options.cpp: move VersionMin to ReaderOptions
2593 * src/MachOWriterExecutable.hpp: move VersionMin to ReaderOptions
2594 * unit-tests/test-cases/symbol-moving: added test case
2597 2007-05-03 Nick Kledzik <kledzik@apple.com>
2599 <rdar://problem/5181105> typo in error message for linking -pie
2600 * src/MachOWriterExecutable.hpp: fix typo in error messages
2603 ----- Tagged ld64-74
2605 2007-05-03 Nick Kledzik <kledzik@apple.com>
2607 <rdar://problem/5171880> ld64 can't find @executable _path relative dylibs from our umbrella frameworks
2608 <rdar://problem/4019497> ld64 should handle linking against dylibs that have @loader_path based dylib load commands
2609 * src/ObjectFile.h: add from parameter to findDylib()
2610 * src/MachOReaderDylib.hpp: supply from parameter to findDylib()
2611 * src/ld.cpp: use from parameter for @loader_path substitution in findDylib()
2612 * unit-tests/test-cases/re-export-relative-paths: added test case
2615 2007-05-02 Nick Kledzik <kledzik@apple.com>
2617 * src/ObjectFile.h: add fLogObjectFiles and fLogAllFiles
2618 * src/Options.cpp: hook up -t to fLogAllFiles and -whatsloaded to fLogObjectFiles
2619 * src/MachOReaderDylib.hpp: log if fLogAllFiles
2620 * src/MachOReaderRelocatable.hpp: log if fLogObjectFiles or fLogAllFiles
2621 * src/MachOReaderArchive.hpp: log if fLogAllFiles
2622 * doc/man/man1/ld.1: update man page
2625 2007-05-02 Nick Kledzik <kledzik@apple.com>
2627 <rdar://problem/5177848> typo in message, frameowrk
2628 * src/Options.cpp: fix typo
2631 2007-05-01 Nick Kledzik <kledzik@apple.com>
2633 <rdar://problem/4977301> "ld" man page is missing the description for many options
2634 * doc/man/man1/ld.1: add documentation on all obsolete options
2637 2007-05-01 Nick Kledzik <kledzik@apple.com>
2639 <rdar://problem/5113424> ld doesn't handle -mlong-branch .o files that have had local symbols stripped
2640 <rdar://problem/4965359> warning about dwarf line info with -mlong-branch
2641 * src/MachOReaderRelocatable.hpp: don't lop -mlong-branch stubs off end of functions
2642 * src/MachOWriterExecutable.hpp: allow code references besides BR24 to be stubable
2645 2007-04-30 Nick Kledzik <kledzik@apple.com>
2647 <rdar://problem/5065659> unable to link VTK because __textcoal_nt too large
2648 * src/MachOReaderRelocatable.hpp: when doing a final link map __textcoal_nt to __text
2651 2007-04-30 Nick Kledzik <kledzik@apple.com>
2653 <rdar://problem/5062685> ld does not report error when -r is used and exported symbols are not defined.
2654 <rdar://problem/4637139> ld leaves global common symbols not in exported symbols list.
2655 * src/ld.cpp: stop special casing -r mode in checkUndefines()
2656 * src/MachOWriterExecutable.hpp: don't create proxy atom in -r mode if it is supposed to be exported.
2657 mark tentative definitions are private extern in -r mode even without -keep_private_externs
2658 * unit-tests/test-cases/exported_symbols_list-r: added test case
2661 2007-04-27 Nick Kledzik <kledzik@apple.com>
2663 <rdar://problem/5137732> ld should keep looking when it finds a weak definition in a dylib
2664 * src/ld.cpp: modified addJustInTimeAtoms() to keep looking when a weak defintion is found
2665 * unit-tests/test-cases/weak-def-ordinal: added test case
2668 2007-04-27 Nick Kledzik <kledzik@apple.com>
2670 <rdar://problem/5166572> better error message for indirect dylibs missing required architecture
2671 * src/ld.cpp: when loading indirect dylib add path to error messages
2674 2007-04-25 Nick Kledzik <kledzik@apple.com>
2676 <rdar://problem/5109373> the i386 slice of dyld does not need __IMPORT segment
2677 * src/ObjectFile.h: add fForDyld
2678 * src/Options.cpp: set up fForDyld
2679 * src/MachOReaderRelocatable.hpp: if fForDyld, change __IMPORT segment to __DATA
2680 * src/MachOWriterExecutable.hpp: recognize __DATA/__pointers in dyld as a non-lazy section
2683 2007-04-24 Nick Kledzik <kledzik@apple.com>
2685 <rdar://problem/5008421> ppc64: need to make LOCAL indirect symbol table entry for now local symbol
2686 * src/MachOWriterExecutable.hpp: use INDIRECT_SYMBOL_LOCAL for any non-global symbol
2687 * unit-tests/test-cases/strip_local: update test case
2690 2007-04-24 Nick Kledzik <kledzik@apple.com>
2692 <rdar://problem/5150407> ld64 -sectorder and -order_file files don't accept white space following the :
2693 * src/Options.cpp: prune white space after colon and before symbol name
2694 * unit-tests/test-cases/order_file: update test case to have a space after the colon
2697 2007-04-24 Nick Kledzik <kledzik@apple.com>
2699 <rdar://problem/5055233> ld64 corrupts debug symbol table entries, nm doesn't print them
2700 * src/MachOWriterExecutable.hpp: properly set ilocalsym in module table
2703 2007-04-24 Nick Kledzik <kledzik@apple.com>
2705 <rdar://problem/5066152> support __image_info in __DATA segment for 64-bits
2706 * src/MachOReaderRelocatable.hpp: look for new objc info section name too
2709 2007-04-24 Nick Kledzik <kledzik@apple.com>
2711 * src/MachOWriterExecutable.hpp: fix -non_global_symbols_strip_list to work with -r
2712 * unit-tests/test-cases/local-symbol-partial-stripping: update test case
2716 ----- Tagged ld64-73.7
2718 2007-05-10 Nick Kledzik <kledzik@apple.com>
2720 <rdar://problem/5194804> can't use dtrace static probes in x86_64 dylib
2721 * src/MachOWriterExecutable.hpp: x86_64:kPointerDiff32 is ok in shared region
2722 * unit-tests/test-cases/dtrace-static-probes: update to build dylib too
2725 2007-05-09 Nick Kledzik <kledzik@apple.com>
2727 <rdar://problem/5191610> 9A430: using -dead_strip with static dtrace probes causes ld to crash
2728 * src/ld.cpp: fix markLive() to look at right name in dtrace probe refernce
2729 * unit-tests/test-cases/dtrace-static-probes: added -dead_strip case
2732 ----- Tagged ld64-73.6
2734 2007-04-17 Nick Kledzik <kledzik@apple.com>
2736 <rdar://problem/5140897> Add options to do partial stripping of local symbols
2737 * src/MachOWriterExecutable.hpp: use fOptions.keepLocalSymbol()
2738 * src/Options.cpp: implement -non_global_symbols_no_strip_list and -non_global_symbols_strip_list
2739 * src/Options.h: replace stripLocalSymbols() with localSymbolHandling() and keepLocalSymbol()
2740 * doc/man/man1/ld.1: document -non_global_symbols_no_strip_list and -non_global_symbols_strip_list
2741 * unit-tests/test-cases/local-symbol-partial-stripping: added test case
2744 ----- Tagged ld64-73.5
2746 2007-04-17 Nick Kledzik <kledzik@apple.com>
2748 <rdar://problem/5129379> ld64-73.3 XBS logging incorrectly reporting "direct" dynamic libraries
2749 * src/ld.cpp: restore direct vs indirect library for LD_TRACE_DYLIBS logging
2752 2007-04-16 Nick Kledzik <kledzik@apple.com>
2754 <rdar://problem/5067034> data initialized to a weak imported symbol is missing relocation
2755 * src/MachOWriterExecutable.hpp: check for A::kPointerWeakImport in buildExecutableFixups()
2756 * unit-tests/test-cases/weak_import: updated test case to catch this problem
2759 2007-04-13 Nick Kledzik <kledzik@apple.com>
2761 <rdar://problem/5071047> Support -U
2762 * src/MachOWriterExecutable.hpp: create proxies for -U symbols
2763 * src/Options.cpp: process -U
2764 * src/Options.h: add allowedUndefined() and someAllowedUndefines()
2765 * src/ld.cpp: create proxies for -U symbols
2766 * doc/man/man1/ld.1: document -U and -undefined options
2767 * unit-tests/test-cases/undefined-dynamic-lookup: added test case
2770 ----- Tagged ld64-73.4
2772 2007-04-12 Nick Kledzik <kledzik@apple.com>
2774 <rdar://problem/5125280> ld changes needed to support read-only DOF
2775 * src/Options.cpp: remove -read_only_dof
2776 * src/Options.h: remove fReadOnlyDOFs
2777 * src/ld.cpp: only generate read-only DOF sections
2780 ----- Tagged ld64-73.3.1
2782 2007-04-13 Nick Kledzik <kledzik@apple.com>
2784 <rdar://problem/5130496> -framework vecLib -framework Accelerate causes bad ordinals
2785 * src/MachOWriterExecutable.hpp: fix bug optimizeDylibReferences() when there are two readers with same install name
2788 ----- Tagged ld64-73.3
2790 2007-04-03 Nick Kledzik <kledzik@apple.com>
2792 * src/ld.cpp: read-only-dofs should use 32-bit offsets for x86_64
2793 * src/MachOReaderDylib.hpp: if "public" re-export is not marked implict, still mark it as re-exported
2796 2007-04-02 Nick Kledzik <kledzik@apple.com>
2798 <rdar://problem/5105971> if replacement file for -dylib_file is missing, warn instead of error
2799 * src/ld.cpp: a try/catch to turn -dylib_file error into a warning.
2800 * unit-tests/test-cases/dylib_file-missing: add test case
2801 * doc/man/man1/ld.1: update man page about -dead_strip_dylibs
2804 ----- Tagged ld64-73.2
2806 2007-03-31 Nick Kledzik <kledzik@apple.com>
2808 <rdar://problem/5102873> ld64-73: atom sorting error with duplicate zero sized bss symbols
2809 * src/MachOReaderRelocatable.hpp: suppress warning on sorting zero size zero fill atoms
2811 2007-03-31 Nick Kledzik <kledzik@apple.com>
2813 <rdar://problem/5102845> ld64-73 fails anything linking with -lm
2814 * src/ld.cpp: when processing dylbs that are sylinks ensure that fDylibMap contains all paths
2815 * src/MachOWriterExecutable.hpp: when dead stripping dylibs and renumbering ordinals make sure
2816 aliases dylib get renumbered too
2817 * unit-tests/test-cases/dylib-aliases: added
2820 ----- Tagged ld64-73.1
2822 2007-03-30 Nick Kledzik <kledzik@apple.com>
2824 * src/MachOWriterExecutable.hpp: back out use of LC_REEXPORT_DYLIB until rdar://problem/5009909 is in build fleet
2827 ----- Tagged ld64-73
2829 2007-03-30 Nick Kledzik <kledzik@apple.com>
2831 <rdar://problem/4175790> ER: -dead_strip_dylibs
2832 <rdar://problem/3904828> linker should add implicit load commands for indirectly used public dylibs
2833 * src/ObjectFile.h: change dylib reader interface to implictly/explicitlyLinked
2834 * src/ld.cpp: use new dylib reader interface
2835 * src/Options.h: add deadStripDylibs()
2836 * src/Options.cpp: support -dead_strip_dylibs
2837 * src/MachOReaderDylib.hpp: use new dylib reader interface
2838 * src/MachOWriterExecutable.hpp: remove dylib load commands for unused dylibs and alter ordinals
2839 * unit-tests/test-cases/re-export-optimizations: added
2840 * unit-tests/test-cases/dead_strip_dylibs: added
2843 2007-03-30 Nick Kledzik <kledzik@apple.com>
2845 * src/Options.cpp: enable -lfoo to search for libfoo.so as well as libfoo.dylib,
2846 remove seg addr table hack for transitioning to new linker
2848 2007-03-30 Nick Kledzik <kledzik@apple.com>
2850 <rdar://problem/5073800> ADOBE XCODE3: Linker is slow with large C++ .o files
2851 * src/MachOReaderRelocatable.hpp: the compiler generates stubs to weak functions in the
2852 same translation unit. Don't treat those like the spurios stubs to static functions.
2855 2007-03-29 Nick Kledzik <kledzik@apple.com>
2857 <rdar://problem/4739044> ld64 should link mach_kernel during xnu builds to support dtrace
2858 * src/MachOReaderRelocatable.hpp: To handle duplicate labels properly, rework how atoms sizes are set
2859 by iterating through sorted fAtoms rather than fAddrToAtom, . Change default alignment of commons
2860 to be the natural alignment of the size rounded up to the closest power of two and max it at 12.
2861 Build atoms in reverse symbol table order so that global atoms are constructed before locals.
2862 This assures that if there is a global and local label at the same location, the global label
2863 will become the atom's name and the local will be an alias. Properly handle a label
2864 at the end of a section. Handle R_ABS in relocations. Handle sect-diff relocs with addends.
2865 Don't auto-strip 'l' symbols in static executables (mach_kernel).
2866 * src/OpaqueSection.hpp: opaque_section now has an ordinal
2867 * src/ld.cpp: opaque_section now requires an ordinal
2868 * src/ObjectFile.h: add ReaderOptions.fForStatic
2869 * src/Options.cpp: set fForStatic when building a static executable
2870 * src/MachOWriterExecutable.hpp: add from atom to StubAtom<ppc>. Properly write out i386
2871 sect-diff relocs with addends. properly write out ppc PICbase relocs where pic base
2875 2007-03-27 Nick Kledzik <kledzik@apple.com>
2877 <rdar://problem/5085863> Typo in ld man page (-exported_symbols_list)
2878 * doc/man/man1/ld.1: fix typo
2881 2007-03-26 Nick Kledzik <kledzik@apple.com>
2883 <rdar://problem/4727750> consider generating LC_UUID from a checksum of the file
2884 * src/Options.h: change emitUUID() to getUUIDMode()
2885 * src/Options.cpp: support -random_uuid
2886 * src/MachOWriterExecutable.hpp: set uuid to be md5 hash of entire output file
2889 2007-03-24 Nick Kledzik <kledzik@apple.com>
2891 * src/MachOWriterExecutable.hpp: restructure writeAtoms() to copy all atoms in memory if possible
2894 2007-03-24 Nick Kledzik <kledzik@apple.com>
2896 <rdar://problem/5082603> ld -r of stripped .o file can incorrectly merge non-lazy pointers
2897 * src/MachOWriterExecutable.hpp: when generating a .o file, non-lazy pointer with target offsets should be
2898 encoded as LOCAL in the indirect symbol table
2899 * unit-tests/test-cases/stripped-indirect-symbol-table: added test case
2902 2007-03-23 Nick Kledzik <kledzik@apple.com>
2904 <rdar://problem/5084564> SWB: ld64-72 errors building with gcc-4.2
2905 * src/MachOReaderDylib.hpp: add curly brackets in switch cases
2906 * src/MachOWriterExecutable.hpp: rearrange classes so there are no template specialization forward references
2909 2007-03-23 Nick Kledzik <kledzik@apple.com>
2911 * src/ld.cpp: fix -print_statistics when using -dead_strip
2914 2007-03-23 Nick Kledzik <kledzik@apple.com>
2916 * src/MachOReaderRelocatable.hpp: generate better names for non-lazy pointers to the interior of atoms
2919 2007-03-16 Nick Kledzik <kledzik@apple.com>
2921 * src/MachOWriterExecutable.hpp: speed up ld -r a little by reversing relocs en mas
2924 2007-03-16 Nick Kledzik <kledzik@apple.com>
2926 <rdar://problem/4975277> ld Bus Error on missing command line arguments
2927 * src/Options.cpp: check next argv[] is not NULL
2930 2007-03-16 Nick Kledzik <kledzik@apple.com>
2932 <rdar://problem/4832049> need to be able to order symbols in anonymous namespaces
2933 * src/ld.cpp: add logic to do fuzzy matching of symbols with anonymous namespace usage
2934 * unit-tests/test-cases/order_file-ans: added test case
2937 2007-03-16 Nick Kledzik <kledzik@apple.com>
2939 <rdar://problem/5042552> headerpad_max_install_names deprecated for 64-bit
2940 * src/ld.cpp: make sure dylib load command order matches command line order
2941 * src/Options.h: add maxMminimumHeaderPad()
2942 * src/Options.cpp: add maxMminimumHeaderPad() set by -headerpad_max_install_names
2943 * src/src/MachOWriterExecutable.hpp: check maxMminimumHeaderPad()
2944 * doc/man/man1/ld.1: update man page about -headerpad_max_install_names
2947 2007-03-16 Nick Kledzik <kledzik@apple.com>
2949 <rdar://problem/4592484> Linker returns success although exported symbols are undefined.
2950 * src/ld.cpp: turn missing symbols back into an error
2953 2007-03-16 Nick Kledzik <kledzik@apple.com>
2955 <rdar://problem/4019497> ld64 should handle linking against dylibs that have @loader_path based dylib load commands
2956 * unit-tests/test-cases/loader_path: added test case
2959 2007-03-16 Nick Kledzik <kledzik@apple.com>
2961 <rdar://problem/3904828> linker should add implicit load commands for indirectly used public dylibs
2962 <rdar://problem/4142277> Indirect libraries should be found using -F and -L options
2963 <rdar://problem/4607755> Simplier, generalized way to re-export dylibs: LC_REEXPORT_DYLIB
2964 * src/ld.cpp: reworked all dylib processing. Readers can now add the dylib list.
2965 * src/Options.h: add findFileUsingPaths()
2966 * src/MachOReaderDylib.hpp: look in re-exported children instead of requring linker to do that
2967 * src/ObjectFile.h: add processIndirectLibraries(), remove getDependentLibraryPaths()
2968 * src/machochecker.cpp: support LC_REEXPORT_DYLIB
2969 * src/ExecutableFile.h: simplify DyLibUsed
2970 * src/Options.cpp: add findFileUsingPaths(). add new re-export options
2971 * src/MachOWriterExecutable.hpp: Use LC_REEXPORT_DYLIB when targetting 10.5
2972 * doc/man/man1/ld.1: updated with new re-export options
2973 * unit-tests/test-cases/indirect-path-search: added tests that -F and -L work with indirect dylibs
2974 * unit-tests/test-cases/re-export-cases: added tests for all combinations of re-exporting
2977 2007-03-14 Nick Kledzik <kledzik@apple.com>
2979 <rdar://problem/4982400> sort external relocations to optimize dyld performance
2980 * src/MachOWriterExecutable.hpp: added ExternalRelocSorter
2981 * src/machochecker.cpp: verify external relocations are grouped by symbol number
2982 * unit-tests/test-cases/external-reloc-sorting: added test case
2985 ----- Tagged ld64-72
2987 2007-03-06 Nick Kledzik <kledzik@apple.com>
2989 * src/Options.cpp: ignore .objc_category_name_* symbols in .exp files
2992 2007-03-06 Nick Kledzik <kledzik@apple.com>
2994 * src/Options.cpp: stop special casing mach_kernel and instead requre kernel to be built with -new_linker
2997 2007-03-06 Nick Kledzik <kledzik@apple.com>
2999 <rdar://problem/5044253> ld64-72 (experimental) is causing DejaGnu test failures
3000 * src/MachOWriterExecutable.hpp: add optimizableGOTReferenceKind() to track GOT uses that cannot be optimized
3003 2007-03-06 Nick Kledzik <kledzik@apple.com>
3005 <rdar://problem/5026135> minimum header padding should be 32 to allow code signing
3006 * src/Options.cpp: initialize fMinimumHeaderPad to 32
3007 * src/MachOWriterExecutable.hpp: better calculation of header padding
3010 2007-03-06 Nick Kledzik <kledzik@apple.com>
3012 <rdar://problem/5033206> Linker crashes with -flat_namespace against two-level dylibs that might have re-exports
3013 * src/ld.cpp: flat namespace should not allow NULL indirect readers
3016 2007-03-06 Nick Kledzik <kledzik@apple.com>
3018 * src/MachOReaderRelocatable.hpp: don't error on S_COALESCED sections with anonymous atoms
3019 * src/MachOWriterExecutable.hpp: set MH_PIE bit when linking -pie
3020 * ld64.xcodeproj/project.pbxproj: don't echo environment when running unit test
3023 2007-03-01 Nick Kledzik <kledzik@apple.com>
3025 * doc/man/man1/ld.1: Add descriptions to all "rarely used options"
3028 2007-03-01 Nick Kledzik <kledzik@apple.com>
3030 <rdar://problem/4971033> Remove support for Essential Symbols: Warn about use of -Sp option; remove man page entry
3031 * src/Options.cpp: make -Sp obsolete
3032 * doc/man/man1/ld.1: make -Sp obsolete
3035 2007-03-01 Nick Kledzik <kledzik@apple.com>
3037 <rdar://problem/5040314> Support -pie
3038 * src/Options.h: Add positionIndependentExecutable()
3039 * src/Options.cpp: Support -pie option to set positionIndependentExecutable()
3040 * src/MachOWriterExecutable: if -pie is used, add extra local relocations and error if any
3041 absolute addressing is used
3044 2007-03-01 Nick Kledzik <kledzik@apple.com>
3046 <rdar://problem/4739044> ld64 should link mach_kernel during xnu builds to support dtrace
3047 * src/ld.cpp: Ensure segments are laid out in discovery order. Add support for kAbsoluteSymbol.
3048 Warn when merging symbols of different visiblity. Warn when a tentative definition
3049 is replaced by one a real definition with a smaller size. Lay out __common section
3050 so that ones built with -fno-commons come before regular commons.
3051 * src/ObjectFile.h: remove SegmentOffset ivar and getter/setters
3052 * src/machochecker.cpp: allow images with no r/w segments
3053 * src/MachOReaderRelocatable: Add AbsoluteAtom. Sort tentative definitions by name instead of by size
3054 Add support for custom commons alignment.
3055 * src/Options.cpp: Fix spurious -sectalign warnings. Don't use ld_classic when linking mach_kernel
3056 * src/MachOWriterExecutable.hpp: Support kAbsoluteSymbol atoms. In -r mode, set custom alignment
3057 for commons if alignment is not its size. Support global __dtrace_probe labels.
3058 * src/ObjectDump.cpp: add support for kAbsoluteSymbol atoms.
3059 * unit-tests/test-cases/commons-alignment: Added test case for custom commons alignment
3060 * unit-tests/test-cases/absolute-symbol: Added test case for basic absolute symbols
3061 * unit-tests/test-cases/segment-order: Added test case that segments lay out in discovery order
3062 * unit-tests/test-cases/commons-order: Added test case that commons lay out correctly
3063 * unit-tests/test-cases/end-label: Added test case that a label used to mark the end of a section does not
3064 get associcated with the next section.
3067 2007-02-23 Nick Kledzik <kledzik@apple.com>
3069 <rdar://problem/3965017> gcc-5005: DejaGnu failures due to -frepo
3070 * src/ld.cpp: Add quotes to referenced from name to make collect2 and -frepo happy
3073 2007-02-22 Nick Kledzik <kledzik@apple.com>
3075 * src/MachOWriterExecutable.hpp: rework how padding after load commands is calculated
3078 2007-02-21 Nick Kledzik <kledzik@apple.com>
3080 * src/MachOWriterExecutable.hpp: extend special case of __mh_execute_header to static executables too
3083 2007-02-21 Nick Kledzik <kledzik@apple.com>
3085 <rdar://problem/3882294> gcc link map option ( "-M" ) should be redirectable to file
3086 * doc/man/man1/ld.1: added -map option description
3087 * src/Options.h: added generatedMapPath()
3088 * src/Options.cpp: set up generatedMapPath() if -map option is used
3089 * src/MachOWriterExecutable.hpp: add writeMap() method to generate map file
3092 2007-02-19 Nick Kledzik <kledzik@apple.com>
3094 <rdar://problem/4557734> Implement GOT Load elimination optimization
3095 * src/ld.cpp: track size of all atoms and if > 2GB sort large zero-fill atoms to end
3096 * src/MachOWriterExecutable.hpp: If image size < 2GB, only generate GOT entries if value must be
3097 updatable by dyld. If > 2GB, only eliminate GOT entries to non-zero-fill atoms. Any use
3098 of an eliminated GOT entry has its code changed from MOVQ _foo@GOT(%rip) to LEAQ _foo(%rip).
3099 * unit-tests/test-cases/large-data: added
3100 * unit-tests/test-cases/got-elimination: added
3103 ----- Tagged ld64-71.2
3105 2007-02-13 Nick Kledzik <kledzik@apple.com>
3107 <rdar://problem/4995303> new ld ignores -segprot option
3108 * src/Options.h: expose customSegmentProtections()
3109 * src/Options.cpp: parse -segprot option and populate customSegmentProtections()
3110 * src/MachOWriterExecutable.hpp: use customSegmentProtections()
3113 2007-02-13 Nick Kledzik <kledzik@apple.com>
3115 <rdar://problem/4988068> i386 -stack_addr doesn't work
3116 * src/MachOWriterExecutable.hpp: use correct offset into thread state record
3119 ----- Tagged ld64-71.1
3121 2007-02-07 Nick Kledzik <kledzik@apple.com>
3123 * src/ld.cpp: sort __OBJC2 segment to be next to __OBJC segment
3126 2007-02-07 Nick Kledzik <kledzik@apple.com>
3128 * src/Options.cpp: change missing -seg_addr_table from an error to a warning
3131 2007-02-06 Nick Kledzik <kledzik@apple.com>
3133 <rdar://problem/4977311> Leopard 9A357: -dylib_file broken?
3134 * src/MachOWriterExecutable.hpp: remove use of fInstallPathOverride
3135 * src/Options.cpp: wire up -dylib_file option
3136 * src/Options.h: remove fInstallPathOverride. add fDylibOverrides
3137 * src/ld.cpp: check dylibOverrides() for indirect libraries
3138 * unit-tests/test-cases/dylib_file: add test case
3141 2007-02-05 Nick Kledzik <kledzik@apple.com>
3143 * src/MachOReaderDylib.hpp: don't warn about zero size __image_info sections
3146 2007-02-04 Rick Balocca <rbalocca@apple.com>
3147 Enable the failing cases for missing command line arguments
3149 2007-02-04 Rick Balocca <rbalocca@apple.com>
3150 Make sure that all .o's are checked by ObjectDump
3151 and all macho are checked by machochecker
3153 2007-02-04 Rick Balocca <rbalocca@apple.com>
3154 Fix an endian problem with machochecker
3155 Fix blank-stubs Makefile
3157 ----- Tagged ld64-71
3159 2007-02-02 Rick Balocca <rbalocca@apple.com>
3160 blank-stubs test case: handle the case of a native ppc compile--this
3161 sets the subtype, which must be passed to lipo
3163 2007-02-01 Rick Balocca <rbalocca@apple.com>
3164 make cpu-sub-types test more robust
3166 2007-02-01 Rick Balocca <rbalocca@apple.com>
3167 auto-arch tests were resulting in a false FAILs
3169 2007-02-01 Rick Balocca <rbalocca@apple.com>
3170 test cpu-sub-types was resulting in a false FAIL
3172 2007-02-01 Nick Kledzik <kledzik@apple.com>
3174 <rdar://problem/4969335> STD:VSC: c99 -o writes to file that does not have write permission
3175 * src/MachOWriterExecutable.hpp: check file is writable before using it
3177 2007-02-01 Nick Kledzik <kledzik@apple.com>
3179 <rdar://problem/4965743> debug map (N_OSO) timestamps for object files in ranlib archive are incorrect
3180 * src/MachOReaderArchive.hpp: parse modTime for .o files out of archive header
3182 2007-01-31 Nick Kledzik <kledzik@apple.com>
3184 <rdar://problem/4967535> 9A354: ld -all_load does *NOT* produce the same dSYM as *.o or -u
3185 * src/ld.cpp: when using -all_load don't assume that all atoms have same reader
3186 * unit-tests/test-cases/dwarf-archive-all_load: added
3188 ----- Tagged ld64-70.1
3190 2007-01-31 Nick Kledzik <kledzik@apple.com>
3192 * src/MachOWriterExecutable.hpp: in addObjectRelocs_powerpc() mask scattered r_address to 16-bits
3194 ----- Tagged ld64-70
3197 2007-01-30 Nick Kledzik <kledzik@apple.com>
3199 <rdar://problem/4810668> linker should verify GC consistency of modules being linked into library
3200 <rdar://problem/4474195> Support cpu-sub-types for ppc
3201 * src/ObjectFile.h: Add getObjCConstraint() and getCpuConstraint()
3202 * src/MachOReaderRelocatable.hpp: don't make atom for __image_info section, instead parse constaints
3203 * src/MachOReaderDylib.hpp: look at __image_info content to get constaints
3204 * src/ld.cpp: add updateContraints() and checkObjc()
3205 * src/MachOWriterExecutable.hpp: add ObjCInfoAtom to sythesize __image_info content
3208 2007-01-28 Nick Kledzik <kledzik@apple.com>
3210 src/*: remove ObjectFile::requiresFollowOnAtom() method
3213 2007-01-28 Nick Kledzik <kledzik@apple.com>
3215 src/ld.cpp: enable LLVM_SUPPORT by default
3216 src/LLVMReader.hpp: don't use absolute paths for llvm headers and libraries
3219 2007-01-26 Rick Balocca <rbalocca@apple.com>
3220 * src/ObjectDump.cpp: The usage() message was incorrect.
3223 2007-01-25 Rick Balocca <rbalocca@apple.com>
3224 * unit-tests/test-cases/zero-fill3: It was reporting FAIL on ld64 error return.
3225 It should have been checking for non-error return.
3228 2007-01-24 Nick Kledzik <kledzik@apple.com>
3230 <rdar://problem/4952297> x86 fast stubs should not cross 64-byte boundries
3231 * src/MachOWriterExecutable.hpp: for x86, 64-byte align __jump_table section
3232 and make 64-btye crossing stubs be empty entries with indirect symbol table
3233 entry of INDIRECT_SYMBOL_ABS
3236 2007-01-19 Nick Kledzik <kledzik@apple.com>
3238 * src/Options.h: add readOnlyx86Stubs()
3239 * src/Options.cpp: support -read_only_stubs
3240 * src/MachOWriterExecutable.hpp: make __IMPORT segment not writable if -read_only_stubs is used
3243 2007-01-16 Eric Christopher <echristo@apple.com>
3245 <rdar://problem/4856341> ld64 --help isn't recognized
3246 * src/Options.cpp (Options::parse): Support --help and -help.
3249 2007-01-15 Nick Kledzik <kledzik@apple.com>
3251 * src/MachOFileAbstraction.hpp: add range checking on macho_scattered_relocation_info::set_r_address()
3254 2007-01-14 Nick Kledzik <kledzik@apple.com>
3256 <rdar://problem/4514409> Support wildcards in contents of -exported_symbols_list
3257 * src/Options.h: add SetWithWildcards class
3258 * src/Options.cpp: add -exported_symbol and -unexported_symbol and use SetWithWildcards
3259 * doc/man/man1/ld.1: add -exported_symbol and wildcard explanation
3260 * unit-tests/test-cases/exported-symbols-wildcards: added test case
3263 2007-01-10 Nick Kledzik <kledzik@apple.com>
3265 <rdar://problem/4868270> [U]SDT probes should use C calling convention
3266 * src/Options.cpp: Add -read_only_dof
3267 * src/ld.cpp: create __dof section(s) based on probe and isenabled sites
3268 * src/MachOReaderRelocatable.hpp: parse new sdt 2.0 probes encoded in .o files
3269 * src/MachOWriterExecutable.hpp: handle regenerating dtrace probes into .o files
3270 * unit-tests/test-cases/dtrace-static-probes: added test case
3273 ----- Tagged ld64-69.8
3275 2007-01-30 Nick Kledzik <kledzik@apple.com>
3277 <rdar://problem/4964508> Support LD_FORCE_NO_SEG_ADDR_TABLE
3278 * src/Options.cpp: Support LD_FORCE_NO_SEG_ADDR_TABLE
3281 ----- Tagged ld64-69.7
3283 2007-01-25 Nick Kledzik <kledzik@apple.com>
3285 <rdar://problem/4949507> Leopard9A351: CFM Apps Are Broken because CFM glue is missing
3286 * src/MachOReaderRelocatable.hpp: check S_ATTR_NO_DEAD_STRIP in dontDeadStrip()
3289 ----- Tagged ld64-69.6
3291 2007-01-24 Nick Kledzik <kledzik@apple.com>
3293 <rdar://problem/4947347> LD_TRACE_ARCHIVES should only print out when a .o is actually used from an archive
3294 * src/ld.cpp: create and use logArchive()
3297 ----- Tagged ld64-69.5
3299 2007-01-22 Nick Kledzik <kledzik@apple.com>
3301 <rdar://problem/4946075> 9A350: can't link ppc programs with ld_classic
3302 * src/Options.cpp: Remove support for LD_NO_CLASSIC_LINKER. Add support for -classic_linker
3305 ----- Tagged ld64-69.4
3307 2007-01-17 Nick Kledzik <kledzik@apple.com>
3309 <rdar://problem/4925645> QTComponents does not link with ld64
3310 * src/MachOReaderRelocatable.hpp: handle N_RSYM and N_PSYM stabs
3313 ----- Tagged ld64-69.3
3315 2007-01-03 Nick Kledzik <kledzik@apple.com>
3317 * src/Options.cpp: If the same dylib is specified twice and the second is specified weak, make it weak
3320 ----- Tagged ld64-69.2
3322 2006-12-18 Nick Kledzik <kledzik@apple.com>
3324 <rdar://problem/4889729> -dead_strip without -exported_symbols_list should not strip global functions from archives
3325 * src/ld.cpp: when adding a .o file from an archive, add all its global symbols to live roots
3326 * unit-tests/test-cases/dead_strip-archive: added
3329 2006-12-18 Nick Kledzik <kledzik@apple.com>
3331 <rdar://problem/4889409> flat_namespace main executables do not need to indirect interior references
3332 * src/MachOWriterExecutable.hpp: don't indirect references to global symbols in main executables
3333 * unit-tests/test-cases/flat-main: updated to test for indirection
3334 * unit-tests/test-cases/flat-dylib: added
3337 ----- Tagged ld64-69.1
3339 2006-12-15 Nick Kledzik <kledzik@apple.com>
3341 <rdar://problem/4886721> -flat_namespace does not work with -mdynamic-no-pic
3342 * src/MachOWriterExecutable.hpp: rework checking for use of ppc absolute addressing to allow them as long as
3343 the target is within the same linkage unit.
3346 2006-12-15 Nick Kledzik <kledzik@apple.com>
3348 <rdar://problem/4886652> -ObjC should only load .o with .objc_ symbols
3349 * src/Options.cpp: remove warning from -ObjC and have it instead set fLoadAllObjcObjectsFromArchives
3350 * src/MachOReaderArchive.hpp: when -ObjC is used, preload all .o files from archives that contain .objc_ symbols
3353 ----- Tagged ld64-69
3355 2006-12-13 Nick Kledzik <kledzik@apple.com>
3357 <rdar://problem/4879913> prebound interior pointers must be non-zero
3358 * src/MachOWriterExecutable.hpp: in fixUpReference_powerpc() set lazy pointers bound to with the dylib to
3359 their target value. Properly set REFERENCE_FLAG_UNDEFINED_* flags in reference table and n_desc
3362 2006-12-09 Nick Kledzik <kledzik@apple.com>
3364 <rdar://problem/4868738> ld64 fails to detect error that ld_classic does
3365 * src/MachOWriterExecutable.hpp: check for absolute reloc to an external symbol
3366 * src/MachOReaderRelocatable.hpp: ignore -mlong-branch stubs in .o files
3369 2006-12-09 Nick Kledzik <kledzik@apple.com>
3371 <rdar://problem/4874209> symbols with REFERENCED_DYNAMICALLY should never be stripped
3372 * src/MachOWriterExecutable.hpp: update Writer<A>::shouldExport() to check for kSymbolTableInAndNeverStrip
3373 * unit-tests/test-cases/main-stripped: add test that dynamically referenced symbol cannot be stripped
3376 2006-12-08 Nick Kledzik <kledzik@apple.com>
3378 * unit-tests/test-cases/allowable-client: add variant test cases (e.g. CoreServices_profile)
3379 * src/ld.cpp: allow frameworks with variant install names (e.g. CoreServices_profile) to be private clients
3382 2006-12-08 Nick Kledzik <kledzik@apple.com>
3384 * doc/man/man1/ld.1: rewrite man page
3385 * src/Options.h: add warnObsolete()
3386 * src/Options.cpp: use warnObsolete() on many options. Make nonWeak the weak-mis-match default.
3387 Make -ObjC mean -all_load.
3389 ----- Tagged ld64-68.3
3391 2006-12-05 Nick Kledzik <kledzik@apple.com>
3393 * src/ld.cpp: allow umbrella frameworks to have variant install names (e.g. CoreServices_profile) and still link
3396 ----- Tagged ld64-68.2
3398 2006-12-05 Nick Kledzik <kledzik@apple.com>
3400 * src/MachOWriterExecutable.cpp: Use N_PBUD in the symbol table for undefined symbols in prebound dylibs
3403 ----- Tagged ld64-68.1
3405 2006-12-01 Nick Kledzik <kledzik@apple.com>
3407 * src/Options.cpp: always generate module tables for 32-bit architectures so that ld_classic
3408 can link against them
3411 ----- Tagged ld64-68
3413 2006-12-01 Nick Kledzik <kledzik@apple.com>
3415 <rdar://problem/4858299> seg_addr_table needs matching fuzziness
3416 * src/Options.cpp: special case a how a dozen dylib are looked up in the seg_addr_table
3419 2006-12-01 Nick Kledzik <kledzik@apple.com>
3421 * src/Options.cpp: have all -static links for 32-bit archs roll over to ld_classic unless
3422 LD_NO_CLASSIC_LINKER_STATIC is set.
3423 * unit-tests/bin/make-recursive.pl: set LD_NO_CLASSIC_LINKER_STATIC for unit tests
3426 2006-11-29 Nick Kledzik <kledzik@apple.com>
3428 <rdar://problem/4855542> ld64-67: QTComponents fails to build
3429 * src/MachOReaderRelocatable.hpp: don't error out when a local non-lazy pointer does not point to a symbol
3430 * unit-tests/test-cases/strip_local: added test case
3433 2006-11-28 Nick Kledzik <kledzik@apple.com>
3435 <rdar://problem/4433496> Need a way to mark libraries usable by dynamic linker but unusable by static linker
3436 * src/Options.cpp: allow -client_name to be used with main executables
3437 * src/ld.cpp: generalize -allowable_client. Any dylib can now restrict who can link against it. As a convention
3438 linking with -allowable_client '!' will mean no one can statically link with the dylib. It can still be loaded
3439 dynamically, or by any existing clients, but no new clients can link with it.
3440 * unit-tests/test-cases/allowable-client/Makefile: enable previously commented out test cases. Add test cases
3441 of a dylib that allows no clients and just one client
3443 2006-11-27 Nick Kledzik <kledzik@apple.com>
3445 <rdar://problem/4795615> -final_output should be used if -install_name not used
3446 * src/Options.cpp: fall back to using -final_output for install name
3449 ----- Tagged ld64-67
3451 2006-11-17 Nick Kledzik <kledzik@apple.com>
3453 * src/MachOWriterExecutable.hpp: support __IMPORT segment being slide independently of __DATA segment in shared cache
3456 2006-11-16 Nick Kledzik <kledzik@apple.com>
3458 <rdar://problem/4838262> 9a303: ld -filelist Bus Error
3459 * src/Options.cpp: add check that -filelist is followed by an argument
3462 2006-11-16 Nick Kledzik <kledzik@apple.com>
3464 * src/MachOWriterExecutable.hpp: when building split-seg dylibs, LINKEDIT goes in read-only side
3467 2006-11-15 Nick Kledzik <kledzik@apple.com>
3469 * src/MachOWriterExecutable.hpp: set proper attributes for __eh_frame in ld -r mode
3470 * unit-tests/test-cases/eh_frame: added test case
3473 2006-11-10 Nick Kledzik <kledzik@apple.com>
3475 * src/MachOReaderRelocatable.hpp: redirect references to static weak stubs to the real target
3478 2006-11-09 Nick Kledzik <kledzik@apple.com>
3480 * src/MachOWriterExecutable.hpp: r_address is offset from first LC_SEGMENT vmaddr - not from segment with lowest address
3483 ----- Tagged ld64-66.1
3485 2006-11-09 Nick Kledzik <kledzik@apple.com>
3487 * src/MachOWriterExecutable.hpp: initialize fModuleInfoAtom to zero
3490 2006-11-08 Nick Kledzik <kledzik@apple.com>
3492 <rdar://problem/4821985> FSF GCC's libjava doesn't link with Ochre ld64
3493 * src/MachOReaderRelocatable.hpp: ignore debug_line section if debug_info section is missing or empty
3495 ----- Tagged ld64-66
3497 2006-11-07 Nick Kledzik <kledzik@apple.com>
3499 <rdar://problem/4824368> SWB: d64-65 does not built usage split-seg dylibs
3500 * src/MachOWriterExecutable.hpp: when prebinding split-seg correctly set r_address fields and on
3501 disk values for external relocations
3502 * unit-tests/test-cases/prebound-split-seg: added test case
3505 2006-11-03 Nick Kledzik <kledzik@apple.com>
3507 * src/MachOReaderDylib.hpp: don't report dependent libraries if MH_NO_REEXPORTED_DYLIBS bit is set
3508 * src/MachOWriterExecutable.hpp: set MH_NO_REEXPORTED_DYLIBS bit if dylib does not logically re-export any other dylibs
3509 * unit-tests/test-cases/re-export-flag: added test case
3510 * src/machochecker.cpp: validate use of MH_NO_REEXPORTED_DYLIBS
3513 2006-11-02 Nick Kledzik <kledzik@apple.com>
3515 <rdar://problem/4814565> Mysterious messages from ld64 with MACOSX_DEPLOYMENT_TARGET = 10.5
3516 * src/MachOWriterExecutable.hpp: kPointerWeakImport is a valid reference type to cross segments
3519 2006-11-02 Nick Kledzik <kledzik@apple.com>
3521 * src/Options.cpp,h: Add support for -rpath
3522 * src/MachOFileAbstraction.hpp: add macho_rpath_command
3523 * src/MachOWriterExecutable.hpp: add RPathLoadCommandsAtom to create LC_RPATH for each -rpath
3526 ----- Tagged ld64-65
3528 2006-10-30 Nick Kledzik <kledzik@apple.com>
3530 <rdar://problem/4729162> x86_64 default stack_addr is wrong
3531 * src/Options.cpp: change default 64-bit stack location when using -stack_size
3534 2006-10-30 Nick Kledzik <kledzik@apple.com>
3536 <rdar://problem/4474316> dylibs need modules for 10.3 and for ld_classic in Salt
3537 * src/MachOWriterExecutable.hpp: add ModuleInfoLinkEditAtom to create module table stuff
3538 * src/Options.cpp,h: Add needsModuleTable()
3539 * src/MachOFileAbstraction.hpp: Add macho_dylib_module, macho_dylib_reference, and macho_dylib_table_of_contents
3542 2006-10-27 Nick Kledzik <kledzik@apple.com>
3544 * unit-tests/test-cases/no-uuid/Makefile: add -gstabs+ to be compatible with latest compiler
3545 * unit-tests/test-cases/stabs-coalesce/Makefile: add -gstabs+ to be compatible with latest compiler
3548 2006-10-26 Nick Kledzik <kledzik@apple.com>
3550 <rdar://problem/4585230> i386 -mdynamic-no-pic switch statement jump table is out of line
3551 * src/MachOWriterExecutable.hpp: for i386 don't check for direct references to weak symbols
3554 2006-10-26 Devang Patel <dpatel@apple.com>
3556 * src/LLVMReader.hpp: Supply final output file path to optimizer.
3558 2006-10-26 Devang Patel <dpatel@apple.com>
3560 * src/ObjectFile.h: Make setSection* methods virtual.
3561 * src/LLVMReader.hpp: Override setSection* methods.
3563 2006-10-26 Devang Patel <dpatel@apple.com>
3565 * unit-tests/test-case/llvm-integration/a13.h: New.
3566 * unit-tests/test-case/llvm-integration/a13.cc: New.
3567 * unit-tests/test-case/llvm-integration/main13.cc: New.
3569 2006-10-26 Devang Patel <dpatel@apple.com>
3571 * src/options.h, src/options.cpp: Add -save-temps command line option.
3572 * src/LLVMReader.hpp: Use saveTemps option.
3575 2006-10-26 Devang Patel <dpatel@apple.com>
3577 * src/LLVMReader.hpp: Remove invalid module from memory.
3579 2006-10-26 Devang Patel <dpatel@apple.com>
3581 * src/LLVMReader.hpp: Collect symbol alignment info from LLVM optimizer.
3583 2006-10-21 Eric Christopher <echristo@apple.com>
3585 * src/ld.cpp (Linker::Linker): Check for LD_NO_CLASSIC_LINKER before
3586 invoking ld_classic.
3587 * unit-tests/test-cases/relocs-literals/Makefile: Run for -mdynamic-no-pic
3589 * unit-tests/test-cases/static-executable/Makefile: Skip for 64-bit. Add
3590 -dead_strip to command line.
3592 ----- Tagged ld64-64.2
3594 2006-10-19 Nick Kledzik <kledzik@apple.com>
3596 * ld64.xcodeproj/project.pbxproj: stop copying LLVMReader.hpp into man1 directory
3598 ----- Tagged ld64-64.1
3600 2006-10-19 Nick Kledzik <kledzik@apple.com>
3602 <rdar://problem/4791643> ld64-63.1 erroneously coalesces an empty string with a non-empty string
3603 * src/MachOReaderRelocatable.hpp: rework cstring parsing to not assume all strings are start
3604 at section alignment boundaries, and when coalescing empty strings always use one with greatest
3605 alignment requirement
3606 * src/MachOWriterExecutable.hpp: in -r mode, don't pad end of cstring section
3607 * src/ObjectFile.h: correctly name leadingZeros() as trailingZeros()
3608 * src/ld.cpp: leadingZeros() --> trailingZeros()
3611 2006-10-18 Eric Christopher <echristo@apple.com>
3613 * unit-tests/test-cases/read-only-relocs/Makefile: Skip for x86_64.
3614 * unit-tests/test-cases/llvm-integration/Makefile: Skip if llvm isn't
3617 2006-10-18 Nick Kledzik <kledzik@apple.com>
3619 <rdar://problem/4783853> ld64 change required to go with assembler cstring change
3620 <rdar://problem/4732996> ld64 should error when a local relocation references an address outside its section
3621 * src/MachOReaderRelocatable.hpp: for x86_64 in order to work with local or external relocations to cstrings
3622 change parser to allow atoms with a pending name that is resolved after references are instantiated.
3623 Make direct references to kRegularDefinition atoms.
3624 * src/MachOWriterExecutable.hpp: in -r mode for x86_64 generate L* labels for cstrings and use external relocations
3625 * unit-tests/test-cases/relocs-literals/test.c: add two cases of cstring literal plus addend
3628 2006-10-06 Nick Kledzik <kledzik@apple.com>
3630 <rdar://problem/4786250> check MACOSX_DEPLOYMENT_TARGET if -macosx_version_min is not used
3631 * src/Options.cpp: if -macosx_version_min is not used, check MACOSX_DEPLOYMENT_TARGET, if
3632 that is unused, default to 10.5
3634 ----- Tagged ld64-64
3636 2006-10-06 Nick Kledzik <kledzik@apple.com>
3638 <rdar://problem/4756806> crash in ppc64 program - bl to saveFP, but saveFP is too far away?
3639 * src/MachOWriterExecutable.hpp: in addPPCBranchIslands(), properly account for growth of __text
3642 2006-10-06 Nick Kledzik <kledzik@apple.com>
3644 <rdar://problem/4769120> Linker-defined alias converts reference into definition and generates error.
3645 * src/MachOReaderRelocatable.hpp: only alias symbols actually in the symbol table
3648 2006-10-06 Nick Kledzik <kledzik@apple.com>
3650 * unit-tests/test-cases/dwarf-debug-notes/Makefile: crt1.o no longer has stabs, so don't need to strip it
3651 * unit-tests/test-cases/dwarf-debug-notes-r/Makefile: crt1.o no longer has stabs, so don't need to strip it
3654 2006-10-06 Nick Kledzik <kledzik@apple.com>
3656 * src/MachOReaderRelocatable.hpp: rework dwarf line parsing to fix warnings that starting
3657 showing up with gcc-5421
3660 2006-10-05 Eric Christopher <echristo@apple.com>
3662 <rdar://problem/4760935> ld64 needs to support libtool options
3663 * src/Options.cpp (Options::parse): Add -noall_load, -install_name,
3664 -current_version and -compatibility_version.
3666 2006-10-03 Eric Christopher <echristo@apple.com>
3668 * src/Options.cpp (Options::gotoClassicLinker): Use execvp
3671 2006-10-03 Eric Christopher <echristo@apple.com>
3673 * unit-tests/test-cases/tentative-to-real/Makefile: Clean up after tests.
3675 2006-10-03 Eric Christopher <echristo@apple.com>
3677 * unit-tests/include/common.makefile (VALID_ARCHS): Add x86_64.
3678 (OTOOL): Remove munging based on ARCH.
3680 2006-09-29 Nick Kledzik <kledzik@apple.com>
3682 <rdar://problem/4743925> problem merging .o files built with and without -fno-common
3683 src/Options.*: make MakeTentativeDefinitionsReal a reader option
3684 src/ObjectFile.h: make MakeTentativeDefinitionsReal a reader option
3685 src/MachOWriterExecutable.hpp: make MakeTentativeDefinitionsReal a reader option
3686 src/MachOReaderRelocatable.hpp: only assign a section name of __common to
3687 tentative defintions when making a final linked image
3690 2006-09-28 Nick Kledzik <kledzik@apple.com>
3692 src/Options.h/.cpp: add support for -segaddr option
3693 src/MachOWriterExecutable.hpp: In Writer::assignFileOffsets(), use -segaddr info
3696 2006-09-28 Nick Kledzik <kledzik@apple.com>
3698 <rdar://problem/4587349> Emit new CPU subtypes for ppc64 and x86-64 when targeting 10.5 or later
3699 src/MachOWriterExecutable.hpp: set high bit of cpusubtype of 64-bit main executables when targeting 10.5 or later
3702 2006-09-28 Devang Patel <dpatel@apple.com>
3704 Add LLVM LTO support
3705 src/LLVMReader.hpp: New file.
3706 src/ld.cpp: Add optimization phase. Use LLVM LTO.
3707 unit-tests/test-cases/llvm-integration: New tests.
3709 2006-09-27 Nick Kledzik <kledzik@apple.com>
3711 ld64.xcodeproj/project.pbxproj: remove accidental install of source file into man1
3714 2006-09-25 Nick Kledzik <kledzik@apple.com>
3716 src/Architectures.hpp: add kPointerDiff16 for ppc and ppc64
3717 src/MachOReaderRelocatable.hpp: support kPointerDiff16
3718 src/MachOWriterExecutable.hpp: support kPointerDiff16
3720 ----- Tagged ld64-63.1
3722 2006-09-22 Nick Kledzik <kledzik@apple.com>
3724 src/MachOWriterExecutable.hpp: include stubs in LC_SEGMENT_SPLIT_INFO
3727 2006-09-21 Nick Kledzik <kledzik@apple.com>
3729 src/Options.cpp: disable split-seg dylibs for 64-bit architectures
3732 2006-09-19 Nick Kledzik <kledzik@apple.com>
3734 src/MachOReaderRelocatable.hpp: rework __cstring parsing to better handle mixed alignment cstrings
3735 src/MachOWriterExecutable.hpp: in -r mode, make all __cstrings aligned to section alignment
3738 2006-09-19 Nick Kledzik <kledzik@apple.com>
3740 src/MachOWriterExecutable.hpp: rework encoding of LC_SEGMENT_SPLIT_INFO
3743 2006-09-19 Nick Kledzik <kledzik@apple.com>
3745 src/Options.cpp: check for -search_paths_first in first pass
3748 ----- Tagged ld64-63
3750 2006-09-15 Nick Kledzik <kledzik@apple.com>
3752 src/Options.cpp: since the ld64 will repeatedly search an archive, and some project list archives
3753 multiple times on command line to work with traditional linkers, automatically ignore duplicate libraries
3754 unit-tests/test-cases/archive-duplicate: added test case
3757 2006-09-15 Nick Kledzik <kledzik@apple.com>
3759 src/Options.cpp: support -r -static
3760 src/MachOWriterExecutable.hpp: support -r -static an don't generate LC_DYSYMTAB
3763 2006-09-14 Nick Kledzik <kledzik@apple.com>
3765 src/MachOWriterExecutable.hpp: in -r mode references to weak symbols should not create external relocations
3766 as that can cause nmedit to errror later.
3769 2006-09-13 Nick Kledzik <kledzik@apple.com>
3771 <rdar://problem/4718189> ld64: Handle .objc_class_name exports specially
3772 src/Options.cpp: add hack so that .objc_class_name_XXX in -exported_symbols_list imples _OBJC_CLASS_$_XXX
3773 src/ld.cpp: add hack to supporess errors about .objc_class_name_XXX or _OBJC_CLASS_$_XXX being undefined
3776 2006-09-12 Nick Kledzik <kledzik@apple.com>
3778 <rdar://problem/4474172> Support -prebind when targeting ppc and OS < 10.4
3779 src/Options.h: add splitSeg() and baseWritableAddress()
3780 src/Options.cpp: Add support for -seg_addr_table and LD_SEG_ADDR_TABLE, and -prebind and LD_PREBIND.
3781 src/src/MachOWriterExecutable.hpp: support split-seg and canonical prebound files to be generated
3784 2006-09-11 Nick Kledzik <kledzik@apple.com>
3786 <rdar://problem/4464904> Linking a dylib or binary from identical binaries should produce the same output
3787 src/MachOWriterExecutable.hpp: set the timestamps to be constant
3790 2006-09-11 Nick Kledzik <kledzik@apple.com>
3792 <rdar://problem/4070025> Linker support for ordering all sections and symbols
3793 src/Options.cpp: Add -order_file_statistics. Allow architecture prefixes in order files
3794 src/ld.cpp: Use fOptions.printOrderFileStatistics()
3797 2006-09-11 Nick Kledzik <kledzik@apple.com>
3799 <rdar://problem/3894079> Support -sectorder
3800 unit-tests/test-cases/order_file: added test case
3801 src/ld.cpp: Implement order file support in Linker::sortAtoms()
3802 src/Options.h: add Options.orderedSymbols()
3803 src/Options.cpp: add parseOrderFile(), implement -order_file
3806 2006-09-07 Nick Kledzik <kledzik@apple.com>
3808 <rdar://problem/4637023> need -i for 64-bit (or equivalent)
3809 <rdar://problem/4014529> Support -i for aliasing exported symbols
3810 unit-tests/test-cases/alias-objects: added
3811 unit-tests/test-cases/alias-command-line: added
3812 src/ObjectFile.h: Added Atom::getOrdinal() as new way to sort atoms. Added ReaderOptions.fAliases
3813 src/MachOReaderRelocatable.hpp: Added SymbolAliasAtom to handle multiple symbols to same address
3814 src/MachOReaderArchive.hpp: implement Atom::getOrdinal() to space out atom ordinals across member objects
3815 src/Options.cpp: support -i, -alias, -alias_list. Move search of /Network/Library/Frameworks to after /System/Library/Frameworks
3816 src/MachOWriterExecutable.hpp: pad out seg_info data. Implement getOrdinal().
3817 src/ObjectDump.cpp: call constructors directly instead of using make() wrapper
3820 2006-09-01 Nick Kledzik <kledzik@apple.com>
3822 <rdar://problem/4458878> Need the ability to tag libraries/plug-ins with security attributes
3823 src/MachOReaderDylib.hpp: add warning if using -root_safe or -setuid_safe and link against dylib that is not
3824 src/ObjectFile.h: add ReaderOption fRootSafe and fSetuidSafe
3825 src/Options.cpp: handle -root_safe or -setuid_safe command line options
3826 src/MachOWriterExecutable.hpp: set MH_ROOT_SAFE and MH_SETUID_SAFE flags
3829 2006-08-31 Nick Kledzik <kledzik@apple.com>
3831 src/ld.cpp: Add Linker::processDTrace() for processing dtrace static probes
3832 src/OpaqueSection.hpp: renamed, add symbol name, add ability to add references
3833 ld64.xcodeproj/project.pbxproj: remove SectCreate.cpp, add OpaqueSection.hpp
3836 2006-08-28 Nick Kledzik <kledzik@apple.com>
3838 <rdar://problem/4571042> Add convention for removing symbols at link time
3839 <rdar://problem/3962731> Assembler -L option causes ld64 to split stubs
3840 unit-tests/test-cases/special-labels: added test case
3841 src/MachOReaderRelocatable.hpp: ignore L* labels, make l* labels as kSymbolTableNotIn
3844 2006-08-28 Nick Kledzik <kledzik@apple.com>
3846 src/lObjectFile.h: refactor isTargetUnbound() into getTargetBinding()
3847 src/ld.cpp: create __dof section in final linked images from dtrace static probes
3848 src/Architectures.hpp: add kDtraceProbe
3849 src/Options.h/cpp: Add support for -dtrace
3850 src/machochecker.cpp: support LC_SEGMENT_SPLIT_INFO
3851 src/MachOWriterExecutable.hpp: support kDtraceProbe
3852 src/MachOReaderRelocatable.hpp: suppport kDtraceProbe
3855 2006-08-25 Nick Kledzik <kledzik@apple.com>
3857 <rdar://problem/4701529> generate LC_SEGMENT_SPLIT_INFO for 10.5 or later dylibs
3858 src/Options.h&.cpp: implement sharedRegionEligible() to control when LC_SEGMENT_SPLIT_INFO is added
3859 src/MachOFileAbstraction.hpp: add macho_linkedit_data_command
3860 src/MachOWriterExecutable.hpp: generate LC_SEGMENT_SPLIT_INFO load command and linkedit content
3862 ----- Tagged ld64-62
3864 2006-08-15 Nick Kledzik <kledzik@apple.com>
3866 <rdar://problem/4681062> wrong error message when symbol is found in unused indirect library
3867 src/ld.cpp: remove indirect libraries if they are not re-exported
3868 unit-tests/test-cases/indirect-dylib: added test case
3871 2006-08-15 Nick Kledzik <kledzik@apple.com>
3873 <rdar://problem/3930461> alignment needs to be richer
3874 src/ObjectFile.h: define ObjectFile::Alignment class for tracking rich alignment info
3875 src/ld.cpp: modify SymbolTable::add() to work with new Alignment type
3876 src/MachOReaderRelocatable.hpp: use new Alignment type. Remove alignAtLeast() and handleAnonymousNonLazyPointers()
3877 src/MachOWriterExecutable.hpp: update for new Alignment type, use modulus when calculating layout address
3878 src/ObjectDump.cpp: print richer Alignment info
3879 unit-tests/test-cases/align-modulus: added test case
3882 2006-08-11 Nick Kledzik <kledzik@apple.com>
3884 remove OPEN_SOURCE conditionals around x86_64 support
3887 2006-07-31 Nick Kledzik <kledzik@apple.com>
3889 <rdar://problem/4654131> ld64 while linking cc1 [ when dead_strip is ON]
3890 src/ld.cpp: Add ivar fAtomsWithUnresolvedReferences to track atoms not initially resolvable
3891 unit-tests/test-cases/dead_strip-archive: added test case
3894 2006-07-31 Nick Kledzik <kledzik@apple.com>
3896 <rdar://problem/4656617> x86_64: instructions with immediate and rip-relative operands need to use new relocation types
3897 src/MachOWriterExecutable.hpp: generate new reloc types in -r mode
3898 src/MachOReaderRelocatable.hpp: parse new reloc types
3899 unit-tests/test-cases/relocs-asm/relocs-asm.s: add test cases for new reloc type
3902 2006-07-18 Nick Kledzik <kledzik@apple.com>
3904 src/MachOReaderRelocatable.hpp: suppress warning about dwarf info parsing for one benign no-op case
3905 the compiler emits when there are not functions in the __text section
3908 2006-07-17 Nick Kledzik <kledzik@apple.com>
3910 <rdar://problem/4634840> faster debug note generation
3911 src/ld.cpp: rework collectDebugInfo() to produce all debug notes in one pass, intead of a
3912 pass per .o file. Added timing info for collectDebugInfo() to -print_statistics
3913 unit-tests/test-cases/dwarf-debug-notes-r/Makefile: add expliced -arch to ld -r
3914 unit-tests/test-cases/dwarf-debug-notes-r/expected-stabs: alter for new debug notes order
3917 2006-07-17 Nick Kledzik <kledzik@apple.com>
3919 <rdar://problem/4623994> ld64 VSIZE is 1.18GB when building Finder ppc64
3920 src/ld.cpp: fixed typo in createReader() that prevented dylibs from being unmapped
3922 ----- Tagged ld64-61.1
3924 2006-07-11 Nick Kledzik <kledzik@apple.com>
3926 <rdar://problem/4622049> ld64-61: gcc DejaGnu tests failing due to -arch followed by unknown architecture name
3927 src/Options.cpp: map ppc750, ppc7400, ppc7450, and ppc970 to ppc. Improve error message
3929 2006-07-11 Nick Kledzik <kledzik@apple.com>
3931 <rdar://problem/4622769> If -arch is missing, rollover to ld_classic does not happen
3932 src/Options.h: make gotoClassicLinker() public
3933 src/ld.cpp: call gotoClassicLinker() if the inferred architecture is ppc or i386
3935 ----- Tagged ld64-61
3937 2006-06-29 Nick Kledzik <kledzik@apple.com>
3939 <rdar://problem/4606628> ld64 should be renamed to ld
3940 src/Options.cpp: exec() ld_classic if -arch ppc or -arch i386 is seen
3941 src/ld.cpp: alter version string
3942 ld64.xcodeproj/project.pbxproj: change install location to /usr/bin/ld, add symlink from /usr/bin/ld64
3943 doc/man/man1/ld.1: added
3945 ----- Tagged ld64-60
3947 2006-06-28 Nick Kledzik <kledzik@apple.com>
3949 <rdar://problem/4604539> Can't link large ppc64 program: ld64 says "bl out of range"
3950 MachOWriterExecutable.hpp: fix branch island generation to work for weak_import functions
3951 and properly chain together branch islands
3952 MachOReaderRelocatable.hpp: improve performance of huge .o file reading by sorted references
3955 2006-06-28 Nick Kledzik <kledzik@apple.com>
3957 <rdar://problem/4603454> MySQL-36 fails to build with ld64-59
3958 src/MachOReaderRelocatable.hpp: back out fix for 4585335
3959 src/MachOWriterExecutable.hpp: back out fix for 4585335
3961 2006-06-27 Nick Kledzik <kledzik@apple.com>
3963 src/MachOReaderRelocatable.hpp: handle N_GSYM without ending :G() since that is how
3964 dwarf debug notes are formed.
3966 2006-06-23 Nick Kledzik <kledzik@apple.com>
3968 <rdar://problem/4599239 objc class with no superclass causes bad undefined symbol
3969 src/MachOReaderRelocatable.hpp: handle NULL superclass in objc_class
3970 unit-tests/test-cases/relocs-objc/test.m: add case with no super class
3973 2006-06-23 Nick Kledzik <kledzik@apple.com>
3975 <rdar://problem/4313369> ld64 doesn't support variant linking -framework fw,_debug
3976 src/Options.cpp: enhance findFramework() to support suffixes
3978 ----- Tagged ld64-59
3980 2006-06-22 Nick Kledzik <kledzik@apple.com>
3982 <rdar://problem/4596726> ld64 lost DWARF debug notes
3983 src/MachOReaderRelocatable.hpp: add fHasUUID so kDebugInfoStabsUUID can be set later
3984 unit-tests/test-cases/dwarf-debug-notes-r: added test case
3986 2006-06-21 Nick Kledzik <kledzik@apple.com>
3988 <rdar://problem/4567995> python 64-bit address miscalculation
3989 src/MachOReaderRelocatable.hpp: change getTargetOffset() to sign extend the 32-bit value to 64-bits
3991 2006-06-21 Nick Kledzik <kledzik@apple.com>
3993 <rdar://problem/4535036> ld64 seems to offset things incorrectly when using -r
3994 src/MachOWriterExecutable.hpp: in -r mode, virtual sections should not increment address
3997 ----- Tagged ld64-58
3999 2006-06-16 Nick Kledzik <kledzik@apple.com>
4001 src/rebase.cpp: fix page alignment problem
4002 src/rebase.cpp: fix endianess problem with local non-lazy pointers
4004 2006-06-15 Nick Kledzik <kledzik@apple.com>
4006 src/rebase.cpp: fix to build in CurryWeed
4007 ld64.xcodeproj/project.pbxproj: fix to build properly in CurryWeed
4009 2006-06-15 Nick Kledzik <kledzik@apple.com>
4011 <rdar://problem/4495309> Support .objc_class_name_* symbols
4012 src/ObjectFile.h: Add kSymbolTableInAsAbsolute
4013 src/MachOReaderRelocatable.hpp: synthesize references to required objc classes
4014 src/MachOWriterExecutable.hpp: write objc_class_name as absolute symbol
4015 unit-tests/test-cases/objc-references: added
4017 2006-06-15 Nick Kledzik <kledzik@apple.com>
4019 <rdar://problem/4484369> SECTION_ATTRIBUTES unset in ppc64 mach-o header
4020 src/MachOWriterExecutable.hpp: add section attribute for sections with code
4022 2006-06-15 Nick Kledzik <kledzik@apple.com>
4024 <rdar://problem/4569407> ld64 bogus duplicate symbol name linking GNU libobjc
4025 src/MachOReaderRelocatable.hpp: only special case Apple objc runtime objc classes
4027 2006-06-15 Nick Kledzik <kledzik@apple.com>
4029 <rdar://problem/4582999> x86_64: ".align" directive not honored
4030 src/MachOReaderRelocatable.hpp: change code alignment to not depend on atom size
4032 2006-06-14 Nick Kledzik <kledzik@apple.com>
4034 <rdar://problem/4585335> jump table into middle of weak symbol causes error
4035 src/MachOReaderRelocatable.hpp: create direct references to the interior of weak symbols
4036 src/MachOWriterExecutable.hpp: do not error on absolute references to interior of weak symbols
4038 2006-06-13 Nick Kledzik <kledzik@apple.com>
4040 src/Options.cpp: allow -image_base as an alias for -seg1addr
4042 2006-06-13 Nick Kledzik <kledzik@apple.com>
4044 <rdar://problem/4585115> implement -d
4045 src/Options.h: add fMakeTentativeDefinitionsReal
4046 src/Options.cpp: set fMakeTentativeDefinitionsReal if -d option is found
4047 src/MachOWriterExecutable.hpp: turn tentative into real definition if makeTentativeDefinitionsReal
4048 unit-tests/test-cases/btentative-to-real: added test case
4050 2006-06-13 Nick Kledzik <kledzik@apple.com>
4052 <rdar://problem/4584355> implement -bundle_loader
4053 src/Options.h: add fBundleLoader bit to DynamicLibraryOptions
4054 src/Options.cpp: handle -bundle_loader
4055 src/ld.cpp: pass fBundleLoader bit to MachOReaderDylib
4056 src/MachOReaderDylib.hpp: support reading MH_EXECUTE files if fBundleLoader is set
4057 src/MachOWriterExecutable.hpp: set bundle loader ordinal as EXECUTABLE_ORDINAL
4058 unit-tests/test-cases/bundle_loader: added test case
4060 2006-06-12 Nick Kledzik <kledzik@apple.com>
4062 <rdar://problem/4583347> -syslibroot can cause "can't find ordinal for imported" error
4063 src/MachOReaderDylib.hpp: in Reader::reExports() compare install path in addition to load path
4066 2006-06-10 Nick Kledzik <kledzik@apple.com>
4068 <rdar://problem/4548935> Need rebasing tool
4069 src/rebase.cpp: added
4070 unit-tests/test-cases/rebase-basic: added
4071 doc/man/man1/rebase.1: added
4072 ld64.xcodeproj/project.pbxproj: added rebase target. changed all targets to build with dwarf
4075 2006-06-10 Nick Kledzik <kledzik@apple.com>
4077 src/machochecker.cpp: add some ppc reloc sanity checking
4079 ----- Tagged ld64-57
4081 2006-06-06 Nick Kledzik <kledzik@apple.com>
4083 <rdar://problem/4565088> ld64 is not adding a final '/' char on the initial directory-name SO stab debug map entry
4084 ld.cpp: Change Linker::synthesizeStabs() to assure directory SO always has a trailing slash
4085 unit-tests/test-cases/dwarf-debug-notes/expected-stabs: update with trailing /
4087 2006-06-06 Nick Kledzik <kledzik@apple.com>
4089 <rdar://problem/4572702> -sectcreate of a 0-byte section fails
4090 MachOWriterExecutable.cpp: Don't error out on zero length segments
4091 MachOWriterExecutable.cpp: For ppc64 reloc base address is the first writable segment iff
4092 there is a writable segment >4GB from base address
4094 2006-06-04 Eric Christopher <echristo@apple.com>
4098 * src/ld.cpp (createReader): Fixed error message.
4100 (resolveFrom): Ditto.
4101 (checkUndefines): Ditto.
4103 ----- Tagged ld64-56
4105 2006-05-23 Nick Kledzik <kledzik@apple.com>
4107 <rdar://problem/4558079> No debug notes for ObjC methods when linking with ld64
4108 ld.cpp: don't limit debug notes to functions starting with underscore
4110 2006-05-22 Nick Kledzik <kledzik@apple.com>
4112 <rdar://problem/4556982> ld64 spends much time in mach_o::relocatable::Reader<x86_64>::findAtomByName
4113 * src/MachOReaderRelocatable.hpp: add makeReferenceToSymbol() so that x86_64 does not need to do by-name lookups
4115 2006-05-22 Nick Kledzik <kledzik@apple.com>
4117 <rdar://problem/4535044> remove inferring warning
4118 * ld.cpp: Remove "inferring" warning. If a link failed and now arch was specifed add which arch was
4119 inferred to error message
4121 2006-05-19 Nick Kledzik <kledzik@apple.com>
4123 <rdar://problem/4544001> ld64 does not honor -arch_multiple
4124 * ld.cpp: If fOptions.printArchPrefix(), add architecture name to error message
4126 2006-05-19 Nick Kledzik <kledzik@apple.com>
4128 <rdar://problem/4555973> Support S_16BYTE_LITERALS section types
4129 * src/MachOReaderRelocatable.hpp: support S_16BYTE_LITERALS
4130 * src/MachOWriterExecutable.hpp: support S_16BYTE_LITERALS
4132 2006-05-19 Nick Kledzik <kledzik@apple.com>
4134 <rdar://problem/4548803> "warning can't parse dwarf compilation unit info" warnings building debug
4135 * src/MachOReaderRelocatable.hpp: fix bugs in dwarf line table parsing
4137 ----- Tagged ld64-55
4139 2006-05-18 Nick Kledzik <kledzik@apple.com>
4141 <rdar://problem/4534339> Default the pagezero size to 4GB for x86-64
4142 * src/Options.cpp: Chnage default the pagezero size to 4GB for x86-64
4144 2006-05-18 Nick Kledzik <kledzik@apple.com>
4146 <rdar://problem/4552825> x86_64 CarbonCore fails to link with "atom not found in symbolIndex"
4147 * src/MachOWriterExecutable.hpp: in buildObjectFileFixups() don't call addObjectRelocs() on kNoFixUp references
4149 2006-05-18 Nick Kledzik <kledzik@apple.com>
4151 <rdar://problem/4553555> ld64: .section defaults to read-only
4152 * src/MachOReaderRelocatable.hpp: default unknown segments to r/w
4154 2006-05-18 Nick Kledzik <kledzik@apple.com>
4156 <rdar://problem/4551990> -fvisibility=hidden causes crashes for x86_64
4157 * src/MachOWriterExecutable.hpp: properly handle RIP relative tentative definitions
4159 2006-05-12 Nick Kledzik <kledzik@apple.com>
4161 * src/Architectures.hpp: add x86::kAbsolute32
4162 * src/MachOReaderRelocatable.hpp: generate x86::kAbsolute32 for mdynamic-no-pic instructions
4163 * src/MachOWriterExecutable.hpp: process x86::kAbsolute32 reference kind
4165 ----- Tagged ld64-54
4167 2006-05-11 Nick Kledzik <kledzik@apple.com>
4169 <rdar://problem/4545108> CF-393 failes to link for x86_64
4170 * src/MachOWriterExecutable.cpp: fix sign extension for Rel32 relocs in Writer<x86_64>::fixUpReferenceRelocatable
4172 2006-05-11 Nick Kledzik <kledzik@apple.com>
4174 <rdar://problem/4501434> warning arch x86_64 not found using i386
4175 * src/ld.cpp: remove hack to allow x86_64 to link against i386 dylibs
4178 2006-05-10 Nick Kledzik <kledzik@apple.com>
4180 <rdar://problem/4543754> x86_64: .objc_class_name symbol names scrambled
4181 * src/MachOReaderRelocatable.hpp: properly compute alignment of __OBJC __class sections
4184 2006-05-08 Nick Kledzik <kledzik@apple.com>
4186 <rdar://problem/3894083> Support -dead_strip
4187 * src/Options.h/cpp: implement -why_load and -why_live. Enable -dead_strip.
4188 * src/MachOReaderArchive.hpp: implement -why_load
4189 * src/MachOReaderRelocatable.hpp: suppress GCC_except_table* symbols in final output
4190 * src/ld.cpp: implement dead code stripping
4191 * unit-tests/test-cases/dead_strip: added
4193 ----- Tagged ld64-53
4195 2006-05-05 Nick Kledzik <kledzik@apple.com>
4197 * src/Options.cpp: make 10.4 be minimum OS version for newer architectures
4199 2006-05-05 Nick Kledzik <kledzik@apple.com>
4201 <rdar://problem/4147604> N_SO symbols in 64-bit builds have a zero address for n.n_value
4202 * src/ld.cpp: for SO stabs, associate first and last atom in the SO range
4203 * src/MachOWriterExecutable.hpp: use atom associated with SO stab to set ins n_value
4205 2006-05-05 Nick Kledzik <kledzik@apple.com>
4207 * MachOWriterExecutable.hpp: fix end FUN stab to have length of function
4210 2006-05-02 Nick Kledzik <kledzik@apple.com>
4212 <rdar://problem/4496250> 64-bit main executables should have 4GB zero page by default
4213 * src/Opptions.cpp: change default pagezero_size to 4GB for ppc64
4214 <rdar://problem/4492850> 64 bit: apps with -mdynamic-no-pic seg fault when page zero > 4GB
4215 * src/MachOWriterExecutable.cpp: rework pagezero for ppc64 so that if any mdynamic-no-pic code
4216 is found, the code is kept in the low 2GB, and a new segment is create to map away up to 4GB.
4218 2006-05-02 Nick Kledzik <kledzik@apple.com>
4220 * src/Opptions.cpp: remove warning about -stack_addr not specified. Add warning if 32-bit stack
4221 overlaps shared region
4223 ----- Tagged ld64-52.1
4225 2006-05-01 Nick Kledzik <kledzik@apple.com>
4227 * src/MachOReaderRelocatable.cpp: rework handleAnonymousNonLazyPointers() to handle anl's in the middle
4228 the __data section too.
4230 ----- Tagged ld64-52
4232 2006-04-28 Nick Kledzik <kledzik@apple.com>
4234 <rdar://problem/4513304> 64-bit: 9A152 TextEdit crashes in dlopen on bring-up
4235 * src/MachOReaderRelocatable.cpp: rework anonymous non-lazy-pointer detection
4237 2006-04-28 Nick Kledzik <kledzik@apple.com>
4239 <rdar://problem/4528054> 64 Bit: Development build of ppc64 TextEdit gets confused about static variables
4240 * src/MachOReaderRelocatable.cpp: mark non-lazy-pointer atoms as scopeTranslationUnit if targetting a static symbol
4244 2006-04-21 Nick Kledzik <kledzik@apple.com>
4246 * src/Options.cpp: fix default address for ppc64 custom stack
4247 * src/MachOWriterExecutable.cpp: fix set up of ppc64 custom stack
4250 2006-04-14 Nick Kledzik <kledzik@apple.com>
4252 * src/Options.cpp: fix -sub_library processing to work it dylib is specifed with leaf name
4254 ----- Tagged ld64-51.1
4256 2006-04-13 Nick Kledzik <kledzik@apple.com>
4258 <rdar://problem/4513304> 64-bit: 9A152 TextEdit crashes in dlopen on bring-up
4259 * src/MachOReaderRelocatable.hpp: when detecting anonymous non-lazy-pointers disqualify data
4260 that points to static or global symbols
4261 * src/ld.cpp: print version of ld64 in error messages
4264 ----- Tagged ld64-51
4266 2006-04-11 Nick Kledzik <kledzik@apple.com>
4268 <rdar://problem/4499168> exported symbols not properly stripped
4269 * src/MachOReaderRelocatable.hpp: enable AnonymousAtom::setScope()
4271 2006-03-31 Nick Kledzik <kledzik@apple.com>
4273 <rdar://problem/4498391> ld64 fails when linking debug ppc64 HIToolbox
4274 * src/MachOReaderRelocatable.hpp: handle anonymous non-lazy pointers encoded with local relocations
4275 * src/MachOWriterExecutable.hpp: in -r mode, only generated INDIRECT_SYMBOL_LOCAL for non-lazy targets that
4278 2006-03-31 Nick Kledzik <kledzik@apple.com>
4280 <rdar://problem/4496499> ld64 should remove generated file if link errors out
4281 * src/MachOWriterExecutable.hpp: catch exceptions in Writer<A>::write(), delete output file, and rethrow
4284 ----- Tagged ld64-50
4287 2006-03-29 Nick Kledzik <kledzik@apple.com>
4289 * src/MachOReaderRelocatable.hpp: synthesize .objc_class_name symbols
4290 * src/MachOFileAbstraction.hpp: use strncpy for sect/seg names to zero fill trailing space
4292 2006-03-28 Nick Kledzik <kledzik@apple.com>
4294 * src/MachOReaderRelocatable.hpp: fix spurious warning about dwarf line info
4296 ----- Tagged ld64-49.1
4298 2006-03-25 Nick Kledzik <kledzik@apple.com>
4300 * MachOWriterExecutable.hpp : don't complain about ppc64 dyld being based > 4GB
4302 ----- Tagged ld64-49
4304 2006-03-24 Nick Kledzik <kledzik@apple.com>
4306 * src/MachOWriterExecutable.hpp: dyld is allowed to have synthesized non-lazy pointers
4307 <rdar://problem/4488113> ld64 is after processing bad GSYM stabs
4308 * src/MachOReaderRelocatable.hpp: if a GSYM is found that does not match any data symbol, suppress it
4310 2006-03-23 Nick Kledzik <kledzik@apple.com>
4312 * src/MachOWriterExecutable.hpp: in Writer<x86>::fixUpReferenceFinal() fix when x86::kPointer is for an
4315 2006-03-23 Nick Kledzik <kledzik@apple.com>
4317 * src/Options.cpp: change macosx-min-version to default to a per-architecture setting
4318 add warning if -pagezero_size is not page aligned
4319 * src/MachOWriterExecutable.hpp: properly handle external relocations for ppc64 with 4GB pagezero
4320 * src/machochecker.cpp: sanity check relocation records
4322 ----- Tagged ld64-48
4324 2006-03-21 Nick Kledzik <kledzik@apple.com>
4326 <rdar://problem/4481406> 64bit: passing function pointer to another function passes the wrong function address
4327 * src/MachOReaderRelocatable.hpp: when processing a non-lazy pointer to a static function, don't accidentally
4328 match it to a STAB symbol.
4330 2006-03-21 Nick Kledzik <kledzik@apple.com>
4332 <rdar://problem/4180168> .eh symbols make up 13% of libstdc++'s stripped binary size
4333 * src/ObjectFile.h: add ReaderOptions.fForFinalLinkedImage
4334 * src/Options.cpp: setup ReaderOptions.fForFinalLinkedImage
4335 * src/MachOReaderRelocatable.hpp: mark .eh symbols kSymbolTableNotIn when building final linked image
4337 2006-03-21 Nick Kledzik <kledzik@apple.com>
4339 <rdar://problem/4473742> ld64 does not parse optional second argument to -filelist
4340 * unit-tests/test-cases/filelist: added
4341 * src/Options.cpp: in Options::loadFileList() handle comma option
4344 ----- Tagged ld64-47.1
4347 ----- Tagged ld64-47
4350 ----- Tagged ld64-46
4352 2006-03-10 Nick Kledzik <kledzik@apple.com>
4354 <rdar://problem/4419505> ld64 should figure out architecture from .o files
4355 * unit-tests/test-cases/auto-arch: added
4356 * src/ld.cpp: added Linker::inferArchitecture() to scan .o files are infer architecture to link
4357 * src/MachOReaderArchive.hpp: enhanced validFile() to look deeper into archive and really valdate
4358 * src/MachOWriterExecutable.hpp: stop using fOptions.architecture()
4359 * src/Options.cpp: stop defaulting to ppc64
4362 2006-03-09 Nick Kledzik <kledzik@apple.com>
4364 <rdar://problem/4465004> Need "intentionally left blank" dylib stubs
4365 * unit-tests/include/common.makefile: add VALID_ARCHS
4366 * unit-tests/run-all-unit-tests: set up VALID_ARCHS
4367 * unit-tests/test-cases/blank-stubs: add test case
4368 * src/ld.cpp: in addDylib(), detect and ignore blank stubs
4369 * src/MachOReaderDylib.hpp: in constructor, handle blank stubs
4371 2006-03-09 Nick Kledzik <kledzik@apple.com>
4373 <rdar://problem/4471424> crash in stub with 2GB pagezero
4374 * src/MachOWriterExecutable.hpp: StubAtom<ppc64> can't be no-pic if a large zero-page is used
4376 2006-03-06 Nick Kledzik <kledzik@apple.com>
4378 * src/Options.cpp: addSectionAlignment, warn if -sectalign alignment is not a power of two
4380 ----- Tagged ld64-45
4383 2006-03-06 Nick Kledzik <kledzik@apple.com>
4385 <rdar://problem/4466930> LP64/9A122: ld64: hang when trying to link DiscRecording framework
4386 * src/Options.cpp: addSectionAlignment, warn on zero. Use log2() for alignment conversion
4389 ----- Tagged ld64-44
4391 2006-03-04 Nick Kledzik <kledzik@apple.com>
4393 * src/MachOReaderRelocatable.hpp: fix again test for detection of anonymous non-lazy-pointer.
4394 Error out if .o file contains old __DWARFA style dwarf.
4396 2006-03-02 Nick Kledzik <kledzik@apple.com>
4398 * src/ld.cpp: only re-map page aligned sub-parts of a fat file. A conformat mmap() requires alignment.
4400 ----- Tagged ld64-43
4403 2006-03-02 Nick Kledzik <kledzik@apple.com>
4405 * src/MachOReaderRelocatable.hpp: <rdar://problem/4464370> tighten detection of anonymous non-lazy-pointer
4407 ----- Tagged ld64-42
4409 2006-02-28 Nick Kledzik <kledzik@apple.com>
4411 * src/MachOReaderRelocatable.hpp: fix x86 __IMPORT permissions for class Segment
4413 2006-02-28 Nick Kledzik <kledzik@apple.com>
4415 <rdar://problem/4461240> SWB: ld64-37 (can't resolve symbol ___dso_handle)
4416 * src/MachOWriterExecutable.hpp: add class DsoHandleAtom
4418 2006-02-28 Nick Kledzik <kledzik@apple.com>
4420 * unit-tests/test-cases/literals-coalesce-alignment: added test case
4421 * src/ld.cpp: when coalescing strings pick one with greater alignment
4422 <rdar://problem/4458660> ld64: CG link failed because lo14 reference to anonymous non-lazy-pointer not aligned
4423 * unit-tests/test-cases/relocs-c/test.c: tweak to fail like 4458660
4424 * src/MachOReaderRelocatable.hpp: detect anonymous non-lazy-pointer and transform into real non-lazy-pointers
4426 ----- Tagged ld64-41
4428 2006-02-24 Nick Kledzik <kledzik@apple.com>
4430 * src/Options.cpp: Warning about -no_dead_strip_inits_and_terms and -i options.
4433 ----- Tagged ld64-40
4435 2006-02-24 Nick Kledzik <kledzik@apple.com>
4437 <rdar://problem/4454698> Leopard9A113: ppc64 libstdc++.dylib initializer crashes in pthread_once
4438 * unit-tests/test-cases/multiple-entry-points: added
4439 * src/MachOReaderRelocatable.hpp: make sure that if there are multiple symbols with the same
4440 address, that we properly make zero length atoms for all but last symbol
4442 2006-02-24 Nick Kledzik <kledzik@apple.com>
4444 * src/Options.cpp: <rdar://problem/4456093> ld64 doesn't realpath(3) B&I tracing paths
4446 2006-02-24 Nick Kledzik <kledzik@apple.com>
4448 * src/Options.cpp: <rdar://problem/4457078> 9A110: ld64 can't deal with section names >16 chars
4450 2006-02-23 Nick Kledzik <kledzik@apple.com>
4452 * src/MachOWriterExecutable.hpp: use vector.reserve() to minimize re-allocations
4453 * src/Options.cpp: use vector.reserve() to minimize re-allocations
4454 * src/MachOReaderRelocatable.hpp: use vector.reserve() to minimize re-allocations
4455 * src/MachOReaderDylib.hpp: use vector.reserve() to minimize re-allocations
4456 * src/ld.cpp: use vector.reserve() to minimize re-allocations
4458 2006-02-23 Nick Kledzik <kledzik@apple.com>
4460 <rdar://problem/4455927> ld64 creates corrupt executables (and has malloc errors) with -headerpad option
4461 * src/MachOWriterExecutable.hpp: Change LoadCommandsPaddingAtom<A>::setSize() to update fLargestAtomSize
4462 * unit-tests/test-cases/header-pad: added
4464 2006-02-23 Nick Kledzik <kledzik@apple.com>
4466 <rdar://problem/4455192> ld64 creates invalid static executables
4467 * src/MachOWriterExecutable.hpp: Change MachHeaderAtom<A>::copyRawContent() to create correct header
4468 for static executables. Change SymbolTableLoadCommandsAtom to skip LC_DYSYMTAB for static executables
4469 * src/machochecker.cpp: Add tests that static executables are well formed
4470 * unit-tests/test-cases/static-executable: added
4472 2006-02-22 Nick Kledzik <kledzik@apple.com>
4474 * src/Options.cpp: <rdar://problem/4453468> chnage printf on unknown arg to a throw
4476 ----- Tagged ld64-39
4478 2006-02-20 Nick Kledzik <kledzik@apple.com>
4480 * unit-tests/test-cases/read-only-relocs: added new test case
4481 * src/MachOWriterExecutable.hpp: <rdar://problem/4448922> detect and error on relocs in read-only sections
4482 * src/MachOReaderRelocatable.hpp: fix parsing of i386 absolute addressing relocs
4484 2006-02-20 Nick Kledzik <kledzik@apple.com>
4486 * unit-tests/test-cases/stabs-coalesce: added new test case
4487 * src/ld.cpp.hpp: <rdar://problem/4449226> in collectStabs removed unused stabs
4489 ----- Tagged ld64-38
4491 2006-02-17 Nick Kledzik <kledzik@apple.com>
4493 * src/MachOWriterExecutable.hpp: <rdar://problem/4434578> set correct n_sect field of stabs
4495 2006-02-15 Nick Kledzik <kledzik@apple.com>
4497 * src/MachOReaderArchive.hpp: <rdar://problem/4441920> with -all_load skip over both kinds of SYMDEFs
4498 * unit-tests/test-cases/archive-basic/Makefile: add -all_load test case
4500 ----- Tagged ld64-37
4502 2006-02-13 Eric Christopher <echristo@apple.com>
4504 * src/MachOWriterExecutable.hpp (assignFileOffsets): Simplify. Add comments.
4507 2006-02-13 Nick Kledzik <kledzik@apple.com>
4509 * src/MachOWriterExecutable.hpp: in Writer<x86>::fixUpReferenceRelocatable() fix kPCRel32 for external case
4511 2006-02-13 Nick Kledzik <kledzik@apple.com>
4513 * unit-tests/test-cases/zero-fill: added
4514 * src/machochecker.cpp: check that S_ZEROFILL have no file offset
4515 * src/MachOWriterExecutable.hpp: rework assignFileOffsets() to fix rdar://problem/4441145
4517 2006-02-12 Nick Kledzik <kledzik@apple.com>
4519 * src/MachOReaderRelocatable.hpp: <rdar://problem/4440880> fix use of first zero-length c-string in .o file
4521 2006-02-12 Nick Kledzik <kledzik@apple.com>
4523 * src/MachOReaderRelocatable.hpp: <rdar://problem/4440905> fix uninitialized fAlignment
4525 2006-02-12 Nick Kledzik <kledzik@apple.com>
4527 * unit-tests/test-cases/relocs-asm/relocs-asm.s: add pointer-diff cases
4528 * src/Architectures.hpp: make size explicit in ppc/ppc64 kPointerDiff
4529 * src/MachOReaderRelocatable.hpp: don't allow kPointerDiff64 for ppc (just ppc64)
4530 * src/MachOWriterExecutable.cpp: set proper r_length for ld -r of kPointerDiff
4532 ----- Tagged ld64-36
4534 2006-02-08 Nick Kledzik <kledzik@apple.com>
4536 * src/MachOReaderRelocatable.cpp: rdar://problem/4438677 Handle when a .o file dwarf line info entries but no functions
4538 2006-02-08 Nick Kledzik <kledzik@apple.com>
4540 * src/MachOWriterExecutable.cpp: Properly set address of first TEXT section
4541 Keep S_COALESCED attribute for __eh_frame
4543 2006-02-08 Nick Kledzik <kledzik@apple.com>
4545 * src/ld.cpp: Temporarily turn allowable client errors into warnings
4546 * unit-tests/test-cases/allowable-clientMakefile: Temporarily let warnings be ok for above
4547 * src/MachOWriterExecutable.hpp: fix ld -r to not use external relocations for symbols make static
4549 2006-02-08 Nick Kledzik <kledzik@apple.com>
4551 * src/ld.cpp: A sibling in an umbrella can always link with its other siblings
4552 * unit-tests/test-cases/allowable-client: add test case for above
4554 2006-02-08 Nick Kledzik <kledzik@apple.com>
4556 * src/MachOReaderRelocatable.hpp: support LOCAL non-lazy pointers to hidden symbols
4557 * src/machochecker.cpp: verify indirect symbol table
4558 * unit-tests/test-cases/private-non-lazy: added test case
4560 2006-02-07 Nick Kledzik <kledzik@apple.com>
4562 * src/MachOWriterExecutable.hpp: fix calculation of file offsets in ld -r mode
4563 * src/machochecker.cpp: verify segment file offsets are within file
4565 ----- Tagged ld64-35
4567 2006-02-06 Nick Kledzik <kledzik@apple.com>
4569 * ld.cpp: allow parent of sub-framework to link
4570 * unit-tests/test-cases/allowable-client/Makefile: added cases for parent and clients of parent
4572 2006-02-04 Nick Kledzik <kledzik@apple.com>
4574 * unit-tests/test-cases/relocs-c/test.c: added some array cases
4575 * src/MachOReaderRelocatable.hpp: factor out makeReferenceToEH()
4576 * src/MachOWriterExecutable.hpp: add initial support for non-lazy pointer synthesis
4578 ----- Tagged ld64-34
4580 2006-02-04 Nick Kledzik <kledzik@apple.com>
4582 * src/ld.cpp: <rdar://problem/4432917> fix -no_arch_warnings
4583 <rdar://problem/4432932> fix -undefined warning
4584 Do BINCL/EINCL optimization for gfull stabs
4585 Implement "essential symbols" for stabs (-Sp)
4586 Fix allowable clients to only test on direct libraries
4587 * src/MachOReaderRelocatable.hpp: support BINCL/EINCL stabs
4589 2006-02-03 Nick Kledzik <kledzik@apple.com>
4591 * src/machochecker.cpp: add code to check load command alignment
4592 * src/MachOWriterExecutable.hpp: make load command alignment depend on architecture
4594 2006-02-03 Nick Kledzik <kledzik@apple.com>
4596 * unit-tests/test-cases/literals-coalesce: added
4597 * src/MachOReaderRelocatable.hpp: assure all targets of low14 ppc relocs are at least 4-byte alignmented
4599 ----- Tagged ld64-33
4601 2006-02-02 Nick Kledzik <kledzik@apple.com>
4603 * src/MachOReaderRelocatable.hpp: properly coalesce 8-byte literals
4604 * src/MachOWriterExecutable.hpp: support ppc64::kPointerDiff32
4606 ----- Tagged ld64-32
4608 2006-02-02 Nick Kledzik <kledzik@apple.com>
4610 * src/MachOReaderRelocatable.hpp: support anonymous zero fill atoms
4612 2006-02-02 Nick Kledzik <kledzik@apple.com>
4614 * src/ld.cpp: A weak definition is good enough, do not search archives for a non-weak one
4615 * unit-tests/test-cases/archive-weak: add test case for above
4616 * src/MachOReaderRelocatable.hpp: an atom should never have a by-name reference to itself
4617 * src/Options.cpp: prevent .eh symbols from being exported via a -exported_symbols_list
4619 2006-02-01 Nick Kledzik <kledzik@apple.com>
4621 * src/MachOReaderRelocatable.hpp: Support -macosx_version_min 10.5
4623 2006-02-01 Nick Kledzik <kledzik@apple.com>
4625 * src/MachOReaderRelocatable.hpp: don't try to parse debug_line dwarf if no symboled atoms
4627 ----- Tagged ld64-31
4629 2006-02-01 Eric Christopher <echristo@apple.com>
4631 * unit-tests/test-cases/allow-stack-execute/Makefile: Move otool handling...
4632 * unit-tests/include/common.makefile: ... here.
4633 * unit-tests/bin/fail-if-stdin.pl: New.
4634 * unit-tests/test-cases/no-uuid: Ditto.
4635 * src/ld.cpp (Linker::) Add fCreateUUID.
4636 (::Linker): Initialize.
4637 (::collectStabs): Use. Set if dwarf or we have a UUID already.
4638 (::writeOutput): Pass as argument to Writer::write along with option.
4639 * src/Options.h (Option::emitUUID): Declare.
4640 (Option::fEmitUUID): Ditto.
4641 * src/Options.cpp (Option::emitUUID): New.
4642 (parse): Handle -no_uuid.
4643 * src/MachOReaderRelocatable (Reader::Reader): Handle LC_UUID.
4644 * src/ExecutableFile.h (Writer::Write): Add createUUID boolean.
4645 * src/MachOWriterExecutable: Add UUID forward declaration.
4647 (UUIDLoadCommandAtom): Emit LC_UUID if fEmit. New function emit. Size
4649 (Writer::writer): Add handle for LC_UUID. If createUUID emit LC_UUID.
4650 (MachHeaderAtom::copyRawContent): Don't count a load command if its size is
4652 (UUIDLoadCommandAtom::copyRawContent): Depend on fEmit.
4655 2006-01-31 Nick Kledzik <kledzik@apple.com>
4657 * unit-tests/test-cases/dwarf-debug-notes : Added
4658 * src/ld.cpp: don't generate debug note for .eh symbols
4659 * src/MachOReaderRelocatable.hpp: make dwarf line info to atom matching faster and better
4661 2006-01-31 Nick Kledzik <kledzik@apple.com>
4663 * ld64.xcodeproj/project.pbxproj : Make buildable on Leopard
4664 * src/MachOFileAbstraction.hpp: make buildable without latest cctools headers
4666 2006-01-31 Nick Kledzik <kledzik@apple.com>
4668 * src/MachOReaderRelocatable.hpp: better error message for bad relocs
4669 * src/ObjectDump.cpp: add emacs tab settings
4670 * src/SectCreate.h: ditto
4671 * src/SectCreate.cpp: ditto
4672 * src/machochecker.cpp: ditto
4673 * src/ExecutableFile.h: ditto
4675 2006-01-30 Eric Christopher <echristo@apple.com>
4677 * src/ExecutableFile.h: Indent.
4679 2006-01-30 Nick Kledzik <kledzik@apple.com>
4681 * src/MachOReaderRelocatable.hpp: performance improvements
4682 * src/ld.cpp: now that stubs are synthesized in write, don't need to special case anymore
4684 2006-01-30 Nick Kledzik <kledzik@apple.com>
4686 * src/MachOReaderRelocatable.hpp: fix parsing of pcc relocs
4687 * unit-tests/test-cases/relocs-asm/relocs-asm.s: add test case for above
4689 2006-01-29 Nick Kledzik <kledzik@apple.com>
4691 * unit-tests/test-cases/weak_import: added test case
4692 * src/ld.cpp: move code for weak_import mismatch to writer
4693 * src/ObjectFile.h: remove ImportWeakness methods
4694 * src/MachOReaderDylib.hpp: ditto
4695 * src/SectCreate.cpp: ditto
4696 * src/Architectures.hpp: add new ReferenceKinds for weak_imports
4697 * src/MachOReaderRelocatable.hpp: implement new ReferenceKinds
4698 * src/MachOWriterExecutable.hpp: handle new ReferenceKinds and weak_import mismatches
4700 2006-01-29 Nick Kledzik <kledzik@apple.com>
4702 * src/Options.cpp: verify -allow_stack_execute is only used on main executables
4704 2006-01-29 Nick Kledzik <kledzik@apple.com>
4706 * src/MachOReaderRelocatable.hpp: sync with latest dwarf reader from Geoff
4707 * src/debugline.c: sync with latest dwarf reader from Geoff
4709 2006-01-27 Eric Christopher <echristo@apple.com>
4711 * src/ld.cpp (Linker::syntesizeStabs): Correct spelling. Update all uses.
4713 2006-01-27 Eric Christopher <echristo@apple.com>
4715 * src/Options.h (Options): Add hasExecutableStack, fExecutableStack.
4716 * src/Options.cpp (Options::hasExecutableStack): New.
4717 (Options::parse): Parse -allow_stack_execute.
4718 * src/MachOWriterExecutable.hpp (MachHeaderAtom::copyRawContent):
4719 Implement MH_ALLOW_STACK_EXECUTION.
4720 * unit-tests/include/common.makefile (FAIL_IF_EMPTY): New.
4721 * unit-tests/bin/fail-if-no-stdin.pl: New file.
4722 * unit-tests/test-cases/allow-stack-execute: New directory.
4724 2006-01-27 Nick Kledzik <kledzik@apple.com>
4726 * src/MachOFileAbstraction.hpp: rely on latest system headers
4727 * src/MachOWriterExecutable.hpp: fix ppc stubs.
4728 wrote new relocationNeededInFinalLinkedImage() to replace common code
4730 2006-01-27 Eric Christopher <echristo@apple.com>
4732 * src/ld.cpp (logTraceInfo): New.
4733 (Linker::addArchive): Use.
4734 (Linker::addDylib): Ditto.
4735 * src/ObjectFile (ReaderOptions::fTraceOutputFile): New.
4736 * src/MachOReaderArchive.hpp (Reader::Reader): Move trace
4737 logging to Linker::addArchive.
4738 * src/Options.cpp (parsePreCommandLineEnvironment): Check
4739 LD_PRINT_FILE if tracing dylibs or archives.
4741 2006-01-26 Nick Kledzik <kledzik@apple.com>
4743 * src/MachOWriterExecutable.hpp: handle NULL strings in SO debug notes
4745 2006-01-26 Nick Kledzik <kledzik@apple.com>
4747 * src/MachOWriterExecutable.hpp: fix header padding calculation and thread state
4749 2006-01-26 Nick Kledzik <kledzik@apple.com>
4751 Rewrite all stabs processing.
4752 Move sythesize of debug notes into ld.cpp
4754 2006-01-26 Nick Kledzik <kledzik@apple.com>
4756 * src/MachOWriterExecutable.hpp: fix ppc and ppc64 stub relocs
4758 2006-01-25 Nick Kledzik <kledzik@apple.com>
4760 * ld64.xcodeproj/project.pbxproj: special case building in Curry
4762 2006-01-25 Nick Kledzik <kledzik@apple.com>
4764 * src/MachOWriterExecutable.hpp: fix bugs in stub/lazy-pointer synthesis
4766 2006-01-24 Eric Christopher <echristo@apple.com>
4768 * src/ld.cpp (Linker::createReaders): Change logging title to XBS.
4769 (Linker::addDylib): Ditto.
4770 * src/MachOReaderArchive.hpp (Reader::Reader): Ditto.
4771 * src/Options.h (fPrintOptions): New.
4772 * src/Options.cpp (Options::Options): Initialize above.
4773 (Options::checkForFile): Change logging title to XBS.
4774 (Options::findFramework): Ditto.
4775 (Options::parse): Add log for options.
4776 (Options::parsePreCommandLineEnvironmentSettings): Add LD_TRACE_ARCHIVES,
4777 LD_TRACE_DYLIBS, and LD_PRINT_OPTIONS.
4779 2006-01-24 Nick Kledzik <kledzik@apple.com>
4781 * src/MachOReaderRelocatable.hpp: better C++ eh parsing
4783 2006-01-23 Eric Christopher <echristo@apple.com>
4785 * unit-tests/bin/fail-if-exit-zero.pl: New.
4786 * unit-tests/include/common.makefile (FAIL_IF_SUCCESS): Use.
4787 * unit-tests/allowable-client: New test.
4788 * src/ld.cpp (Linker::addDylib): Check allowable clients before adding dylib.
4789 * src/Options.h (allowableClients): New.
4790 (clientName): Ditto.
4791 (fAllowableClients): Ditto.
4792 (fClientName): Ditto.
4793 * src/Options.cpp: Implement above.
4794 (parse): Handle -allowable_client and -client_name.
4795 * src/MachOReaderDylib.hpp (getAllowableClients): New.
4796 (fAllowableClients): Ditto.
4797 (Reader): Process LC_SUB_CLIENT load command.
4798 * src/ObjectFile.h (parentUmbrella): New.
4799 (getAllowableClients): New.
4800 * src/MachOWriterExecutable.hpp (AllowableClientLoadCommandsAtom): New.
4802 2006-01-23 Nick Kledzik <kledzik@apple.com>
4804 * unit-tests/test-cases/archive-basic: added
4805 * src/ld.cpp: fix shadowed local variable
4806 * src/FileAbstraction.hpp: <rdar://problem/4417372> ld64 shouldn't inline when building debug
4808 2006-01-23 Nick Kledzik <kledzik@apple.com>
4810 * src/ld.cpp: fix symbol not found error message
4811 * src/MachOReaderDylib.hpp: add logging to hash table
4812 * src/MachOReaderRelocatable.hpp: enable stabs processing. Handle static functions with stubs
4813 handle labeled cstrings.
4814 * src/MachOWriterExecutable.hpp: properly suppress atoms not in symbol table. fix low14 error check.
4816 * unit-tests/test-cases/relocs-literals/test.c: add more interesting edge cases
4818 2006-01-17 Nick Kledzik <kledzik@apple.com>
4820 * src/MachOReaderRelocatable.hpp: tweaks to synthesizing debug notes
4822 2006-01-16 Nick Kledzik <kledzik@apple.com>
4824 * src/debugline.{sh}: added
4825 * src/MachOReaderRelocatable.hpp: synthesize debug notes SOL from dwarf
4826 * src/MachOWriterExecutable.hpp: fix lazy pointer section
4827 * src/ObjectDump.hpp: Fix conditionalization
4828 * unit-tests/test-cases/dwarf-strip: added
4830 2006-01-11 Nick Kledzik <kledzik@apple.com>
4832 * src/MachOReaderRelocatable.hpp: support Tiger crt1.o build with old ld64
4833 * src/ObjectDump.hpp: Support -arch option
4835 2006-01-10 Nick Kledzik <kledzik@apple.com>
4837 * src/MachOWriterExecutable.hpp: fix stubs for ppc64
4838 * src/MachOFileAbstraction.hpp: fix typo for macho_routines
4839 * ld64.xcodeproj/project.pbxproj: add machochecker target
4840 * src/machochecker.cpp: new skeleton for checking mach-o file bit
4841 * unit-tests/: Add support for running machochecker
4843 2006-01-10 Nick Kledzik <kledzik@apple.com>
4845 * src/MachOReaderRelocatable.hpp: warn if dwarf can't be parsed
4846 * src/MachOReaderArchive.hpp: modTime for OSO stabs from archives is .a modTime
4848 2006-01-09 Nick Kledzik <kledzik@apple.com>
4850 * track modification time of .o files so that sythesized OSO stab will have it
4852 2006-01-09 Nick Kledzik <kledzik@apple.com>
4854 * src/MachOFileAbstraction.hpp: add macho_uuid_command
4855 * src/MachOWriterExecutable.cpp: add UUID load command to generated files
4857 2006-01-09 Nick Kledzik <kledzik@apple.com>
4859 * src/MachOReaderDylib.hpp: no longer keep dylib memory mapped
4860 * src/ld.cpp: don't track dylib sizes because they are not longer memory mapped
4862 2006-01-05 Nick Kledzik <kledzik@apple.com>
4864 * src/MachOReaderRelocatable.hpp: support new relocations
4866 2006-01-05 Nick Kledzik <kledzik@apple.com>
4868 * src/MachOReaderDylib.hpp: support MH_DYLIB_STUB
4869 * src/MachOReaderRelocatable.hpp: Add Geoff's comp unit extractor
4871 2006-01-05 Nick Kledzik <kledzik@apple.com>
4873 refactor: transform Atom::dontStripName() to getSymbolTableInclusion()
4874 * src/ld.cpp: pass dyld_stub_binding_helper to writer
4875 * src/MachOReaderRelocatable.hpp: update synthesized stabs
4876 Ignore stubs and lazy pointers in .o files
4877 Support initializers and terminators
4878 * src/MachOWriterExecutable.hpp: synthesize stubs and lazy pointers as needed
4879 * ld64.xcodeproj/project.pbxproj: change Release target to build with dwarf
4881 2006-01-03 Eric Christopher <echristo@apple.com>
4883 * src/Options.h (multipleDefinitionsInDylibs): Declare.
4884 (overridingDefinitionInDependentDylib): Ditto.
4885 (warnOnMultipleDefinitionsInObjectFiles): Ditto.
4886 (multiplyDefined): Remove.
4887 (multiplyDefinedUnused): Ditto.
4888 (fMultiplyDefined): Ditto.
4889 (fWarnOnMultiplyDefined): New.
4890 (fMultiplyDefinedDynamic): Ditto.
4891 * src/Options.cpp (Options::Options): Initialize above.
4892 (overridingDefinitionInDependentDylib): New.
4893 (multipleDefinitionsInDylibs): Ditto.
4894 (warnOnMultipleDefinitionsInObjectFiles): Ditto.
4895 (parse): Update comments. Fix parsing of -y option.
4896 Update error message for -dead_strip. Parse above
4899 2006-01-02 Nick Kledzik <kledzik@apple.com>
4901 * Refactor: move Atom::writeContent() to Writer
4903 2005-12-23 Nick Kledzik <kledzik@apple.com>
4905 * Reworked, simplify, and document test harness
4906 * unit-tests/README: Added
4908 2005-12-23 Nick Kledzik <kledzik@apple.com>
4910 * src/MachOReaderRelocatable.hpp: fixes for Objective-C
4911 * unit-tests/test-cases/relocs-objc: Added
4913 2005-12-22 Nick Kledzik <kledzik@apple.com>
4915 * src/MachOReaderRelocatable.hpp: fix check that next reloc is pair
4916 * src/MachOReaderRelocatable.hpp: Add code to synthesize essential stabs from dwarf
4918 2005-12-21 Nick Kledzik <kledzik@apple.com>
4920 * src/MachOReaderRelocatable.hpp: Fix parsing of literal sections
4921 * src/MachOWriterExecutable.hpp: Fix writing of literal sections
4922 * unit-tests/test-cases/relocs-literals: Added
4924 2005-12-15 Eric Christopher <echristo@apple.com>
4926 * src/Options.h (enum Treatment): New.
4927 (enum PICTreatment): Delete.
4928 (enum VersionMin): New.
4930 (macosxVersionMin): Ditto.
4931 (multiplyDefined): Ditto.
4932 (multiplyDefinedUnused): Ditto.
4933 (setVersionMin): Ditto.
4934 (setPICTreatment): Delete.
4935 (setReadOnlyRelocTreatment): Ditto.
4936 (picTreatment): Adjust return type.
4937 (parseTreatment): New.
4939 (fVersionMin): Ditto.
4940 (fPICTreatment): Change type.
4941 (fMultiplyDefined): New.
4942 (fMultiplyDefinedUnused): Ditto.
4943 (fLimitUndefinedSymbols): Ditto.
4945 * src/Options.cpp: Fix whitespace. Add comments on options.
4946 (Options::Options): Add initializers for new variables.
4947 (Options::prebind): New.
4948 (Options::macosxVersionMin): Ditto.
4949 (Options::parseTreatment): Ditto.
4950 (Options::setVersionMin): Ditto.
4951 (Options::setReadOnlyRelocTreatment): Delete.
4952 (Options::setPICTreatment): Ditto.
4953 (Options::Parse): Update for above. Add comments.
4955 2005-12-15 Nick Kledzik <kledzik@apple.com>
4957 * src/MachOReaderRelocatable.hpp: Add comments about dwarf
4959 2005-12-14 Nick Kledzik <kledzik@apple.com>
4961 * src/ELFFileAbstraction.hpp: Added
4962 * src/ELFReaderRelocatable.hpp: Added
4963 * Lot of fixes for new architecture
4964 * Added __OPEN_SOURCE__ to "Preprocessor Macros" to disable new architecture support by default
4966 2005-12-13 Nick Kledzik <kledzik@apple.com>
4968 * src/MachOReaderRelocatable.hpp: check for S_ATTR_DEBUG and ignore those sections
4969 * unit-tests/test-cases/dwarf-ignore: added
4971 2005-12-12 Nick Kledzik <kledzik@apple.com>
4973 * Added test harness and three initial tests:
4974 relocs-asm, relocs-c, and hello-world
4976 2005-12-12 Nick Kledzik <kledzik@apple.com>
4978 * src/MachOReaderRelocatable.hpp: Massive refactoring:
4979 Now there are three Atom classes, Chopping into Atoms
4980 is done on label boundaries or by knowledge of special
4981 sections, Share lots of ppc/ppc64 code.
4982 Stabs process code is temporarily disabled.
4984 2005-12-12 Nick Kledzik <kledzik@apple.com>
4986 * src/ObjectDump.cpp: Add command line options: -no_content, -stabs, -no_sort
4988 2005-12-11 Eric Christopher <echristo@apple.com>
4990 * src/Options.cpp: Reformat.
4991 * src/Options.h: Ditto.
4993 2005-12-07 Eric Christopher <echristo@apple.com>
4995 * src/MachOReaderRelocatable.hpp (Atom::getAlignment):
4996 When calculating alignment of an Atom, take into account
4997 the alignment from which we pulled the Atom.
4999 2005-12-06 Nick Kledzik <kledzik@apple.com>
5001 * src/Options.cpp src/Options.h: Add design comments
5003 2005-12-05 Eric Christopher <echristo@apple.com>
5005 * src/ld.cpp (Linker::createWriter): Uncomment ppc64 and
5008 2005-12-05 Eric Christopher <echristo@apple.com>
5010 * ChangeLog: New file.
5012 2005-12-02 Nick Kledzik <kledzik@apple.com>
5014 * src/ObjectFile.h: Add design comments
5016 2005-11-30 Nick Kledzik <kledzik@apple.com>
5018 * Fix uses of __OPEN_SOURCE__
5020 2005-11-28 Nick Kledzik <kledzik@apple.com>
5022 * Refactor Atom to use getDefinitionKind()
5024 2005-11-21 Nick Kledzik <kledzik@apple.com>
5026 * src/MachOWriterExecutable.hpp: don't generate section for commons in -r mode
5028 2005-11-18 Nick Kledzik <kledzik@apple.com>
5032 2005-11-18 Nick Kledzik <kledzik@apple.com>
5034 * src/ObjectDump.cpp: make work with command line arguments
5036 2005-11-18 Nick Kledzik <kledzik@apple.com>
5038 * Massive rework to remove preprocessor conditionals and use templates
5040 2005-11-14 Nick Kledzik <kledzik@apple.com>
5042 * Created new Subversion repository for ld64 from cvs tag ld64-27.2