No, getter will not cause field synchronization.
when it comes to reading and writing a primitive in a multi-threaded environment, we have three problems caused by the processor
- : , , 64- 32- . .
- : , , , . , .
- : , .
Getter . , JIT . ?
Volatile - . . , , . , , .
, , . : " , flag, ?" , , . , , , ( ) , . , . JIT ", ". .
: , ( ), , , ?
. JVM, . . , , , ? ?