This is an archive of the discontinued LLVM Phabricator instance.

tsan: move shadow stack into ThreadState
ClosedPublic

Authored by dvyukov on Sep 26 2021, 11:07 PM.

Details

Summary

Currently the shadow stack is located in the trace memory mapping.
The new tsan runtime will remove the trace memory mapping.
Move the shadow stack into ThreadState as a preparation step.

Diff Detail

Event Timeline

dvyukov requested review of this revision.Sep 26 2021, 11:07 PM
dvyukov created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptSep 26 2021, 11:07 PM
Herald added a subscriber: Restricted Project. · View Herald Transcript
melver accepted this revision.Sep 27 2021, 3:20 AM
This revision is now accepted and ready to land.Sep 27 2021, 3:20 AM
This revision was landed with ongoing or failed builds.Sep 27 2021, 3:53 AM
This revision was automatically updated to reflect the committed changes.

In the failure logs I see:

92: ThreadSanitizer: CHECK failed: tsan_rtl.cpp:148 "((reinterpret_cast<uptr>(this) % 128)) == ((0))" (0x40, 0x0) (tid=90937)

So I think it's https://reviews.llvm.org/D110520 , I've sent https://reviews.llvm.org/D110629 that will hopefully fix the failures.
Thanks for reporting