14b6f4931f
This commit fixes a potential deadlock that can occur between the memory hooks and region registation. This deadlock occurs because of a hold and wait error between two mutexes. The first mutex is the VMA lock used to protect internal rcache/grdma structures and the reader/writer lock in the interval tree. In the case of the memory hooks a reader lock is obtained on the interval tree then the VMA lock is obtained to remove the registration from the LRU. In the case of LRU evictions the VMA lock is obtained then the writer lock on the interval tree is obtained. This leads to the deadlock. To fix the issue the code that evicts from the LRU has been updated to only invalidate the registration while the VMA lock is held then remove the registration from the VMA after the lock is released. This should completely eliminate the above deadlock. Signed-off-by: Nathan Hjelm <hjelmn@google.com> |
||
---|---|---|
.. | ||
class | ||
datatype | ||
dss | ||
etc | ||
include | ||
mca | ||
memoryhooks | ||
runtime | ||
test/reachable | ||
threads | ||
tools | ||
util | ||
win32 | ||
common_sym_whitelist.txt | ||
Makefile.am | ||
win_makefile |