News for hackers. Stuff that matters.
Re:Announcing Rust 1.6 by hellofunk on Friday January 22, 2016 @07:04AM (#10952230)
I'm curious if what you mean is that C++11 has a standard spec for the memory model you describe, but if Linux doesn't use it, then Linux does not actually adhere to the C++11 standard? Does that mean that Linux C++11 compilers are non-standard in general?
Re:Announcing Rust 1.6 by haberman on Friday January 22, 2016 @02:30PM (#10955012)
Let me clarify first that when I say "Linux" in this post, I'm specifically referring to the Linux kernel, not user-space software that runs on Linux.

The Linux kernel is written in C, but uses lots of GCC-specific features and inline assembly to address things that aren't covered by the C standard. Among these, the Linux kernel has its own set of atomic types and memory barriers. It documents them here: https://www.kernel.org/doc/Documentation/memory-barriers.txt

So even if Linux is being compiled on a conforming C11 compiler (the Linux kernel is written in C, not C++), it uses its own atomic primitives instead of the ones provided by the language. Hope that helps.

Re:Announcing Rust 1.6 by Manishearth on Friday January 22, 2016 @09:14AM (#10952776)
I don't think there are any (modern) C++ compilers out there which follow the standard 100% and perfectly. ICBW.
Re:Announcing Rust 1.6 by hellofunk on Friday January 22, 2016 @10:01AM (#10953033)
Re:Announcing Rust 1.6 by Manishearth on Friday January 22, 2016 @12:36PM (#10954220)
That's a list of features. My point was that there are some slight variations induced by optimizations or otherwise which are against the spec.
Re:Announcing Rust 1.6 by hellofunk on Friday January 22, 2016 @01:47PM (#10954703)
I think you are confusing specification with implementation. The C++ standard does not outline how a compiler implements a feature, just how it should behave to match the standard. There are several compilers that 100% adhere to the full standard, including the guarantees specified by the standard in the form of memory and time complexity (optimization).
Re:Announcing Rust 1.6 by Manishearth on Friday January 22, 2016 @04:51PM (#10955824)
Oh, I know that specification != implementation, but IIRC both clang and GCC have certain behaviour which do not conform to the standard. But I can't find these right now, so I'll drop it here :)