Techniques for detecting and preventing potential sources of
concurrency issues are disclosed. In response to an attempt to modify a shared
data structure, the
system generates a copy of the shared
data structure in a transaction area allocated for performing the modification through a
software memory transaction. The
system applies the modification to the copy of the shared
data structure, and the
system subsequently acquires a lock on the shared data structure. After acquiring the lock, the system checks for accesses to the shared data structure that would conflict with applying the modification to shared data structure. If the check does not reveal a conflicting access, the system commits the
software memory transaction by updating the shared data structure to match the state of the copy of the shared data structure. If the check does reveal a conflicting access, the system aborts the
software memory transaction.