Bug 114706 - libstdc++-devel contains a broken bits/atomicity.h on x86_64
Summary: libstdc++-devel contains a broken bits/atomicity.h on x86_64
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc   
(Show other bugs)
Version: 1
Hardware: x86_64 Linux
Target Milestone: ---
Assignee: Richard Henderson
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2004-02-01 00:26 UTC by Bryan O'Sullivan
Modified: 2007-11-30 22:10 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-10-06 01:07:28 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Bryan O'Sullivan 2004-02-01 00:26:00 UTC
Description of problem:

The atomic ops in bits/atomicity.h of libstdc++-devel on x86_64
include broken inline assembly like this:

xadd{l} {%0,%1|%1,%0}

This was also a problem on the RHEL 2.9.5 preview, but seems to have
been fixed in RHEL 3.

Version-Release number of selected component (if applicable):


How reproducible:

Any C++ code that uses atomicity.h fails to compile, for example
basic_string and the IO streams stuff.  In other words, anything that
uses STL will break.

Steps to Reproduce:
Actual results:

Expected results:

Additional info:

Comment 1 Jakub Jelinek 2004-02-16 14:26:42 UTC
Can you expand on why do you think this is broken assembly and what exactly
doesn't work?
It works for me just fine and there is nothing broken on it AFAICS.

Comment 2 Bryan O'Sullivan 2004-02-16 18:44:41 UTC
I had an easy test case to reproduce this, but I've mislaid it.  Argh.
 Keep this open a wee bit longer, and I'll dig it up.

Comment 3 Jaakko Hyvätti 2004-05-03 14:02:57 UTC
Compile this with -O1, gives you the asm errors:

g++ -O1 -c test.cc

#include <string>
using namespace std;
void f () {
  string s;
  s += "";

I tested this on Fedora Core 2 test3 x86_64

Comment 4 Richard Henderson 2004-10-06 01:07:28 UTC
Pushed upstream to

Note You need to log in before you can comment on or make changes to this bug.