| 1 |
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve \ |
| 2 |
// RUN: -verify -verify-ignore-unexpected=error,note -emit-llvm -o - %s |
| 3 |
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sme \ |
| 4 |
// RUN: -verify -verify-ignore-unexpected=error,note -emit-llvm -o - %s |
| 5 |
// REQUIRES: aarch64-registered-target |
| 6 |
// expected-no-diagnostics |
| 7 |
|
| 8 |
#include <arm_sve.h> |
| 9 |
|
| 10 |
__attribute__((target("sme2p2"))) |
| 11 |
void test_svcompact(svbool_t pg, svfloat32_t op) __arm_streaming{ |
| 12 |
svcompact(pg, op); |
| 13 |
} |
| 14 |
|
| 15 |
void test_svcompact_nofeature(svbool_t pg, svfloat32_t op) __arm_streaming{ |
| 16 |
// expected-error@+1 {{'svcompact' needs target feature (sve)|(sme, sme2p2)}} |
| 17 |
svcompact(pg, op); |
| 18 |
} |