This is an archive of the discontinued LLVM Phabricator instance.

tsan: improve detection of stack/tls races
ClosedPublic

Authored by dvyukov on Oct 5 2021, 6:31 AM.

Details

Summary

Print meaningful stack frames for stack/tls races
(instead of PC 1/2 that don't symbolize).

Imitate stack/tls writes after we create and initialize
the new thread, otherwise the races are not detected.

This is re-submit of the following reverted commits,
but without tests as they failed on a number of OSes/arches:
"tsan: fix and test detection of TLS races"
"tsan: fix tls_race3 test on darwin"
"tsan: print a meaningful frame for stack races"

Diff Detail

Event Timeline

dvyukov requested review of this revision.Oct 5 2021, 6:31 AM
dvyukov created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptOct 5 2021, 6:31 AM
Herald added a subscriber: Restricted Project. · View Herald Transcript
This revision was not accepted when it landed; it landed in state Needs Review.Oct 5 2021, 6:32 AM
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.