[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 Jeff Hammond changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |INVALID --- Comment #8 from Jeff Hammond --- My patch was w.r.t. the trunk as of earlier today, not 4.8 but that's fine. I just subscribed to various GCC lists to track these developments. I'll apply my patch locally so that I can use 4.8.1 and get the desired behavior.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #7 from joseph at codesourcery dot com --- __STDC_NO_THREADS__ is defined in glibc's stdc-predef.h because it describes combination compiler and library properties. The correct fix for atomics for 4.9 will be to implement them - see Andrew MacLeod's patches and recent discussion on gcc-patches - and the state of C11 in 4.8 is what it is and 4.8 is subject to normal release branch rules (regression and documentation fixes only, generally).
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 Jeff Hammond changed: What|Removed |Added CC||jeff.science at gmail dot com --- Comment #6 from Jeff Hammond --- Created attachment 30568 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30568&action=edit patch to define macros indicating missing C11 support If GCC defines __STDC_NO_ATOMICS__ and __STDC_NO_THREADS__, it is no longer non-compliant w.r.t. C11 to not provide stdatomic.h and threads.h. This would resolve bugs 53769 and 58016, albeit in a trivial way. I will not be surprised at all if this patch is rejected, if for no other reason than my institution has not signed a contributor agreement with FSF (they almost certainly will if I ask). My goal is to inspire someone else to do it properly since it seems trivial and arguably necessary.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #5 from Jeff Hammond --- Can someone tell me where the appropriate place to define __STDC_NO_ATOMICS__ and __STDC_NO_THREADS__ in GCC so I can submit a patch? I'd rather solve the problem and take 1-2 steps forward towards C11 compliance rather than debate the philosophical aspects of the problem.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #4 from joseph at codesourcery dot com --- __STDC_VERSION__ describes *intent* of command-line options (as regards differences between standard versions, to the extent that those are implemented). This is the same principle that has been documented for __STDC__ since at least GCC 2.0. "Sometimes people say that defining @code{__STDC__} in a compiler that does not completely conform to the ANSI C standard somehow violates the standard. This is illogical. The standard is a standard for compilers that are supposed to conform. It says nothing about what any other compilers should do. Whatever the ANSI C standard says is relevant to the design of plain @samp{gcc} without @samp{-ansi} only for pragmatic reasons, not as a requirement." (quoted from the GCC 2.0 manual). As a pragmatic matter, it's useful for users of standards modes that are incomplete to be able to tell which of those modes is in use, and __STDC_VERSION__ is the natural macro to define to distinguish between them. gcc -std=c11 is a compiler explicitly claimed not to conform.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #3 from Jonathan Wakely --- Noone disputes it's not conforming. The point is the support is incomplete. It's known to be incomplete. It's documented as incomplete. Reporting a bug to say it's incomplete doesn't serve any useful purpose, it will be complete when it's completed.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #2 from Jeff Hammond --- If GCC doesn't support C11, it should not claim to support C11 via __STDC_VERSION__. The C11 standard definition isn't a recommendation from which implementers can pick and choose based upon their priorities. Documentation an implementations failure to comply with a standard does not absolve an implementation from lying about its features with ISO standard macros. The macro is part of the standard; the documentation is not. In any case, there is an absolutely trivial way for GCC to satisfy the C11 standard with respect to stdatomic.h, and it involves __STDC_NO_ATOMICS__. The failure to define this macro or to provide stdatomic.h make GCC non-compliant with C11, in which case __STDC_VERSION__ is defined improperly.
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 --- Comment #1 from joseph at codesourcery dot com --- I don't know whether Andrew intends stdatomic.h to go in GCC or glibc, but in any case I consider this a duplicate of bug 53769, which in turn I don't really consider a useful bug report at all (incompleteness of the implementation of an option documented in the manual as incomplete should not be considered a bug).
[Bug c/58016] stdatomic.h missing in 4.8.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58016 Paolo Carlini changed: What|Removed |Added Severity|blocker |normal