public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/467] New: Build fails on sparc when gcc supports comdat
@ 2004-10-22 18:19 mmazur at kernel dot pl
  2004-10-30 22:00 ` [Bug libc/467] " mmazur at kernel dot pl
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: mmazur at kernel dot pl @ 2004-10-22 18:19 UTC (permalink / raw)
  To: glibc-bugs

Repasting my mail from libc-alpha: 
 
This is what glibc does on sparc: 
 
#   define __make_section_unallocated(section_string)   \ 
        asm (".section " section_string "\n\t.previous"); 
 
__make_section_unallocated 
  (".gnu.linkonce.b.__sparc32_atomic_locks, \"aw\", %nobits"); 
 
volatile unsigned char __sparc32_atomic_locks[64] 
  __attribute__ ((nocommon, 
        section (".gnu.linkonce.b.__sparc32_atomic_locks" "\n\t#"), 
                  visibility ("hidden"))); 
 
On gcc without comdat this results with two .section entries: 
 
    .section .gnu.linkonce.b.__sparc32_atomic_locks, "aw", %nobits 
 
    .section    .gnu.linkonce.b.__sparc32_atomic_locks 
    #,"aw",@nobits 
 
As one can see, that's a smart move to define '%nobits' instead of  
'@nobits' (whatever that does :). 
 
On gccs with comdat support the same code results in: 
 
        .section .gnu.linkonce.b.__sparc32_atomic_locks, "aw", %nobits 
 
        .section        .bss,"awG",@nobits,.__sparc32_atomic_locks 
        #,comdat 
 
This results in (a) additional definition  
of .gnu.linkonce.b.__sparc32_atomic_locks section (which is empty and kind of  
useless) and (b) commenting out comdat definition which causes conflicts when  
linking (since that definition is supposed to replace .gnu.linkonce). 
 
A fix to just make it compile is simple - removal of "\n\t#". But what about  
that nobits hack? It's there for a reason (right? :) and it can't be  
'rehacked' in the same way since .section syntax changed.

-- 
           Summary: Build fails on sparc when gcc supports comdat
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
        AssignedTo: gotom at debian dot or dot jp
        ReportedBy: mmazur at kernel dot pl
                CC: glibc-bugs at sources dot redhat dot com


http://sources.redhat.com/bugzilla/show_bug.cgi?id=467

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

end of thread, other threads:[~2010-06-01  1:59 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-22 18:19 [Bug libc/467] New: Build fails on sparc when gcc supports comdat mmazur at kernel dot pl
2004-10-30 22:00 ` [Bug libc/467] " mmazur at kernel dot pl
2004-12-19 14:27 ` aj at suse dot de
2004-12-20 12:40 ` jakub at redhat dot com
2004-12-20 12:42 ` jakub at redhat dot com
2004-12-20 12:52 ` jakub at redhat dot com
2004-12-20 15:00 ` mmazur at kernel dot pl
2010-06-01  1:59 ` pasky at suse dot cz

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).