mirror of
https://github.com/dart-lang/sdk
synced 2024-09-05 00:13:50 +00:00
389aab624d
This is a revert of b6bbfff8c0c6c44cdab0d7d78 which temporarily disabled this. Turns out that a non-TSAN gen_snapshot would - when emitting code via `Assembler::TsanLoadAcquire` - use an incorrect `Thread`-offset: It calculated the offset via `Thread::OffsetFromThread`. That function took a `dart::RuntimeEntry*` and tried to find its offset. We happen to have the following leaf runtime entries: #define LEAF_RUNTIME_ENTRY_LIST(V) ... V(void, MsanUnpoison, void*, size_t) V(void, MsanUnpoisonParam, size_t) V(void, TsanLoadAcquire, void*) V(void, TsanStoreRelease, void*) ... It loops over all runtime entries and finds the first one that has the identical `dart::RuntimeEntry::function_` pointer. Though all 4 of them are `nullptr` at `gen_snapshot` time, so when searching for offset for `Thread::OffsetFromThread(kTsanLoadAcquireRuntimeEntry)` it looked for the first runtime entry with `nullptr` function pointer - which turned out to be `MsanUnpoison` (instead of `TsanLoadAcquire`). => The obvious fix is to use the `dart::RuntimeEntry*` pointer for comparison instead of it's `function_` member. TEST=ci Issue b/287638965 Change-Id: I85c06674927978ef8561e9e7bdfab4823c0a8e1c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/312902 Commit-Queue: Martin Kustermann <kustermann@google.com> Reviewed-by: Slava Egorov <vegorov@google.com> |
||
---|---|---|
.. | ||
address_sanitizer.h | ||
allocation.cc | ||
allocation.h | ||
assert.cc | ||
assert.h | ||
atomic.h | ||
BUILD.gn | ||
elf.h | ||
floating_point.h | ||
floating_point_win.cc | ||
floating_point_win.h | ||
globals.h | ||
growable_array.h | ||
hashmap.cc | ||
hashmap.h | ||
leak_sanitizer.h | ||
mach_o.h | ||
memory_sanitizer.h | ||
pe.h | ||
platform_sources.gni | ||
priority_queue.h | ||
safe_stack.h | ||
signal_blocker.h | ||
splay-tree-inl.h | ||
splay-tree.h | ||
syslog.h | ||
syslog_android.cc | ||
syslog_fuchsia.cc | ||
syslog_linux.cc | ||
syslog_macos.cc | ||
syslog_win.cc | ||
text_buffer.cc | ||
text_buffer.h | ||
thread_sanitizer.h | ||
unaligned.h | ||
undefined_behavior_sanitizer.h | ||
unicode.cc | ||
unicode.h | ||
unwinding_records.cc | ||
unwinding_records.h | ||
unwinding_records_win.cc | ||
utils.cc | ||
utils.h | ||
utils_android.cc | ||
utils_android.h | ||
utils_fuchsia.cc | ||
utils_fuchsia.h | ||
utils_linux.cc | ||
utils_linux.h | ||
utils_macos.cc | ||
utils_macos.h | ||
utils_win.cc | ||
utils_win.h |