Debian Codegraph @

gcc/testsuite/gcc.target/powerpc/convert-fp-64.c

raw
1 /* { dg-do compile { target { ! longdouble128 } } } */
2 /* { dg-options "-O2" } */
3 /* { dg-require-effective-target dfp } */
4
5 #define conv(M,N) mode_##N conv##M##N(mode_##M x) { return x; }
6
7 #define mode_sf float
8 #define mode_df double
9 #define mode_sd _Decimal32
10 #define mode_dd _Decimal64
11 #define mode_td _Decimal128
12
13 #define conv1(M) \
14 conv(M,sf) conv(M,df) \
15 conv(M,sd) conv(M,dd) conv(M,td)
16 #define conv2 \
17 conv1(sf) conv1(df) \
18 conv1(sd) conv1(dd) conv1(td)
19
20 conv2
21
22
23
24 /* { dg-final { scan-assembler-times {\mbl\M} 18 { target { ! hard_dfp } } } } */
25 /* { dg-final { scan-assembler-times {\mbl\M} 13 { target { hard_dfp } } } } */
26
27
28 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsfsd\M} 1 } } */
29 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsfdd\M} 1 } } */
30 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsftd\M} 1 } } */
31 /* { dg-final { scan-assembler-times {\mbl __dpd_truncdfsd\M} 1 } } */
32 /* { dg-final { scan-assembler-times {\mbl __dpd_extenddfdd\M} 1 } } */
33 /* { dg-final { scan-assembler-times {\mbl __dpd_extenddftd\M} 1 } } */
34 /* { dg-final { scan-assembler-times {\mbl __dpd_truncsdsf\M} 1 } } */
35 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsddf\M} 1 } } */
36 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsddd2\M} 1 { target { ! dfp } } } } */
37 /* { dg-final { scan-assembler-times {\mbl __dpd_extendsdtd2\M} 1 { target { ! dfp } } } } */
38 /* { dg-final { scan-assembler-times {\mbl __dpd_truncddsf\M} 1 } } */
39 /* { dg-final { scan-assembler-times {\mbl __dpd_truncdddf\M} 1 } } */
40 /* { dg-final { scan-assembler-times {\mbl __dpd_truncddsd2\M} 1 { target { ! dfp } } } } */
41 /* { dg-final { scan-assembler-times {\mbl __dpd_extendddtd2\M} 1 { target { ! dfp } } } } */
42 /* { dg-final { scan-assembler-times {\mbl __dpd_trunctdsf\M} 1 } } */
43 /* { dg-final { scan-assembler-times {\mbl __dpd_trunctddf\M} 1 } } */
44 /* { dg-final { scan-assembler-times {\mbl __dpd_trunctdsd2\M} 1 } } */
45 /* { dg-final { scan-assembler-times {\mbl __dpd_trunctddd2\M} 1 { target { ! dfp } } } } */
46
47
48 /* { dg-final { scan-assembler-times {\mfrsp|xsrsp\M} 1 } } */
49
50
51 /* { dg-final { scan-assembler-times {\mfmr\M} 0 { target { ! hard_dfp } } } } */
52 /* { dg-final { scan-assembler-times {\mfmr\M} 1 { target { hard_dfp } } } } */
53
54
55
56 /* { dg-final { scan-assembler-times {\mdrsp\M} 1 { target { hard_dfp } } } } */
57 /* { dg-final { scan-assembler-times {\mdrdpq\M} 1 { target { hard_dfp } } } } */
58 /* { dg-final { scan-assembler-times {\mdctdp\M} 2 { target { hard_dfp } } } } */
59 /* { dg-final { scan-assembler-times {\mdctqpq\M} 2 { target { hard_dfp } } } } */
60
61