From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27952 invoked by alias); 28 Jul 2011 14:18:02 -0000 Received: (qmail 27933 invoked by uid 22791); 28 Jul 2011 14:18:00 -0000 X-SWARE-Spam-Status: No, hits=-2.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,TW_GD X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 28 Jul 2011 14:17:46 +0000 From: "ro at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug debug/49887] New: [4.7 regression] .debug_macro breaks many Solaris/SPARC tests X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: debug X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ro at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Thu, 28 Jul 2011 14:18:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-07/txt/msg02462.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49887 Summary: [4.7 regression] .debug_macro breaks many Solaris/SPARC tests Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: debug AssignedTo: unassigned@gcc.gnu.org ReportedBy: ro@gcc.gnu.org CC: jakub@gcc.gnu.org Host: sparc-sun-solaris2.11 Target: sparc-sun-solaris2.11 Build: sparc-sun-solaris2.11 A recent Solaris 11/SPARC bootstrap with Sun as showed many testsuite regressions: a considerable number of them were gcc.dg/debug and g++.dg/debug tests at -gdwarf-2 -g3, but only with Sun as: FAIL: gcc.dg/debug/20020220-1.c -gdwarf-2 -g3 (test for excess errors) Excess errors: Undefined first referenced symbol in file wm4.0.a88b226d1d8abb1951fbf09c0af98055 /var/tmp//ccV4aG6a.o The failure vanishes with -save-temps, so I had to provide an unlink.so that just returns success to capture the output files. It turns out that in a regular compile, I've got this section in 20020220-1.s: .section ".debug_macro" .LLdebug_macro0: .uahalf 0x4 .byte 0x2 .uaword .LLdebug_line0 .byte 0x7 .uaword .LLdebug_macro1 .byte 0x3 .byte 0 .byte 0x1 .byte 0x4 .byte 0 .section ".debug_macro%wm4.0.a88b226d1d8abb1951fbf09c0af98055" .group wm4.0.a88b226d1d8abb1951fbf09c0af98055,".debug_macro%wm4.0.a88b226d1d8abb1951fbf09c0af98055",#comdat .LLdebug_macro1: but the group signature symbol isn't emitted, which leads to the undefined symbol: > elfdump -g 20020220-1.broken.o Group Section: .group%wm4.0.a88b226d1d8abb1951fbf09c0af98055 index flags / section signature symbol [0] [ COMDAT ] wm4.0.a88b226d1d8abb1951fbf09c0af98055 [1] .debug_macro%wm4.0.a88b226d1d8abb1951fbf09c0af98055 [10] $ nm 20020220-1.o 20020220-1.broken.o: [Index] Value Size Type Bind Other Shndx Name [4] | 0| 0|SECT |LOCL |0 |6 | [7] | 0| 0|SECT |LOCL |0 |2 | [8] | 0| 0|SECT |LOCL |0 |4 | [10] | 0| 0|SECT |LOCL |0 |12 | [11] | 0| 0|SECT |LOCL |0 |7 | [12] | 0| 0|SECT |LOCL |0 |3 | [2] | 0| 0|SECT |LOCL |0 |10 | [3] | 0| 0|SECT |LOCL |0 |9 | [9] | 0| 0|SECT |LOCL |0 |11 | [5] | 0| 0|SECT |LOCL |0 |5 | [6] | 0| 0|SECT |LOCL |0 |8 | [1] | 0| 0|FILE |LOCL |0 |ABS |20020220-1.c [13] | 16| 400|FUNC |GLOB |0 |2 |bar [14] | 0| 16|FUNC |GLOB |0 |2 |foo [15] | 416| 20|FUNC |GLOB |0 |2 |main [16] | 0| 0|NOTY |GLOB |0 |UNDEF |wm4.0.a88b226d1d8abb1951fbf09c0af98055 I still need to find out why this only happens on SPARC, but on x86 even with Sun as all is fine. Rainer