opportunistic cmpxchg on set insert
We now "guess" that the target slot we're inserting into is empty and perform a compare-exchange expecting this to be the case. This works out because, if it is not empty, we just performed the read we needed to anyway. It doesn't seem like this is much of a performance win, but it makes the code slightly more elegant so I've committed it anyway. Closes Github #31 "opportunistic cmpxchg"
parent
d2b19683
Please register or sign in to comment