 By doing this, it makes it possible to reason about code execution in a multithreaded environment, even in the face of optimizations performed by the dynamic compiler, the processor(s) and the caches.For execution of a single thread, the rules are simple.The Java Language Specification requires a Java Virtual Machine to observe "within-thread as-if-serial" semantics.