[AArch64/arm] PR testsuite/85326 Avoid C++ tests when C++ compiler not present
[official-gcc.git] / gcc / testsuite / gcc.target / aarch64 / sha1_1.c
blobe208fe7d93fa2ffc06d6a08f66e3b38c34b64cb7
2 /* { dg-do compile } */
3 /* { dg-options "-march=armv8-a+crypto" } */
5 #include "arm_neon.h"
7 uint32x4_t
8 test_vsha1cq_u32 (uint32x4_t hash_abcd, uint32_t hash_e, uint32x4_t wk)
10 return vsha1cq_u32 (hash_abcd, hash_e, wk);
13 /* { dg-final { scan-assembler-times "sha1c\\tq" 1 } } */
15 uint32x4_t
16 test_vsha1mq_u32 (uint32x4_t hash_abcd, uint32_t hash_e, uint32x4_t wk)
18 return vsha1mq_u32 (hash_abcd, hash_e, wk);
21 /* { dg-final { scan-assembler-times "sha1m\\tq" 1 } } */
23 uint32x4_t
24 test_vsha1pq_u32 (uint32x4_t hash_abcd, uint32_t hash_e, uint32x4_t wk)
26 return vsha1pq_u32 (hash_abcd, hash_e, wk);
29 /* { dg-final { scan-assembler-times "sha1p\\tq" 1 } } */
31 uint32_t
32 test_vsha1h_u32 (uint32_t hash_e)
34 return vsha1h_u32 (hash_e);
37 /* { dg-final { scan-assembler-times "sha1h\\ts" 1 } } */
39 uint32x4_t
40 test_vsha1su0q_u32 (uint32x4_t w0_3, uint32x4_t w4_7, uint32x4_t w8_11)
42 return vsha1su0q_u32 (w0_3, w4_7, w8_11);
45 /* { dg-final { scan-assembler-times "sha1su0\\tv" 1 } } */
47 uint32x4_t
48 test_vsha1su1q_u32 (uint32x4_t tw0_3, uint32x4_t w12_15)
50 return vsha1su1q_u32 (tw0_3, w12_15);
53 /* { dg-final { scan-assembler-times "sha1su1\\tv" 1 } } */