X-Git-Url: https://git.saurik.com/apple/ld64.git/blobdiff_plain/74cfe461234fcf76aadb30ed686f281f06b555cd..4f3e367c520f1fd8affdc77dd9e2b6bc6c3c693b:/ChangeLog diff --git a/ChangeLog b/ChangeLog index ce470b0..1a79a07 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,1189 +1,542 @@ -2006-09-22 Nick Kledzik +2008-07-10 Nick Kledzik - ld64.xcodeproj/project.pbxproj: change install name back to ld64 - src/Options.cpp: remove support for rolling over to ld_classic - src/ld.cpp: remove support for rolling over to ld_classic + * src/LTOReader.hpp: improve missing symbol error message ------ Tagged ld64-62 +2008-07-08 Nick Kledzik -2006-08-15 Nick Kledzik - - wrong error message when symbol is found in unused indirect library - src/ld.cpp: remove indirect libraries if they are not re-exported - unit-tests/test-cases/indirect-dylib: added test case - - -2006-08-15 Nick Kledzik - - alignment needs to be richer - src/ObjectFile.h: define ObjectFile::Alignment class for tracking rich alignment info - src/ld.cpp: modify SymbolTable::add() to work with new Alignment type - src/MachOReaderRelocatable.hpp: use new Alignment type. Remove alignAtLeast() and handleAnonymousNonLazyPointers() - src/MachOWriterExecutable.hpp: update for new Alignment type, use modulus when calculating layout address - src/ObjectDump.cpp: print richer Alignment info - unit-tests/test-cases/align-modulus: added test case - - -2006-08-11 Nick Kledzik - - remove OPEN_SOURCE conditionals around x86_64 support - - -2006-07-31 Nick Kledzik - - ld64 while linking cc1 [ when dead_strip is ON] - src/ld.cpp: Add ivar fAtomsWithUnresolvedReferences to track atoms not initially resolvable - unit-tests/test-cases/dead_strip-archive: added test case + ld: add support for mllvm LTO options + * src/Options.cpp: support -mllvm option + * src/LTOReader.hpp: call lto_codegen_debug_options() with -mllvm options + * src/ld.cpp: pass llvmOptions to optimize() + * src/Options.h: add fLLVMOptions + * src/ArchiveReader.hpp: add llvmOptions parameter to optimize() + * src/ObjectFile.h: add llvmOptions parameter to optimize() + * unit-tests/test-cases/lto-llvm-options: add test case -2006-07-31 Nick Kledzik +2008-06-04 Nick Kledzik - x86_64: instructions with immediate and rip-relative operands need to use new relocation types - src/MachOWriterExecutable.hpp: generate new reloc types in -r mode - src/MachOReaderRelocatable.hpp: parse new reloc types - unit-tests/test-cases/relocs-asm/relocs-asm.s: add test cases for new reloc type - + * src/LTOReader.hpp: if lto_codegen_add_module() fails, add explanation to error message -2006-07-18 Nick Kledzik +2008-06-04 Nick Kledzik - src/MachOReaderRelocatable.hpp: suppress warning about dwarf info parsing for one benign no-op case - the compiler emits when there are not functions in the __text section - + * src/ObjectFile.h: add deadAtoms parameter to optimize() + * src/ld.cpp: ditto + * src/ArchiveReader.hpp: ditto + * src/MachOReaderRelocatable.hpp: handle llvm use of 0x1B pointer encodings in CIEs + * src/LTOReader.hpp: make sure libLTO.dylib knows about any llvm symbol coalesced away + * unit-tests/test-cases/lto-weak-native-override: add test case -2006-07-17 Nick Kledzik - faster debug note generateion - src/ld.cpp: rework collectDebugInfo() to produce all debug notes in one pass, intead of a - pass per .o file. Added timing info for collectDebugInfo() to -print_statistics - unit-tests/test-cases/dwarf-debug-notes-r/Makefile: add expliced -arch to ld -r - unit-tests/test-cases/dwarf-debug-notes-r/expected-stabs: alter for new debug notes order - +2008-06-04 Nick Kledzik -2006-07-17 Nick Kledzik + LTO : 176.gcc and 177.mesa build failure at -O4 + * src/LTOReader.hpp: make sure internal is returned by getAtoms() + * unit-tests/test-cases/lto-archive-dylib: update test case - ld64 VSIZE is 1.18GB when building Finder ppc64 - src/ld.cpp: fixed typo in createReader() that prevented dylibs from being unmapped ------ Tagged ld64-61.1 +2008-05-06 Nick Kledzik -2006-07-11 Nick Kledzik - - ld64-61: gcc DejaGnu tests failing due to -arch followed by unknown architecture name - src/Options.cpp: map ppc750, ppc7400, ppc7450, and ppc970 to ppc. Improve error message + ARM ld should take W bit off of maxprot for __TEXT segment + * src/MachOWriterExecutable.hpp: for iPhone always set maxprot to be initprot in all segments -2006-07-11 Nick Kledzik - If -arch is missing, rollover to ld_classic does not happen - src/Options.h: make gotoClassicLinker() public - src/ld.cpp: call gotoClassicLinker() if the inferred architecture is ppc or i386 +2008-05-06 Nick Kledzik ------ Tagged ld64-61 + encryptable images may not be signable + * src/MachOWriterExecutable.hpp: use minimum header padding when aligning __text section -2006-06-29 Nick Kledzik - ld64 should be renamed to ld - src/Options.cpp: exec() ld_classic if -arch ppc or -arch i386 is seen - src/ld.cpp: alter version string - ld64.xcodeproj/project.pbxproj: change install location to /usr/bin/ld, add symlink from /usr/bin/ld64 - doc/man/man1/ld.1: added - ------ Tagged ld64-60 +----- Tagged ld64-85 (Xcode 3.1) -2006-06-28 Nick Kledzik - - Can't link large ppc64 program: ld64 says "bl out of range" - MachOWriterExecutable.hpp: fix branch island generation to work for weak_import functions - and properly chain together branch islands - MachOReaderRelocatable.hpp: improve performance of huge .o file reading by sorted references - only when done +2008-04-29 Nick Kledzik -2006-06-28 Nick Kledzik + * ld64.xcodeproj/project.pbxproj: is moving from /usr/local/include to /Developer/usr/local/include - MySQL-36 fails to build with ld64-59 - src/MachOReaderRelocatable.hpp: back out fix for 4585335 - src/MachOWriterExecutable.hpp: back out fix for 4585335 -2006-06-27 Nick Kledzik +2008-04-29 Nick Kledzik - src/MachOReaderRelocatable.hpp: handle N_GSYM without ending :G() since that is how - dwarf debug notes are formed. + ld doesn't honor "rightmost" -syslibroot argument + * src/Options.cpp: if last -syslibroot is /, then ignore all syslibroots -2006-06-23 Nick Kledzik - + GLRendererFloat has bad __eh_frame section caused by mixing llvm-gcc and gcc object files + * src/MachOReaderRelocatable.hpp: make all atoms in __eh_frame section have 1-byte alignment + * src/MachOWriterExecutable.hpp: make __eh_frame section have pointer sized alignment -2006-06-23 Nick Kledzik - ld64 doesn't support variant linking -framework fw,_debug - src/Options.cpp: enhance findFramework() to support suffixes +2008-04-17 Nick Kledzik ------ Tagged ld64-59 + * src/MachOReaderRelocatable.hpp: better cpu subtype support -2006-06-22 Nick Kledzik - ld64 lost DWARF debug notes - src/MachOReaderRelocatable.hpp: add fHasUUID so kDebugInfoStabsUUID can be set later - unit-tests/test-cases/dwarf-debug-notes-r: added test case +2008-04-14 Nick Kledzik -2006-06-21 Nick Kledzik - - python 64-bit address miscalculation - src/MachOReaderRelocatable.hpp: change getTargetOffset() to sign extend the 32-bit value to 64-bits + ld64 has bad ARM branch island check + * src/MachOWriterExecutable.hpp: in addBranchIslands() don't force large arm programs to fail -2006-06-21 Nick Kledzik - - ld64 seems to offset things incorrectly when using -r - src/MachOWriterExecutable.hpp: in -r mode, virtual sections should not increment address - - ------ Tagged ld64-58 - -2006-06-16 Nick Kledzik - - src/rebase.cpp: fix page alignment problem - src/rebase.cpp: fix endianess problem with local non-lazy pointers - -2006-06-15 Nick Kledzik - - src/rebase.cpp: fix to build in CurryWeed - ld64.xcodeproj/project.pbxproj: fix to build properly in CurryWeed - -2006-06-15 Nick Kledzik - - Support .objc_class_name_* symbols - src/ObjectFile.h: Add kSymbolTableInAsAbsolute - src/MachOReaderRelocatable.hpp: synthesize references to required objc classes - src/MachOWriterExecutable.hpp: write objc_class_name as absolute symbol - unit-tests/test-cases/objc-references: added - -2006-06-15 Nick Kledzik - - SECTION_ATTRIBUTES unset in ppc64 mach-o header - src/MachOWriterExecutable.hpp: add section attribute for sections with code - -2006-06-15 Nick Kledzik - - ld64 bogus duplicate symbol name linking GNU libobjc - src/MachOReaderRelocatable.hpp: only special case Apple objc runtime objc classes - -2006-06-15 Nick Kledzik - - x86_64: ".align" directive not honored - src/MachOReaderRelocatable.hpp: change code alignment to not depend on atom size - -2006-06-14 Nick Kledzik - - jump table into middle of weak symbol causes error - src/MachOReaderRelocatable.hpp: create direct references to the interior of weak symbols - src/MachOWriterExecutable.hpp: do not error on absolute references to interior of weak symbols - -2006-06-13 Nick Kledzik - - src/Options.cpp: allow -image_base as an alias for -seg1addr - -2006-06-13 Nick Kledzik - - implement -d - src/Options.h: add fMakeTentativeDefinitionsReal - src/Options.cpp: set fMakeTentativeDefinitionsReal if -d option is found - src/MachOWriterExecutable.hpp: turn tentative into real definition if makeTentativeDefinitionsReal - unit-tests/test-cases/btentative-to-real: added test case - -2006-06-13 Nick Kledzik - implement -bundle_loader - src/Options.h: add fBundleLoader bit to DynamicLibraryOptions - src/Options.cpp: handle -bundle_loader - src/ld.cpp: pass fBundleLoader bit to MachOReaderDylib - src/MachOReaderDylib.hpp: support reading MH_EXECUTE files if fBundleLoader is set - src/MachOWriterExecutable.hpp: set bundle loader ordinal as EXECUTABLE_ORDINAL - unit-tests/test-cases/bundle_loader: added test case +2008-04-10 Nick Kledzik -2006-06-12 Nick Kledzik - - -syslibroot can cause "can't find ordinal for imported" error - src/MachOReaderDylib.hpp: in Reader::reExports() compare install path in addition to load path - - -2006-06-10 Nick Kledzik - - Need rebasing tool - src/rebase.cpp: added - unit-tests/test-cases/rebase-basic: added - doc/man/man1/rebase.1: added - ld64.xcodeproj/project.pbxproj: added rebase target. changed all targets to build with dwarf + * src/MachOWriterExecutable.hpp: fix stubs used with lazy dylibs -2006-06-10 Nick Kledzik - - src/machochecker.cpp: add some ppc reloc sanity checking +----- Tagged ld64-84.4 ------ Tagged ld64-57 +2008-04-10 Nick Kledzik -2006-06-06 Nick Kledzik - - ld64 is not adding a final '/' char on the initial directory-name SO stab debug map entry - ld.cpp: Change Linker::synthesizeStabs() to assure directory SO always has a trailing slash - unit-tests/test-cases/dwarf-debug-notes/expected-stabs: update with trailing / + SPEC2000/eon built with -mdynamic-no-pic won't run + * src/Architectures.hpp: added arm::kReadOnlyPointer + * src/MachOReaderRelocatable.hpp: generate arm::kReadOnlyPointer + * src/MachOWriterExecutable.hpp: use arm::kReadOnlyPointer + * src/machochecker.cpp: allow MH_PIE bit + * unit-tests/test-cases/switch-jump-table: added test cases -2006-06-06 Nick Kledzik - - -sectcreate of a 0-byte section fails - MachOWriterExecutable.cpp: Don't error out on zero length segments - MachOWriterExecutable.cpp: For ppc64 reloc base address is the first writable segment iff - there is a writable segment >4GB from base address - -2006-06-04 Eric Christopher - - Radar 4560240 - Radar 3964999 - * src/ld.cpp (createReader): Fixed error message. - (resolve): Ditto. - (resolveFrom): Ditto. - (checkUndefines): Ditto. - ------ Tagged ld64-56 - -2006-05-23 Nick Kledzik - - No debug notes for ObjC methods when linking with ld64 - ld.cpp: don't limit debug notes to functions starting with underscore - -2006-05-22 Nick Kledzik - - ld64 spends much time in mach_o::relocatable::Reader::findAtomByName - * src/MachOReaderRelocatable.hpp: add makeReferenceToSymbol() so that x86_64 does not need to do by-name lookups - -2006-05-22 Nick Kledzik - - remove inferring warning - * ld.cpp: Remove "inferring" warning. If a link failed and now arch was specifed add which arch was - inferred to error message - -2006-05-19 Nick Kledzik - - ld64 does not honor -arch_multiple - * ld.cpp: If fOptions.printArchPrefix(), add architecture name to error message - -2006-05-19 Nick Kledzik - - Support S_16BYTE_LITERALS section types - * src/MachOReaderRelocatable.hpp: support S_16BYTE_LITERALS - * src/MachOWriterExecutable.hpp: support S_16BYTE_LITERALS - -2006-05-19 Nick Kledzik - - "warning can't parse dwarf compilation unit info" warnings building debug - * src/MachOReaderRelocatable.hpp: fix bugs in dwarf line table parsing - ------ Tagged ld64-55 - -2006-05-18 Nick Kledzik - - Default the pagezero size to 4GB for x86-64 - * src/Options.cpp: Chnage default the pagezero size to 4GB for x86-64 - -2006-05-18 Nick Kledzik - - x86_64 CarbonCore fails to link with "atom not found in symbolIndex" - * src/MachOWriterExecutable.hpp: in buildObjectFileFixups() don't call addObjectRelocs() on kNoFixUp references - -2006-05-18 Nick Kledzik - - ld64: .section defaults to read-only - * src/MachOReaderRelocatable.hpp: default unknown segments to r/w - -2006-05-18 Nick Kledzik - - -fvisibility=hidden causes crashes for x86_64 - * src/MachOWriterExecutable.hpp: properly handle RIP relative tentative definitions - -2006-05-12 Nick Kledzik - - * src/Architectures.hpp: add x86::kAbsolute32 - * src/MachOReaderRelocatable.hpp: generate x86::kAbsolute32 for mdynamic-no-pic instructions - * src/MachOWriterExecutable.hpp: process x86::kAbsolute32 reference kind - ------ Tagged ld64-54 - -2006-05-11 Nick Kledzik - - CF-393 failes to link for x86_64 - * src/MachOWriterExecutable.cpp: fix sign extension for Rel32 relocs in Writer::fixUpReferenceRelocatable - -2006-05-11 Nick Kledzik - - warning arch x86_64 not found using i386 - * src/ld.cpp: remove hack to allow x86_64 to link against i386 dylibs - - -2006-05-10 Nick Kledzik - - x86_64: .objc_class_name symbol names scrambled - * src/MachOReaderRelocatable.hpp: properly compute alignment of __OBJC __class sections - - -2006-05-08 Nick Kledzik - - Support -dead_strip - * src/Options.h/cpp: implement -why_load and -why_live. Enable -dead_strip. - * src/MachOReaderArchive.hpp: implement -why_load - * src/MachOReaderRelocatable.hpp: suppress GCC_except_table* symbols in final output - * src/ld.cpp: implement dead code stripping - * unit-tests/test-cases/dead_strip: added - ------ Tagged ld64-53 - -2006-05-05 Nick Kledzik - - * src/Options.cpp: make 10.4 be minimum OS version for newer architectures - -2006-05-05 Nick Kledzik - - N_SO symbols in 64-bit builds have a zero address for n.n_value - * src/ld.cpp: for SO stabs, associate first and last atom in the SO range - * src/MachOWriterExecutable.hpp: use atom associated with SO stab to set ins n_value - -2006-05-05 Nick Kledzik - - * MachOWriterExecutable.hpp: fix end FUN stab to have length of function - - -2006-05-02 Nick Kledzik - - 64-bit main executables should have 4GB zero page by default - * src/Opptions.cpp: change default pagezero_size to 4GB for ppc64 - 64 bit: apps with -mdynamic-no-pic seg fault when page zero > 4GB - * src/MachOWriterExecutable.cpp: rework pagezero for ppc64 so that if any mdynamic-no-pic code - is found, the code is kept in the low 2GB, and a new segment is create to map away up to 4GB. - -2006-05-02 Nick Kledzik - - * src/Opptions.cpp: remove warning about -stack_addr not specified. Add warning if 32-bit stack - overlaps shared region - ------ Tagged ld64-52.1 - -2006-05-01 Nick Kledzik - - * src/MachOReaderRelocatable.cpp: rework handleAnonymousNonLazyPointers() to handle anl's in the middle - the __data section too. - ------ Tagged ld64-52 - -2006-04-28 Nick Kledzik - - 64-bit: 9A152 TextEdit crashes in dlopen on bring-up - * src/MachOReaderRelocatable.cpp: rework anonymous non-lazy-pointer detection - -2006-04-28 Nick Kledzik - - 64 Bit: Development build of ppc64 TextEdit gets confused about static variables - * src/MachOReaderRelocatable.cpp: mark non-lazy-pointer atoms as scopeTranslationUnit if targetting a static symbol - - - -2006-04-21 Nick Kledzik - - * src/Options.cpp: fix default address for ppc64 custom stack - * src/MachOWriterExecutable.cpp: fix set up of ppc64 custom stack - - -2006-04-14 Nick Kledzik - - * src/Options.cpp: fix -sub_library processing to work it dylib is specifed with leaf name - ------ Tagged ld64-51.1 - -2006-04-13 Nick Kledzik - - 64-bit: 9A152 TextEdit crashes in dlopen on bring-up - * src/MachOReaderRelocatable.hpp: when detecting anonymous non-lazy-pointers disqualify data - that points to static or global symbols - * src/ld.cpp: print version of ld64 in error messages - - ------ Tagged ld64-51 - -2006-04-11 Nick Kledzik - - exported symbols not properly stripped - * src/MachOReaderRelocatable.hpp: enable AnonymousAtom::setScope() - -2006-03-31 Nick Kledzik - - ld64 fails when linking debug ppc64 HIToolbox - * src/MachOReaderRelocatable.hpp: handle anonymous non-lazy pointers encoded with local relocations - * src/MachOWriterExecutable.hpp: in -r mode, only generated INDIRECT_SYMBOL_LOCAL for non-lazy targets that - - -2006-03-31 Nick Kledzik - - ld64 should remove generated file if link errors out - * src/MachOWriterExecutable.hpp: catch exceptions in Writer::write(), delete output file, and rethrow - - ------ Tagged ld64-50 - - -2006-03-29 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: synthesize .objc_class_name symbols - * src/MachOFileAbstraction.hpp: use strncpy for sect/seg names to zero fill trailing space - -2006-03-28 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: fix spurious warning about dwarf line info - ------ Tagged ld64-49.1 - -2006-03-25 Nick Kledzik - - * MachOWriterExecutable.hpp : don't complain about ppc64 dyld being based > 4GB - ------ Tagged ld64-49 - -2006-03-24 Nick Kledzik - - * src/MachOWriterExecutable.hpp: dyld is allowed to have synthesized non-lazy pointers - ld64 is after processing bad GSYM stabs - * src/MachOReaderRelocatable.hpp: if a GSYM is found that does not match any data symbol, suppress it - -2006-03-23 Nick Kledzik - - * src/MachOWriterExecutable.hpp: in Writer::fixUpReferenceFinal() fix when x86::kPointer is for an - external relocation - -2006-03-23 Nick Kledzik - - * src/Options.cpp: change macosx-min-version to default to a per-architecture setting - add warning if -pagezero_size is not page aligned - * src/MachOWriterExecutable.hpp: properly handle external relocations for ppc64 with 4GB pagezero - * src/machochecker.cpp: sanity check relocation records - ------ Tagged ld64-48 - -2006-03-21 Nick Kledzik - - 64bit: passing function pointer to another function passes the wrong function address - * src/MachOReaderRelocatable.hpp: when processing a non-lazy pointer to a static function, don't accidentally - match it to a STAB symbol. - -2006-03-21 Nick Kledzik - - .eh symbols make up 13% of libstdc++'s stripped binary size - * src/ObjectFile.h: add ReaderOptions.fForFinalLinkedImage - * src/Options.cpp: setup ReaderOptions.fForFinalLinkedImage - * src/MachOReaderRelocatable.hpp: mark .eh symbols kSymbolTableNotIn when building final linked image - -2006-03-21 Nick Kledzik - - ld64 does not parse optional second argument to -filelist - * unit-tests/test-cases/filelist: added - * src/Options.cpp: in Options::loadFileList() handle comma option - - ------ Tagged ld64-47.1 - - ------ Tagged ld64-47 - - ------ Tagged ld64-46 - -2006-03-10 Nick Kledzik - - ld64 should figure out architecture from .o files - * unit-tests/test-cases/auto-arch: added - * src/ld.cpp: added Linker::inferArchitecture() to scan .o files are infer architecture to link - * src/MachOReaderArchive.hpp: enhanced validFile() to look deeper into archive and really valdate - * src/MachOWriterExecutable.hpp: stop using fOptions.architecture() - * src/Options.cpp: stop defaulting to ppc64 +----- Tagged ld64-84.3 -2006-03-09 Nick Kledzik - - Need "intentionally left blank" dylib stubs - * unit-tests/include/common.makefile: add VALID_ARCHS - * unit-tests/run-all-unit-tests: set up VALID_ARCHS - * unit-tests/test-cases/blank-stubs: add test case - * src/ld.cpp: in addDylib(), detect and ignore blank stubs - * src/MachOReaderDylib.hpp: in constructor, handle blank stubs - -2006-03-09 Nick Kledzik - - crash in stub with 2GB pagezero - * src/MachOWriterExecutable.hpp: StubAtom can't be no-pic if a large zero-page is used - -2006-03-06 Nick Kledzik - - * src/Options.cpp: addSectionAlignment, warn if -sectalign alignment is not a power of two - ------ Tagged ld64-45 - - -2006-03-06 Nick Kledzik - - LP64/9A122: ld64: hang when trying to link DiscRecording framework - * src/Options.cpp: addSectionAlignment, warn on zero. Use log2() for alignment conversion - - ------ Tagged ld64-44 - -2006-03-04 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: fix again test for detection of anonymous non-lazy-pointer. - Error out if .o file contains old __DWARFA style dwarf. - -2006-03-02 Nick Kledzik - - * src/ld.cpp: only re-map page aligned sub-parts of a fat file. A conformat mmap() requires alignment. - ------ Tagged ld64-43 - - -2006-03-02 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: tighten detection of anonymous non-lazy-pointer - ------ Tagged ld64-42 - -2006-02-28 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: fix x86 __IMPORT permissions for class Segment - -2006-02-28 Nick Kledzik - - SWB: ld64-37 (can't resolve symbol ___dso_handle) - * src/MachOWriterExecutable.hpp: add class DsoHandleAtom - -2006-02-28 Nick Kledzik - - * unit-tests/test-cases/literals-coalesce-alignment: added test case - * src/ld.cpp: when coalescing strings pick one with greater alignment - ld64: CG link failed because lo14 reference to anonymous non-lazy-pointer not aligned - * unit-tests/test-cases/relocs-c/test.c: tweak to fail like 4458660 - * src/MachOReaderRelocatable.hpp: detect anonymous non-lazy-pointer and transform into real non-lazy-pointers - ------ Tagged ld64-41 - -2006-02-24 Nick Kledzik - - * src/Options.cpp: Warning about -no_dead_strip_inits_and_terms and -i options. - Fix -weak-l option. - ------ Tagged ld64-40 - -2006-02-24 Nick Kledzik - - Leopard9A113: ppc64 libstdc++.dylib initializer crashes in pthread_once - * unit-tests/test-cases/multiple-entry-points: added - * src/MachOReaderRelocatable.hpp: make sure that if there are multiple symbols with the same - address, that we properly make zero length atoms for all but last symbol - -2006-02-24 Nick Kledzik - - * src/Options.cpp: ld64 doesn't realpath(3) B&I tracing paths - -2006-02-24 Nick Kledzik - - * src/Options.cpp: 9A110: ld64 can't deal with section names >16 chars - -2006-02-23 Nick Kledzik - - * src/MachOWriterExecutable.hpp: use vector.reserve() to minimize re-allocations - * src/Options.cpp: use vector.reserve() to minimize re-allocations - * src/MachOReaderRelocatable.hpp: use vector.reserve() to minimize re-allocations - * src/MachOReaderDylib.hpp: use vector.reserve() to minimize re-allocations - * src/ld.cpp: use vector.reserve() to minimize re-allocations - -2006-02-23 Nick Kledzik - - ld64 creates corrupt executables (and has malloc errors) with -headerpad option - * src/MachOWriterExecutable.hpp: Change LoadCommandsPaddingAtom::setSize() to update fLargestAtomSize - * unit-tests/test-cases/header-pad: added - -2006-02-23 Nick Kledzik - - ld64 creates invalid static executables - * src/MachOWriterExecutable.hpp: Change MachHeaderAtom::copyRawContent() to create correct header - for static executables. Change SymbolTableLoadCommandsAtom to skip LC_DYSYMTAB for static executables - * src/machochecker.cpp: Add tests that static executables are well formed - * unit-tests/test-cases/static-executable: added - -2006-02-22 Nick Kledzik - - * src/Options.cpp: chnage printf on unknown arg to a throw - ------ Tagged ld64-39 - -2006-02-20 Nick Kledzik - - * unit-tests/test-cases/read-only-relocs: added new test case - * src/MachOWriterExecutable.hpp: detect and error on relocs in read-only sections - * src/MachOReaderRelocatable.hpp: fix parsing of i386 absolute addressing relocs - -2006-02-20 Nick Kledzik - - * unit-tests/test-cases/stabs-coalesce: added new test case - * src/ld.cpp.hpp: in collectStabs removed unused stabs - ------ Tagged ld64-38 - -2006-02-17 Nick Kledzik - - * src/MachOWriterExecutable.hpp: set correct n_sect field of stabs - -2006-02-15 Nick Kledzik - - * src/MachOReaderArchive.hpp: with -all_load skip over both kinds of SYMDEFs - * unit-tests/test-cases/archive-basic/Makefile: add -all_load test case - ------ Tagged ld64-37 - -2006-02-13 Eric Christopher - - * src/MachOWriterExecutable.hpp (assignFileOffsets): Simplify. Add comments. - Adjust whitespace. - -2006-02-13 Nick Kledzik - - * src/MachOWriterExecutable.hpp: in Writer::fixUpReferenceRelocatable() fix kPCRel32 for external case - -2006-02-13 Nick Kledzik - - * unit-tests/test-cases/zero-fill: added - * src/machochecker.cpp: check that S_ZEROFILL have no file offset - * src/MachOWriterExecutable.hpp: rework assignFileOffsets() to fix rdar://problem/4441145 - -2006-02-12 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: fix use of first zero-length c-string in .o file - -2006-02-12 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: fix uninitialized fAlignment - -2006-02-12 Nick Kledzik - - * unit-tests/test-cases/relocs-asm/relocs-asm.s: add pointer-diff cases - * src/Architectures.hpp: make size explicit in ppc/ppc64 kPointerDiff - * src/MachOReaderRelocatable.hpp: don't allow kPointerDiff64 for ppc (just ppc64) - * src/MachOWriterExecutable.cpp: set proper r_length for ld -r of kPointerDiff - ------ Tagged ld64-36 - -2006-02-08 Nick Kledzik - - * src/MachOReaderRelocatable.cpp: rdar://problem/4438677 Handle when a .o file dwarf line info entries but no functions - -2006-02-08 Nick Kledzik - - * src/MachOWriterExecutable.cpp: Properly set address of first TEXT section - Keep S_COALESCED attribute for __eh_frame - -2006-02-08 Nick Kledzik - - * src/ld.cpp: Temporarily turn allowable client errors into warnings - * unit-tests/test-cases/allowable-clientMakefile: Temporarily let warnings be ok for above - * src/MachOWriterExecutable.hpp: fix ld -r to not use external relocations for symbols make static - -2006-02-08 Nick Kledzik - - * src/ld.cpp: A sibling in an umbrella can always link with its other siblings - * unit-tests/test-cases/allowable-client: add test case for above - -2006-02-08 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: support LOCAL non-lazy pointers to hidden symbols - * src/machochecker.cpp: verify indirect symbol table - * unit-tests/test-cases/private-non-lazy: added test case - -2006-02-07 Nick Kledzik - - * src/MachOWriterExecutable.hpp: fix calculation of file offsets in ld -r mode - * src/machochecker.cpp: verify segment file offsets are within file - ------ Tagged ld64-35 - -2006-02-06 Nick Kledzik - - * ld.cpp: allow parent of sub-framework to link - * unit-tests/test-cases/allowable-client/Makefile: added cases for parent and clients of parent - -2006-02-04 Nick Kledzik - - * unit-tests/test-cases/relocs-c/test.c: added some array cases - * src/MachOReaderRelocatable.hpp: factor out makeReferenceToEH() - * src/MachOWriterExecutable.hpp: add initial support for non-lazy pointer synthesis - ------ Tagged ld64-34 - -2006-02-04 Nick Kledzik - - * src/ld.cpp: fix -no_arch_warnings - fix -undefined warning - Do BINCL/EINCL optimization for gfull stabs - Implement "essential symbols" for stabs (-Sp) - Fix allowable clients to only test on direct libraries - * src/MachOReaderRelocatable.hpp: support BINCL/EINCL stabs - -2006-02-03 Nick Kledzik - - * src/machochecker.cpp: add code to check load command alignment - * src/MachOWriterExecutable.hpp: make load command alignment depend on architecture - -2006-02-03 Nick Kledzik - - * unit-tests/test-cases/literals-coalesce: added - * src/MachOReaderRelocatable.hpp: assure all targets of low14 ppc relocs are at least 4-byte alignmented - ------ Tagged ld64-33 - -2006-02-02 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: properly coalesce 8-byte literals - * src/MachOWriterExecutable.hpp: support ppc64::kPointerDiff32 - ------ Tagged ld64-32 - -2006-02-02 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: support anonymous zero fill atoms - -2006-02-02 Nick Kledzik - - * src/ld.cpp: A weak definition is good enough, do not search archives for a non-weak one - * unit-tests/test-cases/archive-weak: add test case for above - * src/MachOReaderRelocatable.hpp: an atom should never have a by-name reference to itself - * src/Options.cpp: prevent .eh symbols from being exported via a -exported_symbols_list - -2006-02-01 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: Support -macosx_version_min 10.5 - -2006-02-01 Nick Kledzik - - * src/MachOReaderRelocatable.hpp: don't try to parse debug_line dwarf if no symboled atoms - ------ Tagged ld64-31 +2008-04-09 Nick Kledzik + + -undefined dynamic_lookup busted + * src/ld.cpp: don't create proxy atom when scanning for dylib duplicates + * unit-tests/test-cases/tentative-and-archive: use -undefined dynamic_lookup -2006-02-01 Eric Christopher - * unit-tests/test-cases/allow-stack-execute/Makefile: Move otool handling... - * unit-tests/include/common.makefile: ... here. - * unit-tests/bin/fail-if-stdin.pl: New. - * unit-tests/test-cases/no-uuid: Ditto. - * src/ld.cpp (Linker::) Add fCreateUUID. - (::Linker): Initialize. - (::collectStabs): Use. Set if dwarf or we have a UUID already. - (::writeOutput): Pass as argument to Writer::write along with option. - * src/Options.h (Option::emitUUID): Declare. - (Option::fEmitUUID): Ditto. - * src/Options.cpp (Option::emitUUID): New. - (parse): Handle -no_uuid. - * src/MachOReaderRelocatable (Reader::Reader): Handle LC_UUID. - * src/ExecutableFile.h (Writer::Write): Add createUUID boolean. - * src/MachOWriterExecutable: Add UUID forward declaration. - (fUUIDAtom): New. - (UUIDLoadCommandAtom): Emit LC_UUID if fEmit. New function emit. Size - to zero at start. - (Writer::writer): Add handle for LC_UUID. If createUUID emit LC_UUID. - (MachHeaderAtom::copyRawContent): Don't count a load command if its size is - 0. - (UUIDLoadCommandAtom::copyRawContent): Depend on fEmit. +----- Tagged ld64-84.2 +2008-04-04 Nick Kledzik -2006-01-31 Nick Kledzik + * src/ld.cpp: don't add .eh symbols to symbol table in -r mode + * unit-tests/test-cases/eh-coalescing-r: update to test out of order coalescing + - * unit-tests/test-cases/dwarf-debug-notes : Added - * src/ld.cpp: don't generate debug note for .eh symbols - * src/MachOReaderRelocatable.hpp: make dwarf line info to atom matching faster and better +----- Tagged ld64-84.1 -2006-01-31 Nick Kledzik +2008-03-28 Nick Kledzik - * ld64.xcodeproj/project.pbxproj : Make buildable on Leopard - * src/MachOFileAbstraction.hpp: make buildable without latest cctools headers + ld should prefer architecture-specific variant over generic in fat object file + * src/Options.cpp: fully process -arch arguments into fArchitecture and fSubArchitecture + * src/ld.cpp: when -arch with a subtype is used, try to find the exact subtype from fat files + * unit-tests/test-cases/cpu-sub-types-preference: added test cases for arm and ppc + -2006-01-31 Nick Kledzik +----- Tagged ld64-84 - * src/MachOReaderRelocatable.hpp: better error message for bad relocs - * src/ObjectDump.cpp: add emacs tab settings - * src/SectCreate.h: ditto - * src/SectCreate.cpp: ditto - * src/machochecker.cpp: ditto - * src/ExecutableFile.h: ditto +2008-03-28 Nick Kledzik -2006-01-30 Eric Christopher + * src/LTOReader.hpp: don't print lto version, if lto is unavailable + - * src/ExecutableFile.h: Indent. +2008-03-26 Nick Kledzik -2006-01-30 Nick Kledzik + Add LD_WARN_COMMONS to BigBear builds + * src/Options.cpp: Add support for LD_WARN_FILE which copies all warnings to a side file + - * src/MachOReaderRelocatable.hpp: performance improvements - * src/ld.cpp: now that stubs are synthesized in write, don't need to special case anymore +2008-03-26 Nick Kledzik -2006-01-30 Nick Kledzik + Need encryption tag in mach-o file + linker should adjust arm final linked images so __text is never on the same page as the load commands + * src/MachOFileAbstraction.hpp: add support for encryption_info_command + * src/Options.cpp: add support for LD_NO_ENCRYPT and -no_encryption + * src/MachOWriterExecutable.hpp: add EncryptionLoadCommandsAtom + * src/machochecker.cpp: validate LC_ENCRYPTION_INFO + - * src/MachOReaderRelocatable.hpp: fix parsing of pcc relocs - * unit-tests/test-cases/relocs-asm/relocs-asm.s: add test case for above +2008-03-25 Nick Kledzik -2006-01-29 Nick Kledzik + ld64 does not recognize LLVM bitcode archive files + * src/MachOReaderArchive.hpp: renamed to src/ArchiveReader.hpp + * src/ArchiveReader.hpp: sniff each member and instantiate correct reader + * src/ld.cpp: rename mach_o::archive::Reader to archive::Reader + * ld64.xcodeproj/project.pbxproj: rename MachOReaderArchive.hpp to ArchiveReader.hpp + * unit-tests/test-cases/llvm-integration: added test case - * unit-tests/test-cases/weak_import: added test case - * src/ld.cpp: move code for weak_import mismatch to writer - * src/ObjectFile.h: remove ImportWeakness methods - * src/MachOReaderDylib.hpp: ditto - * src/SectCreate.cpp: ditto - * src/Architectures.hpp: add new ReferenceKinds for weak_imports - * src/MachOReaderRelocatable.hpp: implement new ReferenceKinds - * src/MachOWriterExecutable.hpp: handle new ReferenceKinds and weak_import mismatches -2006-01-29 Nick Kledzik +2008-03-25 Nick Kledzik - * src/Options.cpp: verify -allow_stack_execute is only used on main executables + ld64 should switch to new libLTO.dylib interface + Produce llvm bc file in 'ld -r' mode if all .o files are llvm bc + * src/LTOReader.hpp: rewrite from LLVMReader.hpp to use new lto_* C interface + * unit-tests/test-cases/llvm-integration: update and comment + * ld64.xcodeproj/project.pbxproj: update to lazy load libLTO.dylib + * src/ld.cpp: rework and simplify Linker::optimize() + * src/ObjectDump.cpp: Add -nm option + -2006-01-29 Nick Kledzik +2008-03-25 Nick Kledzik - * src/MachOReaderRelocatable.hpp: sync with latest dwarf reader from Geoff - * src/debugline.c: sync with latest dwarf reader from Geoff + * src/MachOReaderRelocatable.cpp: Fix some .objc_class_name_ off by one problem + * src/MachOWriterExecutable.cpp: Fix some .objc_class_name_ off by one problem -2006-01-27 Eric Christopher - * src/ld.cpp (Linker::syntesizeStabs): Correct spelling. Update all uses. +2008-03-24 Nick Kledzik -2006-01-27 Eric Christopher + Xcode 3.1 breaks linkage of libgcj.9.dylib from gcc 4.3.0 + * src/MachOWriterExecutable.cpp: Make sure all ivars in Writer are initialized. - * src/Options.h (Options): Add hasExecutableStack, fExecutableStack. - * src/Options.cpp (Options::hasExecutableStack): New. - (Options::parse): Parse -allow_stack_execute. - * src/MachOWriterExecutable.hpp (MachHeaderAtom::copyRawContent): - Implement MH_ALLOW_STACK_EXECUTION. - * unit-tests/include/common.makefile (FAIL_IF_EMPTY): New. - * unit-tests/bin/fail-if-no-stdin.pl: New file. - * unit-tests/test-cases/allow-stack-execute: New directory. -2006-01-27 Nick Kledzik +2008-03-21 Nick Kledzik - * src/MachOFileAbstraction.hpp: rely on latest system headers - * src/MachOWriterExecutable.hpp: fix ppc stubs. - wrote new relocationNeededInFinalLinkedImage() to replace common code + * src/Options.cpp: warn if -seg1addr value is not page aligned + -2006-01-27 Eric Christopher +2008-03-21 Nick Kledzik + + Move ARM support outside of __OPEN_SOURCE__ + * src/ld.cpp: remove __OPEN_SOURCE__ around arm support + * src/LLVMReader.hpp: remove __OPEN_SOURCE__ around arm support + * src/MachOReaderDylib.hpp: remove __OPEN_SOURCE__ around arm support + * src/ObjectFile.h: remove __OPEN_SOURCE__ around arm support + * src/MachOReaderRelocatable.hpp: remove __OPEN_SOURCE__ around arm support + * src/OpaqueSection.hpp: Cover arm support inside __OPEN_SOURCE__ macro check + * src/MachOWriterExecutable.hpp: remove __OPEN_SOURCE__ around arm support + * src/ObjectDump.cpp: remove __OPEN_SOURCE__ around arm support + * ld64.xcodeproj/project.pbxproj: remove ARM_SUPPORT from config.h + - * src/ld.cpp (logTraceInfo): New. - (Linker::addArchive): Use. - (Linker::addDylib): Ditto. - * src/ObjectFile (ReaderOptions::fTraceOutputFile): New. - * src/MachOReaderArchive.hpp (Reader::Reader): Move trace - logging to Linker::addArchive. - * src/Options.cpp (parsePreCommandLineEnvironment): Check - LD_PRINT_FILE if tracing dylibs or archives. +----- Tagged ld64-83.2 + +2008-03-15 Nick Kledzik + + ld64-83 removes OBJC_CLASS_$ symbols from projects, causes catastrophic results + * src/Options.cpp: restore "case CPU_TYPE_ARM" in switch statement for .objc_class symbols in .exp files + * unit-tests/test-cases/objc-exported_symbols_list: added test case + + +----- Tagged ld64-83.1 -2006-01-26 Nick Kledzik +2008-03-14 Nick Kledzik - * src/MachOWriterExecutable.hpp: handle NULL strings in SO debug notes + -iphone_version_min ==> -iphoneos_version_min + * src/Options.cpp: support -iphoneos_version_min as well + -2006-01-26 Nick Kledzik +----- Tagged ld64-83 - * src/MachOWriterExecutable.hpp: fix header padding calculation and thread state +2008-03-10 Nick Kledzik -2006-01-26 Nick Kledzik + ld needs to strip iphone_version_min option if invoking ld_classic + * src/Options.cpp: suppress -iphone_version_min from being passed to ld_classic + - Rewrite all stabs processing. - Move sythesize of debug notes into ld.cpp +2008-03-04 Nick Kledzik + + ADOBE XCODE: Linker option to lazy load frameworks (cause dyld is too slow) + * src/MachOWriterExecutable.hpp: create lazy stubs and LC_LAZY_LOAD_DYLIB for lazy load dylibs + * src/Options.cpp: support -lazy-l, -lazy_library, and -lazy_framework + * src/MachOFileAbstraction.hpp: add LC_LAZY_LOAD_DYLIB and S_LAZY_DYLIB_SYMBOL_POINTERS until in cctools + * src/MachOReaderDylib.hpp: add isLazyLoadedDylib() + * src/ld.cpp: pass lazy helper atom to writer + * doc/man/man1/ld.1: document new options + * unit-tests/test-cases/lazy-dylib-objc: add test case + * unit-tests/test-cases/lazy-dylib: add test case + -2006-01-26 Nick Kledzik +----- Tagged ld64-82.7 - * src/MachOWriterExecutable.hpp: fix ppc and ppc64 stub relocs +2008-03-07 Nick Kledzik -2006-01-25 Nick Kledzik + duplicate symbol literal-pointer@__OBJC@__message_refs@... + * src/MachOReaderRelocatable.hpp: AnonymousAtom from S_LITERAL_POINTERS section should be weak + * unit-tests/test-cases/objc-selector-coalescing: added test case - * ld64.xcodeproj/project.pbxproj: special case building in Curry + +----- Tagged ld64-82.6 -2006-01-25 Nick Kledzik +2008-03-04 Nick Kledzik - * src/MachOWriterExecutable.hpp: fix bugs in stub/lazy-pointer synthesis + ld crashes building XsanFS for Snow Leopard Builds + * src/ld.cpp: add bool dylibsOnly parameter to addJustInTimeAtoms() + * unit-tests/test-cases/tentative-and-archive: added test case + +2008-03-04 Nick Kledzik -2006-01-24 Eric Christopher + ld64 should not force building with gcc 4.0 + * ld64.xcodeproj/project.pbxproj: change rules to use "system" compiler instead of 4.0 + - * src/ld.cpp (Linker::createReaders): Change logging title to XBS. - (Linker::addDylib): Ditto. - * src/MachOReaderArchive.hpp (Reader::Reader): Ditto. - * src/Options.h (fPrintOptions): New. - * src/Options.cpp (Options::Options): Initialize above. - (Options::checkForFile): Change logging title to XBS. - (Options::findFramework): Ditto. - (Options::parse): Add log for options. - (Options::parsePreCommandLineEnvironmentSettings): Add LD_TRACE_ARCHIVES, - LD_TRACE_DYLIBS, and LD_PRINT_OPTIONS. +2008-02-29 Nick Kledzik -2006-01-24 Nick Kledzik + Simulator frameworks are being build split-seg and not prebound + * src/Options.cpp: only splitseg if prebound - * src/MachOReaderRelocatable.hpp: better C++ eh parsing -2006-01-23 Eric Christopher +2008-02-29 Nick Kledzik - * unit-tests/bin/fail-if-exit-zero.pl: New. - * unit-tests/include/common.makefile (FAIL_IF_SUCCESS): Use. - * unit-tests/allowable-client: New test. - * src/ld.cpp (Linker::addDylib): Check allowable clients before adding dylib. - * src/Options.h (allowableClients): New. - (clientName): Ditto. - (fAllowableClients): Ditto. - (fClientName): Ditto. - * src/Options.cpp: Implement above. - (parse): Handle -allowable_client and -client_name. - * src/MachOReaderDylib.hpp (getAllowableClients): New. - (fAllowableClients): Ditto. - (Reader): Process LC_SUB_CLIENT load command. - * src/ObjectFile.h (parentUmbrella): New. - (getAllowableClients): New. - * src/MachOWriterExecutable.hpp (AllowableClientLoadCommandsAtom): New. + Linker should not make GSYM debug note for .objc_category_* symbols + * src/ld.cpp: suppress GSYM debug notes for absolute symbols + * unit-tests/test-cases/objc-category-debug-notes: added test case -2006-01-23 Nick Kledzik - * unit-tests/test-cases/archive-basic: added - * src/ld.cpp: fix shadowed local variable - * src/FileAbstraction.hpp: ld64 shouldn't inline when building debug +2008-02-29 Nick Kledzik -2006-01-23 Nick Kledzik + non-ASCII CFString support is broken + * src/MachOReaderRelocatable.hpp: only name and coalesce cfstring constants if they use a __cstring + * unit-tests/test-cases/cfstring-utf16: add test case - * src/ld.cpp: fix symbol not found error message - * src/MachOReaderDylib.hpp: add logging to hash table - * src/MachOReaderRelocatable.hpp: enable stabs processing. Handle static functions with stubs - handle labeled cstrings. - * src/MachOWriterExecutable.hpp: properly suppress atoms not in symbol table. fix low14 error check. - add StubAtomHelper. - * unit-tests/test-cases/relocs-literals/test.c: add more interesting edge cases -2006-01-17 Nick Kledzik +2008-02-25 Nick Kledzik - * src/MachOReaderRelocatable.hpp: tweaks to synthesizing debug notes + ld -r -x + * doc/man/man1/ld.1: update man page to explain -r -x produces auto-stripped labels -2006-01-16 Nick Kledzik - * src/debugline.{sh}: added - * src/MachOReaderRelocatable.hpp: synthesize debug notes SOL from dwarf - * src/MachOWriterExecutable.hpp: fix lazy pointer section - * src/ObjectDump.hpp: Fix conditionalization - * unit-tests/test-cases/dwarf-strip: added +----- Tagged ld64-82.5 -2006-01-11 Nick Kledzik +2008-02-12 Nick Kledzik - * src/MachOReaderRelocatable.hpp: support Tiger crt1.o build with old ld64 - * src/ObjectDump.hpp: Support -arch option + x86_64: -stack_size failure when large __bss is used + * src/ld.cpp: only move section already in __DATA segment to new __huge section + * unit-tests/test-cases/stack_size_no_addr: updated test case to add large bss section + -2006-01-10 Nick Kledzik +----- Tagged ld64-82.4 - * src/MachOWriterExecutable.hpp: fix stubs for ppc64 - * src/MachOFileAbstraction.hpp: fix typo for macho_routines - * ld64.xcodeproj/project.pbxproj: add machochecker target - * src/machochecker.cpp: new skeleton for checking mach-o file bit - * unit-tests/: Add support for running machochecker +2008-02-06 Nick Kledzik + + comdat warnings with ld -r of C++ .o files + * unit-tests/test-cases/eh-coalescing-r: added test case + * src/ld.cpp: in ld -r mode don't warn about if .eh symbols are not static + -2006-01-10 Nick Kledzik +2008-02-06 Devang Patel - * src/MachOReaderRelocatable.hpp: warn if dwarf can't be parsed - * src/MachOReaderArchive.hpp: modTime for OSO stabs from archives is .a modTime + LTO of Bom framework with -dead_strip causes ld(1) crash + * src/LLVMReader.hpp: Check fAtom while determining LLVMReference target binding. + * unit-tests/test-cases/llvm-integration/Makefile: Add new test case. + * unit-tests/test-cases/llvm-integration/a15.c: New. + * unit-tests/test-cases/llvm-integration/b15.c: New. + * unit-tests/test-cases/llvm-integration/c15.c: New. + +2008-02-05 Nick Kledzik -2006-01-09 Nick Kledzik + * src/ld.cpp: fix for -arch ppc -mdynamic-no-pic -pie so PPC_RELOC_HA16 reloc is used + +----- Tagged ld64-82.3 + +2008-02-04 Nick Kledzik - * track modification time of .o files so that sythesized OSO stab will have it + ld doesn't seem to understand $ld$add$os... and $ld$hide$os... for 10.6 moves + * src/ObjectFile.h: add 10.6 + * src/Options.cpp: add 10.6 support + * src/MachOReaderDylib.hpp: recognize $os10.6$ + -2006-01-09 Nick Kledzik +----- Tagged ld64-82.2 - * src/MachOFileAbstraction.hpp: add macho_uuid_command - * src/MachOWriterExecutable.cpp: add UUID load command to generated files +2008-01-30 Devang Patel -2006-01-09 Nick Kledzik + Can't build 64-bit Intel binaries with LTO + ld64 fails to build with llvm-gcc-4.2 + * src/LLVMReader.hpp: Fix character count typo in strncmp call. + Use const char * to initialize temp. string. + * ld64.xcodeproj/project.pbxproj: use $(DEVELOPER_DIR) in header search construction + instead of hard coding /Developer. + +----- Tagged ld64-82.1 - * src/MachOReaderDylib.hpp: no longer keep dylib memory mapped - * src/ld.cpp: don't track dylib sizes because they are not longer memory mapped +2008-01-23 Nick Kledzik -2006-01-05 Nick Kledzik + * src/MachOReaderRelocatable.hpp: don't bus error if S_LITERAL_POINTERS is missing relocs + - * src/MachOReaderRelocatable.hpp: support new relocations +2008-01-22 Nick Kledzik -2006-01-05 Nick Kledzik + ld uses 32-bits in some places to hold addresses when parsing 64-bit mach-o files + * src/MachOReaderRelocatable.hpp: use AddrToAtomMap type that switch address to 64-bits for 64-bit archs + * src/MachOWriterExecutable.hpp: verify BR14 does not overflow for external relocs + * unit-tests/test-cases/relocs-c: update test case to slide addresses to verify x86_64 .o files - * src/MachOReaderDylib.hpp: support MH_DYLIB_STUB - * src/MachOReaderRelocatable.hpp: Add Geoff's comp unit extractor + +----- Tagged ld64-82 + +2008-01-18 Nick Kledzik -2006-01-05 Nick Kledzik + Bad grammar used in ld warning: cannot exported hidden symbol + * src/ld.cpp: fix typo in warning string + - refactor: transform Atom::dontStripName() to getSymbolTableInclusion() - * src/ld.cpp: pass dyld_stub_binding_helper to writer - * src/MachOReaderRelocatable.hpp: update synthesized stabs - Ignore stubs and lazy pointers in .o files - Support initializers and terminators - * src/MachOWriterExecutable.hpp: synthesize stubs and lazy pointers as needed - * ld64.xcodeproj/project.pbxproj: change Release target to build with dwarf +2008-01-16 Nick Kledzik -2006-01-03 Eric Christopher + Bundle Loader does not work anymore when loader is a bundle + ld warns of incorrect architecture when linking a bundle to a bundle + * src/MachOReaderDylib.hpp: support linking against bundles via -bundle_loader. Clean up error messages + * unit-tests/test-cases/bundle_loader: update test case + + +2008-01-16 Nick Kledzik + + ld -r -x creates debug notes (stabs) when it should not with -x (keep only global symbols) + * src/Options.cpp: in reconfigureDefaults() if -r and -x then -S + - * src/Options.h (multipleDefinitionsInDylibs): Declare. - (overridingDefinitionInDependentDylib): Ditto. - (warnOnMultipleDefinitionsInObjectFiles): Ditto. - (multiplyDefined): Remove. - (multiplyDefinedUnused): Ditto. - (fMultiplyDefined): Ditto. - (fWarnOnMultiplyDefined): New. - (fMultiplyDefinedDynamic): Ditto. - * src/Options.cpp (Options::Options): Initialize above. - (overridingDefinitionInDependentDylib): New. - (multipleDefinitionsInDylibs): Ditto. - (warnOnMultipleDefinitionsInObjectFiles): Ditto. - (parse): Update comments. Fix parsing of -y option. - Update error message for -dead_strip. Parse above - options. +2008-01-16 Nick Kledzik -2006-01-02 Nick Kledzik + if ld crashes while writing output file, it should delete the half written file + * src/MachOWriterExecutable.hpp: wrap open/write/close in try block and add signal handlers all to delete + output file on failure. + - * Refactor: move Atom::writeContent() to Writer +2008-01-16 Devang Patel -2005-12-23 Nick Kledzik + * src/LLVMReader.hpp: Use __gnu_cxx::hash_map instead of hash supported by LLVM. - * Reworked, simplify, and document test harness - * unit-tests/README: Added -2005-12-23 Nick Kledzik +2008-01-16 Nick Kledzik - * src/MachOReaderRelocatable.hpp: fixes for Objective-C - * unit-tests/test-cases/relocs-objc: Added + GC-supported library can't be linked into GC-required executable + * src/ld.cpp: loosen constraint that all objc code must be compiled with same GC settings and + allow gc-compatible code to be linked into anything. + * unit-tests/test-cases/objc-gc-checks: update test case -2005-12-22 Nick Kledzik - * src/MachOReaderRelocatable.hpp: fix check that next reloc is pair - * src/MachOReaderRelocatable.hpp: Add code to synthesize essential stabs from dwarf +2008-01-15 Nick Kledzik -2005-12-21 Nick Kledzik + no debug notes for custom named data + * src/ld.cpp: in synthesizeDebugNotes() check getSymbolTableInclusion() instead of for leading underscore + * unit-tests/test-cases/dwarf-debug-notes: update test case + +----- Tagged ld64-81.5 - * src/MachOReaderRelocatable.hpp: Fix parsing of literal sections - * src/MachOWriterExecutable.hpp: Fix writing of literal sections - * unit-tests/test-cases/relocs-literals: Added +2008-01-14 Devang Patel -2005-12-15 Eric Christopher + llvm-gcc-4.2 fails to build Sqlite 3.5.4 with -O4 + * src/LLVMReader.hpp: Resolve proxy references. Collect new unbounded references + after optimization. + * src/ld.cpp: Resolve additional unbounded references after optimization. + - * src/Options.h (enum Treatment): New. - (enum PICTreatment): Delete. - (enum VersionMin): New. - (prebind): Declare. - (macosxVersionMin): Ditto. - (multiplyDefined): Ditto. - (multiplyDefinedUnused): Ditto. - (setVersionMin): Ditto. - (setPICTreatment): Delete. - (setReadOnlyRelocTreatment): Ditto. - (picTreatment): Adjust return type. - (parseTreatment): New. - (fPrebind): Ditto. - (fVersionMin): Ditto. - (fPICTreatment): Change type. - (fMultiplyDefined): New. - (fMultiplyDefinedUnused): Ditto. - (fLimitUndefinedSymbols): Ditto. +2008-01-14 Nick Kledzik - * src/Options.cpp: Fix whitespace. Add comments on options. - (Options::Options): Add initializers for new variables. - (Options::prebind): New. - (Options::macosxVersionMin): Ditto. - (Options::parseTreatment): Ditto. - (Options::setVersionMin): Ditto. - (Options::setReadOnlyRelocTreatment): Delete. - (Options::setPICTreatment): Ditto. - (Options::Parse): Update for above. Add comments. + PPC Leopard (Xcode 3.0) linker ld gets "Bus error" sometimes + * src/MachOReaderRelocatable.hpp: use same code as x86 to parse ppc and arm sect-diff relocs + * src/MachOWriterExecutable.hpp: use same code as x86 to write ppc and arm sect-diff relocs + -2005-12-15 Nick Kledzik +2008-01-11 Nick Kledzik - * src/MachOReaderRelocatable.hpp: Add comments about dwarf + PPC Leopard (Xcode 3.0) linker ld reports "unknown scattered relocation type 4" + * src/MachOReaderRelocatable.hpp: add PPC_RELOC_HI16 to scattered reloc parsing + * unit-tests/test-cases/relocs-asm/relocs-asm.s: added tests for scattered hi/lo instructions + -2005-12-14 Nick Kledzik +2008-01-11 Nick Kledzik - * src/ELFFileAbstraction.hpp: Added - * src/ELFReaderRelocatable.hpp: Added - * Lot of fixes for new architecture - * Added __OPEN_SOURCE__ to "Preprocessor Macros" to disable new architecture support by default + * doc/man/man1/ld.1: add doc for -no_implicit_dylibs, -read_only_stubs, -slow_stubs, -interposable_list + + +2008-01-11 Nick Kledzik -2005-12-13 Nick Kledzik + ld64(1) man page uses ambiguous term "suffix" + * doc/man/man1/ld.1: make meaning of "suffix" more explicit + - * src/MachOReaderRelocatable.hpp: check for S_ATTR_DEBUG and ignore those sections - * unit-tests/test-cases/dwarf-ignore: added +2008-01-11 Nick Kledzik -2005-12-12 Nick Kledzik + Obj-C Symbols in Leopard Can't Be Weak Linked + * src/MachOWriterExecutable.hpp: set weak and lazy attributes on dummy .objc_class_name undefines + to dylibs to support Mac OS X 10.3.x dyld + - * Added test harness and three initial tests: - relocs-asm, relocs-c, and hello-world +2008-01-11 Nick Kledzik -2005-12-12 Nick Kledzik + Unknown error with linker (dyld: unknown external relocation type) + * src/ld.cpp: fix crash when SO stabs are not balanced + - * src/MachOReaderRelocatable.hpp: Massive refactoring: - Now there are three Atom classes, Chopping into Atoms - is done on label boundaries or by knowledge of special - sections, Share lots of ppc/ppc64 code. - Stabs process code is temporarily disabled. +2008-01-11 Devang Patel -2005-12-12 Nick Kledzik + LTO does not work if expected output is a dynamic library + * src/LLVMReader.hpp: Supply arguments describing output kind to optimizer. Communicate + visibility info. - * src/ObjectDump.cpp: Add command line options: -no_content, -stabs, -no_sort +2000-01-10 Nick Kledzik -2005-12-11 Eric Christopher + __cls_refs section is losing S_LITERAL_POINTERS section type + * src/MachOWriterExecutable.hpp: special case __cls_refs section + * unit-tests/test-cases/objc-literal-pointers: add test case - * src/Options.cpp: Reformat. - * src/Options.h: Ditto. -2005-12-07 Eric Christopher +2008-01-03 Nick Kledzik - * src/MachOReaderRelocatable.hpp (Atom::getAlignment): - When calculating alignment of an Atom, take into account - the alignment from which we pulled the Atom. + wrong EH information might be used + Created new kGroupSubordinate reference kind to model group comdat. The "signature" atom + has kGroupSubordinate references to the other atoms in the group. If the signature atom + is coalesced away, the linker follows kGroupSubordinate references and throws away the + other members of the group. + * unit-tests/test-cases/eh-coalescing: added test case + * src/ld.cpp: added markDead() and use propagate to subordinates + * src/Architectures.hpp: added kGroupSubordinate + * src/MachOReaderRelocatable.hpp: add kGroupSubordinate reference from a function to its .eh atom + and if used, from .eh atom to its LSDA atom. + * src/MachOWriterExecutable.hpp: handle kGroupSubordinate like kNoFixUp -2005-12-06 Nick Kledzik +----- Tagged ld64-81.4.1 - * src/Options.cpp src/Options.h: Add design comments +2007-12-19 Devang Patel -2005-12-05 Eric Christopher + * src/LLVMReader.hpp: Add LLVM_LTO_VERSION #ifdef check. + +2007-12-19 Devang Patel - * src/ld.cpp (Linker::createWriter): Uncomment ppc64 and - i386 linkers. + * src/LLVMReader.hpp: Add fOptimizer NULL check before calling printVersion(). + +2007-12-19 Devang Patel -2005-12-05 Eric Christopher + print LLVM LTO version number in verbose mode + * src/LLVMReader.hpp: Add printLLVMVersion() to print llvm version string in verbose mode. + * src/Options.cpp: Use printLLVMVersion() in verbose mode. - * ChangeLog: New file. +2007-12-19 Devang Patel -2005-12-02 Nick Kledzik + print LLVM LTO version number in verbose mode + * src/Options.h: Add verbose() method to check fVerbose flag. + * src/LLVMReader.hpp: Print LLVM version string in verbose mode. + +----- Tagged ld64-81.4 - * src/ObjectFile.h: Add design comments +2007-12-18 Devang Patel -2005-11-30 Nick Kledzik + * src/LLVMReader.hpp: Invalidate input architecture when optimizer is not available. - * Fix uses of __OPEN_SOURCE__ +----- Tagged ld64-81.3 -2005-11-28 Nick Kledzik +2007-12-17 Nick Kledzik - * Refactor Atom to use getDefinitionKind() + * ld64.xcodeproj/project.pbxproj: remove extraneous header search paths + -2005-11-21 Nick Kledzik +2007-12-17 Devang Patel - * src/MachOWriterExecutable.hpp: don't generate section for commons in -r mode + * src/LLVMReader.hpp: Do not throw exception if LLVMReader is not able to + dlopen LTO library. Instead just flag input file as an invalid LLVM bitcode file. -2005-11-18 Nick Kledzik - * x86 tweaks +2007-12-14 Nick Kledzik -2005-11-18 Nick Kledzik + gcc DejaGnu failure: gcc.dg/20020312-2.c (test for excess errors) (-fstack-protector-all) + * src/MachOWriterExecutable.hpp: fix Writer::generatesExternalTextReloc() to allow text relocs + * unit-tests/test-cases/read-only-relocs: updated test case to link a dynamic main executable compiled with -static - * src/ObjectDump.cpp: make work with command line arguments -2005-11-18 Nick Kledzik +2007-12-14 Devang Patel - * Massive rework to remove preprocessor conditionals and use templates + Enable Link Time Optimization in Opal + * src/LLVMReader.hpp: Locate LLVMlto.dylib relative to ld location in Developer folder. + * ld64.xcodeproj/project.pbxproj: Add {DEVELOPER_DIR}/usr/include in header search path. + * unit-tests/run-all-unit-tests: Set DYLD_FALLBACK_LIBRARY_PATH to find LLVMlto.dylib during unit testing. + * unit-tests/testcases/llvm-integration/Makefile: Point LLVMGCC and LLVMGXX to llvm-gcc-4.2 in Developer folder during unit testing. + + +2007-12-13 Nick Kledzik -2005-11-14 Nick Kledzik + SWB: failures due to ld: pointer in read-only segment not allowed in slidable image, used in ... + * src/MachOReaderRelocatable.hpp: in Reader::addRelocReference() handle weak pc-rel 32-bit vanilla relocs properly + +----- Tagged ld64-81.2 - * Created new Subversion repository for ld64 from cvs tag ld64-27.2