| 1 |
// RUN: %clang --target=riscv32 -E -dM %s -o - | \ |
| 2 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 3 |
|
| 4 |
// RUN: %clang --target=riscv32 -fcf-protection=return -E -dM %s -o - | \ |
| 5 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 6 |
|
| 7 |
// RUN: %clang --target=riscv32 -fcf-protection=full -E -dM %s -o - | \ |
| 8 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 9 |
|
| 10 |
// RUN: %clang --target=riscv32 -march=rv32i_zicfiss1p0 \ |
| 11 |
// RUN: -menable-experimental-extensions -E -dM %s -o - | \ |
| 12 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 13 |
|
| 14 |
// RUN: %clang --target=riscv32 -march=rv32i_zicfiss1p0 \ |
| 15 |
// RUN: -menable-experimental-extensions -fcf-protection=return -E -dM %s \ |
| 16 |
// RUN: -o - | FileCheck --check-prefixes=SHSTK-MACRO %s |
| 17 |
|
| 18 |
// RUN: %clang --target=riscv32 -march=rv32i_zicfiss1p0 \ |
| 19 |
// RUN: -menable-experimental-extensions -fcf-protection=full -E -dM %s -o - \ |
| 20 |
// RUN: | FileCheck --check-prefixes=SHSTK-MACRO %s |
| 21 |
|
| 22 |
// RUN: %clang --target=riscv64 -E -dM %s -o - | \ |
| 23 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 24 |
|
| 25 |
// RUN: %clang --target=riscv64 -fcf-protection=return -E -dM %s -o - | \ |
| 26 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 27 |
|
| 28 |
// RUN: %clang --target=riscv64 -fcf-protection=full -E -dM %s -o - | \ |
| 29 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 30 |
|
| 31 |
// RUN: %clang --target=riscv64 -march=rv64i_zicfiss1p0 \ |
| 32 |
// RUN: -menable-experimental-extensions -E -dM %s -o - | \ |
| 33 |
// RUN: FileCheck --check-prefixes=NO-MACRO %s |
| 34 |
|
| 35 |
// RUN: %clang --target=riscv64 -march=rv64i_zicfiss1p0 \ |
| 36 |
// RUN: -menable-experimental-extensions -fcf-protection=return -E -dM %s \ |
| 37 |
// RUN: -o - | FileCheck --check-prefixes=SHSTK-MACRO %s |
| 38 |
|
| 39 |
// RUN: %clang --target=riscv64 -march=rv64i_zicfiss1p0 \ |
| 40 |
// RUN: -menable-experimental-extensions -fcf-protection=full -E -dM %s -o - \ |
| 41 |
// RUN: | FileCheck --check-prefixes=SHSTK-MACRO %s |
| 42 |
|
| 43 |
// SHSTK-MACRO-NOT: __CET__ |
| 44 |
// SHSTK-MACRO: __riscv_shadow_stack 1{{$}} |
| 45 |
// SHSTK-MACRO-NOT: __CET__ |
| 46 |
// NO-MACRO-NOT: __riscv_shadow_stack |