public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/40178]  New: libstdc++ fails to detect atomic builtins for EABI ARM/Linux
@ 2009-05-17 17:08 mikpe at it dot uu dot se
  2009-05-17 17:12 ` [Bug libstdc++/40178] " paolo dot carlini at oracle dot com
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: mikpe at it dot uu dot se @ 2009-05-17 17:08 UTC (permalink / raw)
  To: gcc-bugs

EABI ARM/Linux supports atomic builtins in gcc, but they are implemented as
calls to libgcc helper procedures with names like __sync_fetch_and_add_4() etc
rather than being expanded inline.

libstdc++v3/acinclude.m4 tests for atomic builtins by compiling source files
with calls to __sync_fetch_and_add() etc, and then checking if the resulting
assembly files contain the string "__sync__". If they do then acinclude.m4
assumes that atomic builtins are not supported. This presumably works for archs
that inline expand the atomic builtins, but it gives false negatives on EABI
ARM/Linux.

Building gcc-4.4-20090512 for armv5tel-unknown-linux-gnueabi shows:

...
Configuring in armv5tel-unknown-linux-gnueabi/libstdc++-v3
...
checking for thread model used by GCC... posix
checking for atomic builtins for bool... no
checking for atomic builtins for short... no
checking for atomic builtins for int... no
checking for atomic builtins for long long... no
configure: WARNING: No native atomic operations are provided for this platform.
configure: WARNING: They will be faked using a mutex.
configure: WARNING: Performance of certain classes will degrade as a result.

hppa-linux-gnu implements atomic builtins similarly to EABI ARM/Linux, so it
may also be affected by this problem.


-- 
           Summary: libstdc++ fails to detect atomic builtins for EABI
                    ARM/Linux
           Product: gcc
           Version: 4.4.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: mikpe at it dot uu dot se
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: armv5tel-unknown-linux-gnueabi


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


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

* [Bug libstdc++/40178] libstdc++ fails to detect atomic builtins for EABI ARM/Linux
  2009-05-17 17:08 [Bug libstdc++/40178] New: libstdc++ fails to detect atomic builtins for EABI ARM/Linux mikpe at it dot uu dot se
@ 2009-05-17 17:12 ` paolo dot carlini at oracle dot com
  2009-05-17 18:01 ` mikpe at it dot uu dot se
  2009-05-17 18:42 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: paolo dot carlini at oracle dot com @ 2009-05-17 17:12 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from paolo dot carlini at oracle dot com  2009-05-17 17:12 -------
This is essentially the same as PR40133, which is blocked by PR40134.


-- 


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


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

* [Bug libstdc++/40178] libstdc++ fails to detect atomic builtins for EABI ARM/Linux
  2009-05-17 17:08 [Bug libstdc++/40178] New: libstdc++ fails to detect atomic builtins for EABI ARM/Linux mikpe at it dot uu dot se
  2009-05-17 17:12 ` [Bug libstdc++/40178] " paolo dot carlini at oracle dot com
@ 2009-05-17 18:01 ` mikpe at it dot uu dot se
  2009-05-17 18:42 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: mikpe at it dot uu dot se @ 2009-05-17 18:01 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from mikpe at it dot uu dot se  2009-05-17 18:01 -------
(In reply to comment #1)
> This is essentially the same as PR40133, which is blocked by PR40134.

Agreed. The underlying issue appears to be the static libgcc only symbols. One
wonders why they did things that way.


-- 


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


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

* [Bug libstdc++/40178] libstdc++ fails to detect atomic builtins for EABI ARM/Linux
  2009-05-17 17:08 [Bug libstdc++/40178] New: libstdc++ fails to detect atomic builtins for EABI ARM/Linux mikpe at it dot uu dot se
  2009-05-17 17:12 ` [Bug libstdc++/40178] " paolo dot carlini at oracle dot com
  2009-05-17 18:01 ` mikpe at it dot uu dot se
@ 2009-05-17 18:42 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-05-17 18:42 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2009-05-17 18:42 -------
Because it was accident ...

*** This bug has been marked as a duplicate of 40133 ***


-- 

pinskia at gcc dot gnu dot org changed:

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


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


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

end of thread, other threads:[~2009-05-17 18:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-17 17:08 [Bug libstdc++/40178] New: libstdc++ fails to detect atomic builtins for EABI ARM/Linux mikpe at it dot uu dot se
2009-05-17 17:12 ` [Bug libstdc++/40178] " paolo dot carlini at oracle dot com
2009-05-17 18:01 ` mikpe at it dot uu dot se
2009-05-17 18:42 ` pinskia 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).