ld crashes with assertion failure
| Originator: | ilya.konstantinov | ||
| Number: | rdar://23351659 | Date Originated: | |
| Status: | Resolved: | ||
| Product: | Product Version: | ||
| Classification: | Reproducible: |
Summary: Compile the provided crash-ld64.c file: clang -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.1.sdk-c -o crash-ld64.o crash-ld64.c and then link it: clang -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.1.sdk crash-ld64.o -o crash-ld64 Results in: 0 0x1048027e2 __assert_rtn + 144 1 0x104828fda mach_o::relocatable::Parser<arm>::parse(mach_o::relocatable::ParserOptions const&) + 3162 2 0x10480e15e mach_o::relocatable::Parser<arm>::parse(unsigned char const*, unsigned long long, char const*, long, ld::File::Ordinal, mach_o::relocatable::ParserOptions const&) + 388 3 0x10485355a ld::tool::InputFiles::makeFile(Options::FileInfo const&, bool) + 834 4 0x10485553f ld::tool::InputFiles::parseWorkerThread() + 483 5 0x7fff9916505a _pthread_body + 131 6 0x7fff99164fd7 _pthread_body + 0 A linker snapshot was created at: /tmp/crash-ld64-2015-10-02-002607.ld-snapshot ld: Assertion failed: (_file->_atomsArrayCount == computedAtomCount && "more atoms allocated than expected"), function parse, file /Library/Caches/com.apple.xbs/Sources/ld64_PONDEROSA/ld64-253.6/src/ld/parsers/macho_relocatable_file.cpp, line 1868. clang: error: linker command failed with exit code 1 (use -v to see invocation) Steps to Reproduce: Expected Results: Actual Results: Version: Xcode 7.1
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!