Summary: | Linking libjvm.so with LTO fails with undefined references | ||
---|---|---|---|
Product: | binutils | Reporter: | Trevor Hemsley <trevor.hemsley> |
Component: | gold | Assignee: | Cary Coutant <ccoutant> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ccoutant, hjl.tools, hubicka |
Priority: | P2 | ||
Version: | 2.22 | ||
Target Milestone: | --- | ||
Host: | Target: | ||
Build: | Last reconfirmed: |
Description
Trevor Hemsley
2011-01-24 10:46:05 UTC
Can you try GNU ld on hjl/lto-mixed branch from http://git.kernel.org/?p=devel/binutils/hjl/x86.git;a=shortlog;h=refs/heads/hjl/lto-mixed That branch also helps reduce the undefined refs even further. I did notice that memory usage peaked at 6.4GB this time round but the trunk+patch version may have got to that too because it dropped back after a few minutes to 5.7GB. The undefined refs with binutils-hjl are now /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void G1ParPushHeapRSClosure::do_oop_nv<oopDesc*>(oopDesc**)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void FilterOutOfRegionClosure::do_oop_nv<oopDesc*>(oopDesc**)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void FilterAndMarkInHeapRegionAndIntoCSClosure::do_oop_nv<oopDesc*>(oopDesc**)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void FilterIntoCSClosure::do_oop_nv<oopDesc*>(oopDesc**)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void UpdateRSOopClosure::do_oop_work<oopDesc*>(oopDesc**)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void UpdateRSOopClosure::do_oop_work<unsigned int>(unsigned int*)' /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: undefined reference to `void G1ParScanClosure::do_oop_nv<oopDesc*>(oopDesc**)' (In reply to comment #2) > That branch also helps reduce the undefined refs even further. I did notice > that memory usage peaked at 6.4GB this time round but the trunk+patch version > may have got to that too because it dropped back after a few minutes to 5.7GB. > The undefined refs with binutils-hjl are now > > /sources/java/control/build/linux-amd64/hotspot/outputdir/linux_amd64_compiler2/product/libjvm.so: > undefined reference to `void > G1ParPushHeapRSClosure::do_oop_nv<oopDesc*>(oopDesc**)' ... You should try new gold Ian just updated. Do you get undefined symbols without -flto -fuse-linker-plugin at the final link? No undefined symbols without -flto -fuse-linker-plugin I've just transplanted this system onto a different one with 6GB RAM so I don't have to wait 12 hours for the link to complete! It's currently rerunning the build with a rebuilt version of your binutils and if this fails I will update to the latest and retry. The rerun with binutils-hjl failed with the same 7 undefs as before. I checked out the latest binutils trunk including the gold 1.11 version.cc and rebuilt and this reverts to failing with the 13 undefs as in the original report. You may run into http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47247 This report was filed against gold, but the error messages are from GNU ld, not gold. Which linker are you using? Should this be filed against ld rather than gold? I think that has been fixed for a while now, closing. |