[PATCH] Entry point function should never be dead-stripped.
Shankar Kalpathi Easwaran
shankarke at gmail.com
Tue Aug 13 10:06:34 PDT 2013
The entry symbol should have the same effect as a undefined symbol. For example :-
$ ld --entry=strcpy /usr/lib/libc.a -t
ld: mode elf_x86_64
(/usr/lib/libc.a)strcpy.o
(/usr/lib/libc.a)init-arch.o
It should be added to the resolver like how undefined symbols are added.
On a side note, I think all the symbols that are specified in the command line should be part of the deadStripRoot set, that they should not be removed.
http://llvm-reviews.chandlerc.com/D1366
More information about the llvm-commits
mailing list