configure: add --enable-tsan flag + fiber annotations for coroutine-ucontext
We tried running QEMU under tsan in 2016, but tsan's lack of support for
longjmp-based fibers was a blocker:
https://groups.google.com/forum/#!topic/thread-sanitizer/se0YuzfWazw
Fortunately, thread sanitizer gained fiber support in early 2019:
https://reviews.llvm.org/D54889
This patch brings tsan support upstream by importing the patch that annotated
QEMU's coroutines as tsan fibers in Android's QEMU fork:
https://android-review.googlesource.com/c/platform/external/qemu/+/844675
Tested with '--enable-tsan --cc=clang-9 --cxx=clang++-9 --disable-werror'
configure flags.
Signed-off-by: Lingfeng Yang <[email protected]>
Signed-off-by: Emilio G. Cota <[email protected]>
[cota: minor modifications + configure changes]
Signed-off-by: Robert Foley <[email protected]>
[RF: configure changes, coroutine fix + minor modifications]
Reviewed-by: Alex Bennée <[email protected]>
Signed-off-by: Alex Bennée <[email protected]>
Message-Id: <
20200609200738[email protected]>
Message-Id: <
20200612190237[email protected]>