xref: /llvm-project/clang/test/CodeGen/rtsan_attribute_inserted.c (revision 4102625380823e58d7b13f01b5bd979a29bce19e)
1 // RUN: %clang_cc1  -triple x86_64-unknown-linux -fsanitize=realtime %s -emit-llvm -o - %s | FileCheck %s
2 
3 float process(float *a) [[clang::nonblocking]] { return *a; }
4 // CHECK: @process{{.*}} #0 {
5 // CHECK: attributes #0 = {
6 // CHECK-SAME: {{.*sanitize_realtime .*}}
7 
8 int spinlock(int *a) [[clang::blocking]] { return *a; }
9 // CHECK: @spinlock{{.*}} #1 {
10 // CHECK: attributes #1 = {
11 // CHECK-SAME: {{.*sanitize_realtime_blocking .*}}
12