The macro atomic-exchange
exchanges the value in place with new-value, returning the old-value. The operation is guaranteed to be atomic.
place must be one of the places described in Low level atomic operations, or expand to one of them.
LispWorks User Guide and Reference Manual - 20 Sep 2017