Sorry, I post this message on this mailing list since I couldn't find the
one for common users. As a LLVM newcomer, I don't know how to do the link
time optimization correctly after building the gcc frontend and LLVM itself.
I followed the example in http://llvm.org/docs/LinkTimeOptimization.html but
at the final step I got the following error:
[XXXX at XXX example]$ llvm-gcc a.o main.o -o main
ld warning: in a.o, file is not of required architecture
Undefined symbols:
"_foo1", referenced from:
_main in main.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
It looks like llvm-gcc called the non-llvm linker that didn't recognize the
a.o in bitcode. I'm using OS X Leapard, llvm-2.7, and llvm-gcc-4.2-2.7.
Thanks.
Xiaoming
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20100725/1de4b3de/attachment.html>