mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-25 14:36:06 +00:00

Since we don't always need the vendor extension to be in riscv_vector.td, so it's better to make it be in separated header. Depends on D148223 and D148680 Differential Revision: https://reviews.llvm.org/D148308
23 lines
816 B
C
23 lines
816 B
C
// RUN: %clang_cc1 -triple riscv64 -target-feature +v %s -emit-llvm -o - \
|
|
// RUN: 2>&1 | FileCheck %s
|
|
|
|
#pragma clang riscv intrinsic vvvv
|
|
// CHECK: warning: unexpected argument 'vvvv' to '#pragma riscv'; expected 'vector' or 'sifive_vector' [-Wignored-pragmas]
|
|
|
|
#pragma clang riscv what + 3241
|
|
// CHECK: warning: unexpected argument 'what' to '#pragma riscv'; expected 'intrinsic' [-Wignored-pragmas]
|
|
#pragma clang riscv int i = 12;
|
|
// CHECK: warning: unexpected argument 'int' to '#pragma riscv'; expected 'intrinsic' [-Wignored-pragmas]
|
|
#pragma clang riscv intrinsic vector bar
|
|
// CHECK: warning: extra tokens at end of '#pragma clang riscv intrinsic' - ignored [-Wignored-pragmas]
|
|
|
|
#define FOO 0
|
|
|
|
int main()
|
|
{
|
|
return FOO;
|
|
}
|
|
|
|
// Make sure no more warnings
|
|
// CHECK-NOT: warning:
|