From 03affa8099cba3876aca209daa213dcb880bc34a Mon Sep 17 00:00:00 2001 From: Alex Richardson Date: Mon, 3 Aug 2020 10:31:31 +0100 Subject: [PATCH] [msan] Compile the libatomic.c test with a C compiler Otherwise we end up compiling in C++ mode and on FreeBSD /usr/include/stdatomic.h is not compatible with C++ since it uses _Bool. Reviewed By: guiand, eugenis, vitalybuka, emaste Differential Revision: https://reviews.llvm.org/D84510 --- compiler-rt/test/msan/libatomic.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/compiler-rt/test/msan/libatomic.c b/compiler-rt/test/msan/libatomic.c index 5d8aa9a..a8c030b 100644 --- a/compiler-rt/test/msan/libatomic.c +++ b/compiler-rt/test/msan/libatomic.c @@ -1,6 +1,6 @@ -// RUN: %clangxx_msan -fsanitize-memory-track-origins=2 -latomic -DTEST_STORE -O0 %s -o %t && %run %t 2>&1 -// RUN: %clangxx_msan -fsanitize-memory-track-origins=0 -latomic -DTEST_LOAD -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK -// RUN: %clangxx_msan -fsanitize-memory-track-origins=2 -latomic -DTEST_LOAD -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-SHADOW +// RUN: %clang_msan -fsanitize-memory-track-origins=2 -latomic -DTEST_STORE -O0 %s -o %t && %run %t 2>&1 +// RUN: %clang_msan -fsanitize-memory-track-origins=0 -latomic -DTEST_LOAD -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK +// RUN: %clang_msan -fsanitize-memory-track-origins=2 -latomic -DTEST_LOAD -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-SHADOW // PPC has no libatomic // UNSUPPORTED: powerpc64-target-arch -- 2.7.4