From 2b1cb6d54a3298204e01a2982e3d00a1f08743a2 Mon Sep 17 00:00:00 2001 From: Arthur Eubanks Date: Fri, 18 Sep 2020 11:32:58 -0700 Subject: [PATCH] [test][TSan] Fix tests under NPM Under NPM, the TSan passes are split into a module and function pass. A couple tests were testing for inserted module constructors, which is only part of the module pass. --- .../Instrumentation/ThreadSanitizer/do-not-instrument-memory-access.ll | 3 ++- llvm/test/Instrumentation/ThreadSanitizer/tsan_basic.ll | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/llvm/test/Instrumentation/ThreadSanitizer/do-not-instrument-memory-access.ll b/llvm/test/Instrumentation/ThreadSanitizer/do-not-instrument-memory-access.ll index 494df83c..5086a15 100644 --- a/llvm/test/Instrumentation/ThreadSanitizer/do-not-instrument-memory-access.ll +++ b/llvm/test/Instrumentation/ThreadSanitizer/do-not-instrument-memory-access.ll @@ -2,7 +2,8 @@ ; - Instruction profiler counter instrumentation has known intended races. ; - The gcov counters array has a known intended race. ; -; RUN: opt < %s -tsan -S | FileCheck %s +; RUN: opt < %s -tsan -S -enable-new-pm=0 | FileCheck %s +; RUN: opt < %s -passes='function(tsan),module(tsan-module)' -S | FileCheck %s target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9" diff --git a/llvm/test/Instrumentation/ThreadSanitizer/tsan_basic.ll b/llvm/test/Instrumentation/ThreadSanitizer/tsan_basic.ll index 100717a..20406c7 100644 --- a/llvm/test/Instrumentation/ThreadSanitizer/tsan_basic.ll +++ b/llvm/test/Instrumentation/ThreadSanitizer/tsan_basic.ll @@ -1,4 +1,4 @@ -; RUN: opt < %s -tsan -S | FileCheck %s +; RUN: opt < %s -tsan -S -enable-new-pm=0 | FileCheck %s ; RUN: opt < %s -passes='function(tsan),module(tsan-module)' -S | FileCheck %s target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" -- 2.7.4