| 1 |
// RUN: %clang_cc1 -triple riscv64 -target-feature +zimop -emit-llvm -o - %s -fcf-protection=return | FileCheck %s |
| 2 |
// RUN: %clang_cc1 -triple riscv64 -target-feature +zimop -emit-llvm -o - %s | FileCheck -check-prefix=NOSHADOWSTACK %s |
| 3 |
// RUN: %clang_cc1 -triple riscv32 -target-feature +zimop -emit-llvm -o - %s -fcf-protection=return | FileCheck %s |
| 4 |
// RUN: %clang_cc1 -triple riscv32 -target-feature +zimop -emit-llvm -o - %s | FileCheck -check-prefix=NOSHADOWSTACK %s |
| 5 |
|
| 6 |
int foo(int *a) { return *a; } |
| 7 |
|
| 8 |
// CHECK: attributes {{.*}}"hw-shadow-stack"{{.*}} |
| 9 |
// NOSHADOWSTACK-NOT: attributes {{.*}}"hw-shadow-stack"{{.*}} |