public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug lto/41079]  New: Bootstrap comparison fails, executables contain .gnu.lto_* sections
@ 2009-08-15 15:58 rguenth at gcc dot gnu dot org
  2009-08-16 12:48 ` [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives rguenth at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-15 15:58 UTC (permalink / raw)
  To: gcc-bugs

Likely because .gnu.lto_* sections remain in the final executables (like for
example cc1-dummy) bootstrap with BOOT_CFLAGS="-O2 -flto -g"
BOOT_LDFLAGS="-flto"
currently fails at comparing stage2 and stage3.

Comparing stage2 and stage3 cc1-dummy readelf -S output reveals:

--- a   2009-08-15 17:25:19.000000000 +0200
+++ b   2009-08-15 17:25:22.000000000 +0200
@@ -1,4 +1,4 @@
-There are 13739 section headers, starting at offset 0x67e1b6c:
+There are 13739 section headers, starting at offset 0x67e3424:

 Section Headers:
   [Nr] Name              Type            Addr     Off    Size   ES Flg Lk Inf
Al
@@ -29,13718 +29,13718 @@
   [24] .bss              NOBITS          08b090c0 ac00c0 06f6b8 00  WA  0   0
32
   [25] .gnu.lto_.referen PROGBITS        00000000 ac00c0 0019c6 00      0   0 
4
   [26] .gnu.lto_.purecon PROGBITS        00000000 ac1a88 008daa 00      0   0 
4
-  [27] .gnu.lto_init_adj PROGBITS        00000000 aca834 0005db 00      0   0 
4
+  [27] .gnu.lto_init_adj PROGBITS        00000000 aca834 0005d9 00      0   0 
4
   [28] .gnu.lto_.cgraph  PROGBITS        00000000 acae10 0eaea1 00      0   0 
4
   [29] .gnu.lto_.statics PROGBITS        00000000 bb5cb4 002a22 00      0   0 
4
-  [30] .gnu.lto_.decls   PROGBITS        00000000 bb86d8 1ecd2ce 00      0   0
 4
(further all is different due to offset and size mismatches)

The offset difference of the section headers is odd as well.

Program headers are the same.


-- 
           Summary: Bootstrap comparison fails, executables contain
                    .gnu.lto_* sections
           Product: gcc
           Version: lto
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at gcc dot gnu dot org


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
@ 2009-08-16 12:48 ` rguenth at gcc dot gnu dot org
  2009-08-16 17:13 ` rguenth at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-16 12:48 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from rguenth at gcc dot gnu dot org  2009-08-16 12:47 -------
The lto sections are because we link with the static libraries even if they
contain lto sections.  As the linker doesn't know about them they are not
stripped either.  I guess a linker script could help here ... or archive
support for lto.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dnovillo at gcc dot gnu dot
                   |                            |org
            Summary|Bootstrap comparison fails, |Bootstrap comparison fails,
                   |executables contain         |collect2 links against lto
                   |.gnu.lto_* sections         |archives


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
  2009-08-16 12:48 ` [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives rguenth at gcc dot gnu dot org
@ 2009-08-16 17:13 ` rguenth at gcc dot gnu dot org
  2009-08-16 18:42 ` rguenth at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-16 17:13 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from rguenth at gcc dot gnu dot org  2009-08-16 17:13 -------
Like forcing -Wl,-Tltoscript if using GNU ld with ltoscript being

SECTIONS { /DISCARD/ : { *(.gnu.lto_*) } }
INSERT BEFORE .text

placing this in the std GCC private library path should be enough together
with adjusting the default specs.


-- 


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
  2009-08-16 12:48 ` [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives rguenth at gcc dot gnu dot org
  2009-08-16 17:13 ` rguenth at gcc dot gnu dot org
@ 2009-08-16 18:42 ` rguenth at gcc dot gnu dot org
  2009-08-17 16:14 ` rguenth at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-16 18:42 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from rguenth at gcc dot gnu dot org  2009-08-16 18:42 -------
With that added to BOOT_LDFLAGS the cc1 binaries compare ok (the comparison
still fails as it only considers .o files which obviously differ).


-- 


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2009-08-16 18:42 ` rguenth at gcc dot gnu dot org
@ 2009-08-17 16:14 ` rguenth at gcc dot gnu dot org
  2009-08-19  6:15 ` bje at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-17 16:14 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from rguenth at gcc dot gnu dot org  2009-08-17 16:13 -------
on x86_64-*-* the bootstrap comparison succeeds, even with lto sections in
the executables and .o files.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 GCC target triplet|                            |i?86-*-*


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2009-08-17 16:14 ` rguenth at gcc dot gnu dot org
@ 2009-08-19  6:15 ` bje at gcc dot gnu dot org
  2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
  2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: bje at gcc dot gnu dot org @ 2009-08-19  6:15 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from bje at gcc dot gnu dot org  2009-08-19 06:14 -------
Confirmed.


-- 

bje at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2009-08-19 06:14:55
               date|                            |


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2009-08-19  6:15 ` bje at gcc dot gnu dot org
@ 2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
  2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-24 15:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from rguenth at gcc dot gnu dot org  2009-08-24 15:34 -------
The bootstrap comparison issues have all been fixed.  The lto sections
appearing in the final executables have been dealt with in upstream ld
following what gold does.

Thus, fixed.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
 GCC target triplet|i?86-*-*                    |
         Resolution|                            |FIXED


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


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

* [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives
  2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
@ 2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-08-24 15:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from rguenth at gcc dot gnu dot org  2009-08-24 15:33 -------
Subject: Bug 41079

Author: rguenth
Date: Mon Aug 24 15:33:35 2009
New Revision: 151057

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=151057
Log:
2009-08-24  Richard Guenther  <rguenther@suse.de>

        PR lto/41079
        * lto-streamer-out.c (output_gimple_stmt): Only stream needed
        fields.  Do not stream pointer garbage.
        * lto-streamer-in.c (output_gimple_stmt): Adjust accordingly.
        Structure like output_gimple_stmt.  Do not needlessly zero
        fields.

Modified:
    branches/lto/gcc/ChangeLog.lto
    branches/lto/gcc/lto-streamer-in.c
    branches/lto/gcc/lto-streamer-out.c


-- 


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


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

end of thread, other threads:[~2009-08-24 15:34 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-15 15:58 [Bug lto/41079] New: Bootstrap comparison fails, executables contain .gnu.lto_* sections rguenth at gcc dot gnu dot org
2009-08-16 12:48 ` [Bug lto/41079] Bootstrap comparison fails, collect2 links against lto archives rguenth at gcc dot gnu dot org
2009-08-16 17:13 ` rguenth at gcc dot gnu dot org
2009-08-16 18:42 ` rguenth at gcc dot gnu dot org
2009-08-17 16:14 ` rguenth at gcc dot gnu dot org
2009-08-19  6:15 ` bje at gcc dot gnu dot org
2009-08-24 15:34 ` rguenth at gcc dot gnu dot org
2009-08-24 15:34 ` rguenth at gcc dot gnu dot 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).