• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Link-Time Optimization Breaks Executable
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Link-Time Optimization Breaks Executable


  • Subject: Link-Time Optimization Breaks Executable
  • From: Andreas Grosam <email@hidden>
  • Date: Thu, 10 Nov 2011 11:41:45 +0100

I'm getting linker warnings when compiling a (static) library with Link-Time optimization enabled:

1) ld: warning: section __DATA/__objc_imageinfo has unexpectedly large size 48 in /tmp/lto.o

2) warning: (x86_64) /tmp/lto.o unable to open object file


Then, a category for NSData fails at runtime from within an executable that links again the static lib with exception "unrecognized selector sent to instance x" when, x receives the message defined in the category. (In this case,  NSData was actually NSConcreteData, anyway that doesn't matter, just for info)


With Link-Time Optimization disabled in the static library, the bug does not occur.

Building a dynamic lib will issue a similar linker warning, but also fails later with:
Assertion failed: (ref_die != NULL), function AppendDependants, file /SourceCache/dwarf_utilities/dwarf_utilities-87/source/DWARFDebugInfoEntry.cpp, line 407.
Command /Developer/usr/bin/dsymutil failed with exit code 6


Andreas _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: Protocols documentation missing required methods?
  • Next by Date: Re: Updating a mapping model in Xcode 4
  • Previous by thread: Re: Protocols documentation missing required methods?
  • Next by thread: __builtin_expect in clang?
  • Index(es):
    • Date
    • Thread