I am looking for a link to the differences between the memory models used by the .NET CLR / JIT on x86 / x64 / ia64. I know some differences between x86 and ia64 (reordering commands, deleting commands, etc.), but I did not find a link to the differences between x86 and x64.
I have an application that targets some very tight wait numbers and will only work on x86 at this time and possibly on x64 (definitely not on ia64). I am wondering if I can rely on some artifacts of the XIT JIT implementation and still be relatively safe on x64, or if I have to program on the looser ia64 JIT (which will require more fields that are volatile and memory barriers will be inserted into several places).
Thanks in advance for any pointers.
Two articles on the .NET memory model (which is stronger than the ECMA model, by the way):
Joe Duffy's book, Parallel Programming on Windows , is also a great source of information on this topic.
The .NET memory model is specified in the ECMA ISO / IEC-23271 specification. In particular, in section I: Concepts and architecture, chapter 12.6 “Memory model and optimization”.
, JIT. , - JIT x86/x64.
x64 - x86, , (SSE2), , x64. , ( ). x86 JIT x64.
, , 64- AMD CMPXCHG16B (), .
++, , , , , .
, CLR, Microsoft ( , , 2003). , x64 , x86, , CLR.
Itanium, , , , . , , . , .
, x64 JIT x86 JIT ( 3.5 SP1), Release . .