diff options
Diffstat (limited to 'test/CodeGenObjC/attr-speculative-load-hardening.m')
-rw-r--r-- | test/CodeGenObjC/attr-speculative-load-hardening.m | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/CodeGenObjC/attr-speculative-load-hardening.m b/test/CodeGenObjC/attr-speculative-load-hardening.m new file mode 100644 index 0000000000..3b4929d935 --- /dev/null +++ b/test/CodeGenObjC/attr-speculative-load-hardening.m @@ -0,0 +1,14 @@ +// RUN: %clang -emit-llvm %s -o - -S | FileCheck %s -check-prefix=SLH + +int main() __attribute__((speculative_load_hardening)) { + return 0; +} + +int test() __attribute__((no_speculative_load_hardening)) { + return 0; +} + +// SLH: @{{.*}}main{{.*}}[[SLH:#[0-9]+]] +// SLH: @{{.*}}test{{.*}}[[NOSLH:#[0-9]+]] +// SLH: attributes [[SLH]] = { {{.*}}speculative_load_hardening{{.*}} } +// SLH-NOT: attributes [[NOSLH]] = { {{.*}}speculative_load_hardening{{.*}} } |