| 1 |
/* { dg-do assemble { target aarch64_asm_sve2p1_ok } } */ |
| 2 |
/* { dg-do compile { target { ! aarch64_asm_sve2p1_ok } } } */ |
| 3 |
/* { dg-final { check-function-bodies "**" "" "-DCHECK_ASM" } } */ |
| 4 |
|
| 5 |
#include "test_sve_acle.h" |
| 6 |
|
| 7 |
#pragma GCC target "+sve2p1" |
| 8 |
#ifdef STREAMING_COMPATIBLE |
| 9 |
#pragma GCC target "+sme2" |
| 10 |
#endif |
| 11 |
|
| 12 |
/* |
| 13 |
** whilegt_pn0_rr_2_s64: |
| 14 |
** whilegt pn[0-9]+\.h, x0, x1, vlx2 |
| 15 |
** mov [^\n]+ |
| 16 |
** ret |
| 17 |
*/ |
| 18 |
TEST_COMPARE_S_C (whilegt_pn0_rr_2_s64, int64_t, |
| 19 |
pn0 = svwhilegt_c16_s64 (x0, x1, 2), |
| 20 |
pn0 = svwhilegt_c16 (x0, x1, 2)) |
| 21 |
|
| 22 |
/* |
| 23 |
** whilegt_pn7_rr_4_s64: |
| 24 |
** whilegt pn[0-9]+\.h, x0, x1, vlx4 |
| 25 |
** mov [^\n]+ |
| 26 |
** ret |
| 27 |
*/ |
| 28 |
TEST_COMPARE_S_C (whilegt_pn7_rr_4_s64, int64_t, |
| 29 |
pn7 = svwhilegt_c16_s64 (x0, x1, 4), |
| 30 |
pn7 = svwhilegt_c16 (x0, x1, 4)) |
| 31 |
|
| 32 |
/* |
| 33 |
** whilegt_pn8_rr_2_s64: |
| 34 |
** whilegt pn8\.h, x0, x1, vlx2 |
| 35 |
** ret |
| 36 |
*/ |
| 37 |
TEST_COMPARE_S_C (whilegt_pn8_rr_2_s64, int64_t, |
| 38 |
pn8 = svwhilegt_c16_s64 (x0, x1, 2), |
| 39 |
pn8 = svwhilegt_c16 (x0, x1, 2)) |
| 40 |
|
| 41 |
/* |
| 42 |
** whilegt_pn15_rr_4_s64: |
| 43 |
** whilegt pn15\.h, x0, x1, vlx4 |
| 44 |
** ret |
| 45 |
*/ |
| 46 |
TEST_COMPARE_S_C (whilegt_pn15_rr_4_s64, int64_t, |
| 47 |
pn15 = svwhilegt_c16_s64 (x0, x1, 4), |
| 48 |
pn15 = svwhilegt_c16 (x0, x1, 4)) |
| 49 |
|
| 50 |
/* |
| 51 |
** whilegt_pn8_0r_2_s64: |
| 52 |
** whilegt pn8\.h, xzr, x1, vlx2 |
| 53 |
** ret |
| 54 |
*/ |
| 55 |
TEST_COMPARE_S_C (whilegt_pn8_0r_2_s64, int64_t, |
| 56 |
pn8 = svwhilegt_c16 ((int64_t) 0, x1, 2), |
| 57 |
pn8 = svwhilegt_c16_s64 (0, x1, 2)) |
| 58 |
|
| 59 |
/* |
| 60 |
** whilegt_pn8_5r_4_s64: |
| 61 |
** mov (x[0-9]+), #?5 |
| 62 |
** whilegt pn8\.h, \1, x1, vlx4 |
| 63 |
** ret |
| 64 |
*/ |
| 65 |
TEST_COMPARE_S_C (whilegt_pn8_5r_4_s64, int64_t, |
| 66 |
pn8 = svwhilegt_c16 ((int64_t) 5, x1, 4), |
| 67 |
pn8 = svwhilegt_c16_s64 (5, x1, 4)) |
| 68 |
|
| 69 |
/* |
| 70 |
** whilegt_pn8_r0_2_s64: |
| 71 |
** whilegt pn8\.h, x0, xzr, vlx2 |
| 72 |
** ret |
| 73 |
*/ |
| 74 |
TEST_COMPARE_S_C (whilegt_pn8_r0_2_s64, int64_t, |
| 75 |
pn8 = svwhilegt_c16 (x0, (int64_t) 0, 2), |
| 76 |
pn8 = svwhilegt_c16_s64 (x0, 0, 2)) |
| 77 |
|
| 78 |
/* |
| 79 |
** whilegt_pn15_r5_4_s64: |
| 80 |
** mov (x[0-9]+), #?5 |
| 81 |
** whilegt pn15\.h, x0, \1, vlx4 |
| 82 |
** ret |
| 83 |
*/ |
| 84 |
TEST_COMPARE_S_C (whilegt_pn15_r5_4_s64, int64_t, |
| 85 |
pn15 = svwhilegt_c16 (x0, (int64_t) 5, 4), |
| 86 |
pn15 = svwhilegt_c16_s64 (x0, 5, 4)) |
| 87 |
|
| 88 |
/* |
| 89 |
** whilegt_pn8_rr_2_u64: |
| 90 |
** whilehi pn8\.h, x0, x1, vlx2 |
| 91 |
** ret |
| 92 |
*/ |
| 93 |
TEST_COMPARE_S_C (whilegt_pn8_rr_2_u64, uint64_t, |
| 94 |
pn8 = svwhilegt_c16_u64 (x0, x1, 2), |
| 95 |
pn8 = svwhilegt_c16 (x0, x1, 2)) |
| 96 |
|
| 97 |
/* |
| 98 |
** whilegt_pn8_0r_4_u64: |
| 99 |
** whilehi pn8\.h, xzr, x1, vlx4 |
| 100 |
** ret |
| 101 |
*/ |
| 102 |
TEST_COMPARE_S_C (whilegt_pn8_0r_4_u64, uint64_t, |
| 103 |
pn8 = svwhilegt_c16 ((uint64_t) 0, x1, 4), |
| 104 |
pn8 = svwhilegt_c16_u64 (0, x1, 4)) |
| 105 |
|
| 106 |
/* |
| 107 |
** whilegt_pn8_5r_2_u64: |
| 108 |
** mov (x[0-9]+), #?5 |
| 109 |
** whilehi pn8\.h, \1, x1, vlx2 |
| 110 |
** ret |
| 111 |
*/ |
| 112 |
TEST_COMPARE_S_C (whilegt_pn8_5r_2_u64, uint64_t, |
| 113 |
pn8 = svwhilegt_c16 ((uint64_t) 5, x1, 2), |
| 114 |
pn8 = svwhilegt_c16_u64 (5, x1, 2)) |
| 115 |
|
| 116 |
/* |
| 117 |
** whilegt_pn8_r5_4_u64: |
| 118 |
** mov (x[0-9]+), #?5 |
| 119 |
** whilehi pn8\.h, x0, \1, vlx4 |
| 120 |
** ret |
| 121 |
*/ |
| 122 |
TEST_COMPARE_S_C (whilegt_pn8_r5_4_u64, uint64_t, |
| 123 |
pn8 = svwhilegt_c16 (x0, (uint64_t) 5, 4), |
| 124 |
pn8 = svwhilegt_c16_u64 (x0, 5, 4)) |