diff options
author | Ben Gamari <ben@smart-cactus.org> | 2020-11-08 09:29:16 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2020-11-08 09:29:16 -0500 |
commit | 638f38c50e80a19275f3a06535a0dd8130a17a53 (patch) | |
tree | ac18855cd2f39544e4841866fbabb3f86a4d1f35 /testsuite/driver | |
parent | b1d2c1f3246b3740589a59bdf7648c13de47c32b (diff) | |
parent | 07e82ba52228580cfbd90ff031e657acbecc715b (diff) | |
download | haskell-638f38c50e80a19275f3a06535a0dd8130a17a53.tar.gz |
Merge remote-tracking branch 'origin/wip/tsan/all'
Diffstat (limited to 'testsuite/driver')
-rw-r--r-- | testsuite/driver/testglobals.py | 3 | ||||
-rw-r--r-- | testsuite/driver/testlib.py | 7 |
2 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/driver/testglobals.py b/testsuite/driver/testglobals.py index 71a81bf509..ed34ce9ff0 100644 --- a/testsuite/driver/testglobals.py +++ b/testsuite/driver/testglobals.py @@ -151,6 +151,9 @@ class TestConfig: # Is the compiler dynamically linked? self.ghc_dynamic = False + # Are we running in a ThreadSanitizer-instrumented build? + self.have_thread_sanitizer = False + # Do symbols use leading underscores? self.leading_underscore = False diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 348c198d56..8ef5a8450c 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -591,6 +591,9 @@ def have_slow_bignum( ) -> bool: def llvm_build ( ) -> bool: return config.ghc_built_by_llvm +def have_thread_sanitizer( ) -> bool: + return config.have_thread_sanitizer + # --- # Note [Measuring residency] @@ -642,6 +645,10 @@ def collect_compiler_residency(tolerance_pct: float): def high_memory_usage(name, opts): opts.alone = True + # ThreadSanitizer significantly increases memory footprint; skip + if have_thread_sanitizer(): + opts.skip = True + # If a test is for a multi-CPU race, then running the test alone # increases the chance that we'll actually see it. def multi_cpu_race(name, opts): |