[PATCH] D20677: Make it possible to build a -fno-exceptions libc++abi variant.

Asiri Rathnayake via cfe-commits cfe-commits at lists.llvm.org
Fri May 27 15:01:58 PDT 2016


rmaprath added a comment.



> I have a small concern about how difficult this would make things for us though - our toolchain setup uses `-ffunction-sections` and `-fdata-sections` along with linker's unused-section elimination to get rid of most of the stuff not necessary for the final image, but I can't remember if unused-section elimination happens before or after checking for missing symbols. If it is the latter, then we might be in trouble with this approach. I will have a look into this when I get back to work.


Come to think of it, I'm 90% sure it's the latter (I don't see how the former can work - the linker has to load all the objects while resolving all the dependencies, then only it can get rid of the stuff the final image doesn't really need). The linker will give up as soon as it hits a missing symbol referred from a section which is actually unused in the final image (but is within some object which contains sections that are actually needed for the image).

Of course I need to confirm that 10% when I get my hands on the linker, but I have a feeling this is going to be a blocker for us.


http://reviews.llvm.org/D20677





More information about the cfe-commits mailing list