This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug lto/61052] g++ generated code segfaults when using LTO together with "extern template", non-LTO compiled files, and gold linker
- From: "i.palachev at samsung dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 20 Oct 2014 11:30:08 +0000
- Subject: [Bug lto/61052] g++ generated code segfaults when using LTO together with "extern template", non-LTO compiled files, and gold linker
- Auto-submitted: auto-generated
- References: <bug-61052-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61052
Ilya Palachev <i.palachev at samsung dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |i.palachev at samsung dot com
--- Comment #1 from Ilya Palachev <i.palachev at samsung dot com> ---
Hi,
I can see another error for the attached testcase.
$ gcc -c -O2 -flto a.cc
$ gcc -c -O2 -flto b.cc
$ gcc -c -Os e.cc
$ gcc -o a -fuse-ld=gold a.o e.o b.o
/usr/local/bin/ld.gold: -plugin: unknown option
/usr/local/bin/ld.gold: use the --help option for usage information
collect2: error: ld returned 1 exit status
$ ld -v
GNU gold (GNU Binutils 2.24.51.20141003) 1.11
It seems that this error os related with option "-fuse-ld", since the error
disappears if this option is not specified.