To acquire the lease the thread is required to execute an expensive atomic instruction.
为了获得这份契约,线程必须执行一个代价昂贵的原子指令。
Note that the CMPXCHG instruction is atomic, which means that there is no intermediate visible state of the system before this instruction finishes.
注意,CMPXCHG指令是原子性的,这意味着在这个指令结束之前没有可见的中间状态。
应用推荐