llvm-ld question

Hi
   If I am linking a large library with my app, is there a way I can
eliminate all the unused functions used in the library as part of the
linking ?

thanks
shrey

shreyas krishnan wrote:

Hi
   If I am linking a large library with my app, is there a way I can
eliminate all the unused functions used in the library as part of the
linking ?
  
If you are talking about static libraries (.a), this is done automatically by linker.
You shouldn't have to worry about this.
If you are talking about the shared library (.so) -- it will be loaded into memory unchanged. Not much you can do to reduce it's size.

Yuri

Hi
   I found this question in the archives and i would like to clarify
this a bit. So in the llvm-ld, do unnecessary functions not get added
while linking itself or is it that they get subsequently dropped with
the help of optimizations. If it is the later, is it a feasible idea
to have a fast linker that does not even add functions while linking
itself ? If so, any examples of one in llvm world or otherwise?

thanks
Sumesh