Debian Codegraph @

clang/test/Sema/aarch64-neon-immediate-ranges/matrix-multiplication.c

raw
1 // RUN: %clang_cc1 -triple aarch64-linux-gnu -target-feature +neon -target-feature +v8.6a -ffreestanding -fsyntax-only -verify %s
2
3 #include <arm_neon.h>
4 // REQUIRES: aarch64-registered-target
5
6
7 void test_dot_product_s32(int8x8_t arg_i8x8, int32x2_t arg_i32x2, uint8x16_t arg_u8x16, uint8x8_t arg_u8x8,
8 int32x4_t arg_i32x4, int8x16_t arg_i8x16) {
9 vusdot_lane_s32(arg_i32x2, arg_u8x8, arg_i8x8, 0);
10 vusdot_lane_s32(arg_i32x2, arg_u8x8, arg_i8x8, 1);
11 vusdot_lane_s32(arg_i32x2, arg_u8x8, arg_i8x8, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
12 vusdot_lane_s32(arg_i32x2, arg_u8x8, arg_i8x8, 2); // expected-error-re {{argument value {{.*}} is outside the valid range}}
13
14 vsudot_lane_s32(arg_i32x2, arg_i8x8, arg_u8x8, 0);
15 vsudot_lane_s32(arg_i32x2, arg_i8x8, arg_u8x8, 1);
16 vsudot_lane_s32(arg_i32x2, arg_i8x8, arg_u8x8, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
17 vsudot_lane_s32(arg_i32x2, arg_i8x8, arg_u8x8, 2); // expected-error-re {{argument value {{.*}} is outside the valid range}}
18
19 vusdot_laneq_s32(arg_i32x2, arg_u8x8, arg_i8x16, 0);
20 vusdot_laneq_s32(arg_i32x2, arg_u8x8, arg_i8x16, 3);
21 vusdot_laneq_s32(arg_i32x2, arg_u8x8, arg_i8x16, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
22 vusdot_laneq_s32(arg_i32x2, arg_u8x8, arg_i8x16, 4); // expected-error-re {{argument value {{.*}} is outside the valid range}}
23
24 vsudot_laneq_s32(arg_i32x2, arg_i8x8, arg_u8x16, 0);
25 vsudot_laneq_s32(arg_i32x2, arg_i8x8, arg_u8x16, 3);
26 vsudot_laneq_s32(arg_i32x2, arg_i8x8, arg_u8x16, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
27 vsudot_laneq_s32(arg_i32x2, arg_i8x8, arg_u8x16, 4); // expected-error-re {{argument value {{.*}} is outside the valid range}}
28
29 vusdotq_lane_s32(arg_i32x4, arg_u8x16, arg_i8x8, 0);
30 vusdotq_lane_s32(arg_i32x4, arg_u8x16, arg_i8x8, 1);
31 vusdotq_lane_s32(arg_i32x4, arg_u8x16, arg_i8x8, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
32 vusdotq_lane_s32(arg_i32x4, arg_u8x16, arg_i8x8, 2); // expected-error-re {{argument value {{.*}} is outside the valid range}}
33
34 vsudotq_lane_s32(arg_i32x4, arg_i8x16, arg_u8x8, 0);
35 vsudotq_lane_s32(arg_i32x4, arg_i8x16, arg_u8x8, 1);
36 vsudotq_lane_s32(arg_i32x4, arg_i8x16, arg_u8x8, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
37 vsudotq_lane_s32(arg_i32x4, arg_i8x16, arg_u8x8, 2); // expected-error-re {{argument value {{.*}} is outside the valid range}}
38
39 vusdotq_laneq_s32(arg_i32x4, arg_u8x16, arg_i8x16, 0);
40 vusdotq_laneq_s32(arg_i32x4, arg_u8x16, arg_i8x16, 3);
41 vusdotq_laneq_s32(arg_i32x4, arg_u8x16, arg_i8x16, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
42 vusdotq_laneq_s32(arg_i32x4, arg_u8x16, arg_i8x16, 4); // expected-error-re {{argument value {{.*}} is outside the valid range}}
43
44 vsudotq_laneq_s32(arg_i32x4, arg_i8x16, arg_u8x16, 0);
45 vsudotq_laneq_s32(arg_i32x4, arg_i8x16, arg_u8x16, 3);
46 vsudotq_laneq_s32(arg_i32x4, arg_i8x16, arg_u8x16, -1); // expected-error-re {{argument value {{.*}} is outside the valid range}}
47 vsudotq_laneq_s32(arg_i32x4, arg_i8x16, arg_u8x16, 4); // expected-error-re {{argument value {{.*}} is outside the valid range}}
48
49 }
50