CppMem: Formalised Interactive C/C++ memory model
svr-pes20-cppmem.cl.cam.ac.uk
svr-pes20-cppmem.cl.cam.ac.uk
Memory management normally conotes the process for allocation and reclamation of memory in a program.
A memory model defines where reads can get their information from in a program. In most contexts that is informally "the most recent write" in terms of wall clock time (i.e. sequential consistency).
In C++, C and Java, this is not necessarily how things are. For example in Java writes can be buffered preventing reads in other threads from seeing them right away. This means those reads will get a value from an "older" write (again wall clock time).
It's all really bad for reasoning about your program :(
True, but it's really good for performance in a lot of incredibly common cases, which is why it's a case of a tough tradeoff they had to make - rather than a malicious choice to just make our lives more difficult. :)
(An expert in this stuff would probably also wave their hands and say something about exotic and/or legacy hardware that those languages need and/or want to support.)
[0]: http://preshing.com/20121019/this-is-why-they-call-it-a-weak...
EDIT: found doc. Still it would be great if the legends is nearby.