dvyukov / relacy

Automatically exported from code.google.com/p/relacy
Other
208 stars 32 forks source link

Fix performance bug in thread_local_var #15

Closed strager closed 5 years ago

strager commented 5 years ago

thread_local_var has a poor performance if a thread_local_var object is created each test iteration. This poor performance is caused by some oversights:

Squash both of these bugs:

Unfortunately, this commit has one negative consequence: Win32-style Tls use-after-free is undetected in some cases.

dvyukov commented 5 years ago

Mkay, I don't really remember this code, but you seem to know what you are doing and the tests has passed :)