[PATCH] Entry point function should never be dead-stripped.

Rui Ueyama ruiu at google.com
Mon Aug 26 17:29:05 PDT 2013



================
Comment at: include/lld/Core/LinkingContext.h:229
@@ -221,2 +228,3 @@
     _initialUndefinedSymbols.push_back(symbolName);
+    _deadStripRoots.push_back(symbolName);
   }
----------------
Shankar Kalpathi Easwaran wrote:
> Can we add a seperate function to targetInfo to add symbol to deadStripRoot set so that a list of symbols can be added to the deadStripRoot set.
> 
> I also think that we want to add to the deadStripRoot set only if the linker flag deadstrip is enabled.
setDeadStripping(true) can be called after adding an entry symbol name, in which case deadstrip is not enabled at the time when the symbol is added. How would you handle that?


http://llvm-reviews.chandlerc.com/D1524



More information about the llvm-commits mailing list