4 ms·
Sequentially consistent: the program behaves as if it executed sequentially for some interlacing of the instructions (across threads). Happens-before consisten
by pron 11y ago
Sequentially consistent: the program behaves as if it executed sequentially for some interlacing of the instructions (across threads).
Happens-before consistent: the program behaves according to the happens-before rules of the JMM. Sequential consistency may be violated if two threads modify unsynchronized or non-volatile fields.
- fmstephe 11y agoThanks, I feel like I am being a bit thick here. Would it be fair to say that happens-before consistent is a property of every java program. And sequentially consistent is a property of every java program without data-races? (ignoring unsafe/jni etc.)?
- pron 11y agoYes, as I understand it.