Re: [Bug lto/47188] Undefined reference errors when combining IR and non-IR object files

2011-01-06 Thread Jan Hubicka
This is driver bug. With -flto-partition=none it for whatever reason forgets about -fresolution: ../lto1 -quiet -dumpdir ./ -dumpbase prog -mtune=generic -march=x86-64 -auxbase-strip /tmp/cctgIO6R.lto.o -version -flto-partition=none -fuse-linker-plugin -fwhole-program -fdump-ipa-all-details

Re: [Bug lto/47188] Undefined reference errors when combining IR and non-IR object files

2011-01-06 Thread Jan Hubicka
The problem is that collect2 should be in LTO_MODE_NONE when plugin is used but it confuses itself and sets itself into LTO_MODE_LTO. Consequently compilation is done twice, once correctly with plugin and then once again with collect2 path. I am testing the attached patch. It will also make