Debian Codegraph @

gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vmulxh_f16_1.c

raw
1 /* { dg-require-effective-target arm_v8_2a_fp16_scalar_hw } */
2 /* { dg-add-options arm_v8_2a_fp16_scalar } */
3 /* { dg-skip-if "" { arm*-*-* } } */
4
5 #include <arm_fp16.h>
6
7 /* Input values. */
8 #define A 13.4
9 #define B __builtin_inff ()
10 #define C -34.8
11 #define D -__builtin_inff ()
12 #define E 63.1
13 #define F 0.0
14 #define G -4.8
15 #define H 0.0
16
17 #define I 0.7
18 #define J -__builtin_inff ()
19 #define K 11.23
20 #define L 98
21 #define M 87.1
22 #define N -0.0
23 #define O -1.1
24 #define P 7
25
26 float16_t input_1[] = { A, B, C, D, I, J, K, L };
27 float16_t input_2[] = { E, F, G, H, M, N, O, P };
28 uint16_t expected[] = { 0x629B /* A * E. */,
29 0x4000 /* FP16_C (2.0f). */,
30 0x5939 /* C * G. */,
31 0xC000 /* FP16_C (-2.0f). */,
32 0x53A0 /* I * M. */,
33 0x4000 /* FP16_C (2.0f). */,
34 0xCA2C /* K * O. */,
35 0x615C /* L * P. */ };
36
37 #define TEST_MSG "VMULXH_F16"
38 #define INSN_NAME vmulxh_f16
39
40 #define INPUT_1 input_1
41 #define INPUT_2 input_2
42 #define EXPECTED expected
43
44 #define INPUT_TYPE float16_t
45 #define OUTPUT_TYPE float16_t
46 #define OUTPUT_TYPE_SIZE 16
47
48 /* Include the template for unary scalar operations. */
49 #include "binary_scalar_op.inc"