DescriptionOilpan: Fix ASan instrumentation around heap object headers.
We poison the heap object headers because only our code should ever be
able to access them and only from a handful of methods. Poisoning the
headers lets us catch stray read/writes that end up in our headers and we
use the NO_SANITIZE_ADDRESS annotation on the handful of methods that
operate on the headers.
The ASan NO_SANITIZE_ADDRESS annotation does not propagate to acquireLoad.
Our first attempt to fix that was to unpoison the address accessed.
However, that does not work because we are using this code from multiple
threads without locking (which is the reason for using atomic ops).
Therefore, the threads will have races when it comes to poisoning.
This change fixes the issue by introducing asan aware
asanAcquireLoad/asanReleaseStore which will work on poisoned memory
when you know what you are doing.
Kostya, do you have any alternative suggestions?
R=erik.corry@gmail.com, kcc@chromium.org, oilpan-reviews@chromium.org, zerny@chromium.org
BUG=411712
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=181638
Patch Set 1 #
Total comments: 8
Patch Set 2 : Address review comments. #Patch Set 3 : Don't duplicate. #
Total comments: 2
Patch Set 4 : Address review comments. #
Total comments: 4
Patch Set 5 : Rename #
Messages
Total messages: 22 (4 generated)
|