================
@@ -0,0 +1,11 @@
+// RUN: %clang -std=c++17 %s 2>&1 | FileCheck %s --check-prefix=NO-TSAN 
--allow-empty
+// RUN: %clang -std=c++17 -fsanitize=thread %s 2>&1 | FileCheck %s 
--check-prefix=WITH-TSAN
+
+// WITH-TSAN: `std::atomic_thread_fence` is not supported with 
`-fsanitize=thread`
+// NO-TSAN-NOT: `std::atomic_thread_fence` is not supported with 
`-fsanitize=thread`
----------------
AaronBallman wrote:

```suggestion
// RUN: %clang -std=c++17 %s 2>&1 | FileCheck %s --check-prefix=NO-TSAN 
--allow-empty
// RUN: %clang -std=c++17 -fsanitize=thread %s 2>&1 | FileCheck %s 
--check-prefix=WITH-TSAN

// WITH-TSAN: `std::atomic_thread_fence` is not supported with 
`-fsanitize=thread`
// NO-TSAN-NOT: `std::atomic_thread_fence` is not supported with 
`-fsanitize=thread`
```
These should be running `%clang_cc1` so we're not executing the driver and the 
frontend. Also, please use `-verify` instead of `| FileCheck %s` to verify the 
diagnostics appear on the expected line. You can use `-verify=` to give 
different RUN lines a different prefix so you can show that the diagnostic is 
only emitted for some RUN lines.

https://github.com/llvm/llvm-project/pull/166542
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to