Singleton - multithreading Safety Act

Multi-threaded, there will be instruction reordering problems, resulting in new target when the step is inconsistent with volatile modifications can.

 

 

 

Guess you like

Origin www.cnblogs.com/GotoJava/p/12584544.html