From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8764 invoked by alias); 18 Jun 2009 00:33:16 -0000 Received: (qmail 8648 invoked by uid 48); 18 Jun 2009 00:33:03 -0000 Date: Thu, 18 Jun 2009 00:33:00 -0000 Message-ID: <20090618003303.8647.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug libstdc++/40297] [C++0x] debug mode vs atomics In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "bkoz at gcc dot gnu dot org" 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: 2009-06/txt/msg01254.txt.bz2 ------- Comment #3 from bkoz at gcc dot gnu dot org 2009-06-18 00:33 ------- Jonathan, you are right. These assertions are all backwards. I see this hitting the following members: load store compare_exchange_strong I should have done tests for this, obviously. Ouch. Now you've done this for me, so yes proceed please. I'm still not sure that this kind of debug mode only error handling is correct but it seems like an approach that is vaguely familiar from other parts of the library. So at least usage is consistent, even if the original implementation was plain wrong.... There are many problems with memory ordering in the atomics2 implementation. It is known to be incorrect and incomplete, as the saying goes. The goal was to start experimenting with compliler builtins assuming x86_64 hardware and see how far we got, what kind of compiler intrinsics we needed first, how we test this stuff, etc etc. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40297