commit | 9626d66019599de925b9ad1f216388d1c890d193 | [log] [tgz] |
---|---|---|
author | Paul Pluzhnikov <ppluzhnikov@google.com> | Tue Nov 24 15:18:48 2009 -0800 |
committer | Arun Sharma <arun@sharma-home.net> | Tue Nov 24 15:18:48 2009 -0800 |
tree | a081f3056ef0f89f0e09b42b5e76b2f8ff186468 | |
parent | 890a630d76ca4af8cb9758e3c74d00897dbcb544 [diff] |
Fix a race condition in dwarf unwinding. Original code was accessing rs_cache memory without holding a lock in some cases. If there was sufficient cache pressure, entry being accessed may be overwritten by another thread, resulting in a data race. We now make a thread local copy of the data, before releasing the lock. If we end up supporting UNW_CACHE_PER_THREAD properly in the future, this memcpy should be unnecessary.