public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug lto/49612] New: LTO cannot link objects
@ 2011-07-02  5:30 krisztian.kocsis at optimaster dot eu
  2011-07-02 12:40 ` [Bug lto/49612] " rguenth at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: krisztian.kocsis at optimaster dot eu @ 2011-07-02  5:30 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49612

           Summary: LTO cannot link objects
           Product: gcc
           Version: 4.5.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: krisztian.kocsis@optimaster.eu


I made a toolchain for embedded Geode CPUs but if LTO is enabled (-flto) then
the compiler cannot link objects.

Piece of config.log from fuse:

configure:3352: checking whether the C compiler works
configure:3374:
/project/optinux/toolchains/geode-lx-r1/bin/i686-optinux-linux-gnu-gcc -pipe
--param l1-cache-line-size=32 --param l1-cache-size=64 --param
l2-cache-size=128 -march=i686 -mtune=geode -mmmx -m3dnow -g -O2 -fmodulo-sched
-fgcse-after-reload -ftree-loop-linear -fivopts -flto 
-D__optinux_target_geode_lx_r1__ -D__optinux_target__ -D__optinux__ -Wl,-O1
-Wl,-z,combreloc -Wl,-z,relro -Wl,-z,noexecstack -Wl,-z,noexecheap
-Wl,--enable-new-dtags -Wl,--gc-sections -Wl,--hash-style=both
../sysdeps/generic/initfini.c:86:1: error: '_init' has already been defined
../sysdeps/generic/initfini.c:86:1: note: previously defined here
../sysdeps/generic/initfini.c:63:1: error: 'dummy' has already been defined
../sysdeps/generic/initfini.c:63:1: note: previously defined here
../sysdeps/generic/initfini.c:112:1: error: '_fini' has already been defined
../sysdeps/generic/initfini.c:112:1: note: previously defined here
lto-wrapper:
/project/optinux/toolchains/geode-lx-r1/bin/i686-optinux-linux-gnu-gcc returned
1 exit status
lto-wrapper: deleting LTRANS file /tmp/ccoThRvh.lto.o: No such file or
directory
collect2: lto-wrapper returned 1 exit status
configure:3378: $? = 1
configure:3416: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "fuse"
| #define PACKAGE_TARNAME "fuse"
| #define PACKAGE_VERSION "2.8.5"
| #define PACKAGE_STRING "fuse 2.8.5"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define PACKAGE "fuse"
| #define VERSION "2.8.5"
| /* end confdefs.h.  */
|.
| int
| main ()
| {
|.
|   ;
|   return 0;
| }
configure:3421: error: in `/project/optinux/products/mpbr/.builds/fuse-2.8.5':
configure:3423: error: C compiler cannot create executables
See `config.log' for more details

If I remove '-flto' then everything works OK!

gmp-5.0.2
mpfr-3.0.1
ppl-0.10.2
cloog-ppl-0.15.11
mpc-0.9
libelf-0.8.13
linux-2.6.35 (headers)
binutils-2.21
gcc-4.5.3
eglibc-2.14


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug lto/49612] LTO cannot link objects
  2011-07-02  5:30 [Bug lto/49612] New: LTO cannot link objects krisztian.kocsis at optimaster dot eu
@ 2011-07-02 12:40 ` rguenth at gcc dot gnu.org
  2011-07-03  7:31 ` krisztian.kocsis at optimaster dot eu
  2012-05-07 12:38 ` rguenth at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-07-02 12:40 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49612

--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-07-02 12:40:38 UTC ---
please try GCC 4.6.x.  Are you sure you are using GCC 4.5.x?  You shouldn't
see this kind of output with -flto there.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug lto/49612] LTO cannot link objects
  2011-07-02  5:30 [Bug lto/49612] New: LTO cannot link objects krisztian.kocsis at optimaster dot eu
  2011-07-02 12:40 ` [Bug lto/49612] " rguenth at gcc dot gnu.org
@ 2011-07-03  7:31 ` krisztian.kocsis at optimaster dot eu
  2012-05-07 12:38 ` rguenth at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: krisztian.kocsis at optimaster dot eu @ 2011-07-03  7:31 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49612

--- Comment #2 from Krisztian Kocsis <krisztian.kocsis at optimaster dot eu> 2011-07-03 05:59:34 UTC ---
Ok, I'll try 4.6.1.

Yes, it's definitely 4.5.3:

krisztiankocsis@optimaster:/project/optinux/products/mpbr$
/project/optinux/toolchains/geode-lx-r1/bin/i686-optinux-linux-gnu-gcc
--version
i686-optinux-linux-gnu-gcc (crosstool-NG 20110624-optimaster - geode-lx-r1)
4.5.3
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug lto/49612] LTO cannot link objects
  2011-07-02  5:30 [Bug lto/49612] New: LTO cannot link objects krisztian.kocsis at optimaster dot eu
  2011-07-02 12:40 ` [Bug lto/49612] " rguenth at gcc dot gnu.org
  2011-07-03  7:31 ` krisztian.kocsis at optimaster dot eu
@ 2012-05-07 12:38 ` rguenth at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-05-07 12:38 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49612

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID

--- Comment #3 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-07 12:35:44 UTC ---
No response.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-05-07 12:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-02  5:30 [Bug lto/49612] New: LTO cannot link objects krisztian.kocsis at optimaster dot eu
2011-07-02 12:40 ` [Bug lto/49612] " rguenth at gcc dot gnu.org
2011-07-03  7:31 ` krisztian.kocsis at optimaster dot eu
2012-05-07 12:38 ` rguenth at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).