Marl: Suppress MemorySanitizer false-positive
Worker::current is a static thread_local which gets intialized to null,
which gets checked for in Scheduler::Fiber::current(). Unfortunately
MemorySanitizer does not observe the initialization when Marl is used
within a shared library, when the Linux dynamic loader is not
instrumented and its TLS initialization is not otherwise intercepted and
handled correctly.
This change decorates Scheduler::Fiber::current() with
__attribute__((no_sanitize_memory)) to suppress instrumenting it with
use-of-uninitialized-data checks.
Bug: chromium:1211047
Change-Id: I61b584922d9aba5d67991ce916c69102734f2b61
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/54610Reviewed-by:
Alexis Hétu <sugoi@google.com>
Kokoro-Result: kokoro <noreply+kokoro@google.com>
Tested-by:
Nicolas Capens <nicolascapens@google.com>
Showing
Please
register
or
sign in
to comment