1 /* { dg-do compile { target { powerpc*-*-* } } } */
2 /* { dg-skip-if "" { powerpc*-*-darwin* } } */
3 /* { dg-require-effective-target powerpc_vsx_ok } */
4 /* { dg-options "-mdejagnu-cpu=power8 -mvsx -O2" } */
6 /* PR target/84154. Make sure on ISA 2.07 (power8) that we store the result of
7 a conversion to char/short using an offsettable address does not generate
8 direct moves for storing 32-bit integers, but does do a direct move for
12 double_to_uc (double x
, unsigned char *p
)
18 double_to_sc (double x
, signed char *p
)
24 double_to_us (double x
, unsigned short *p
)
30 double_to_ss (double x
, short *p
)
36 double_to_ui (double x
, unsigned int *p
)
42 double_to_si (double x
, int *p
)
47 /* { dg-final { scan-assembler-times {\mfctiwuz\M|\mxscvdpuxws\M} 3 } } */
48 /* { dg-final { scan-assembler-times {\mfctiwz\M|\mxscvdpsxws\M} 3 } } */
49 /* { dg-final { scan-assembler-times {\mmfvsrwz\M} 4 } } */
50 /* { dg-final { scan-assembler-times {\mstfiwx\M|\mstxsiwx\M} 2 } } */
51 /* { dg-final { scan-assembler-times {\mstb\M} 2 } } */
52 /* { dg-final { scan-assembler-times {\msth\M} 2 } } */
53 /* { dg-final { scan-assembler-not {\mlbz\M} } } */
54 /* { dg-final { scan-assembler-not {\mlhz\M} } } */
55 /* { dg-final { scan-assembler-not {\mlha\M} } } */
56 /* { dg-final { scan-assembler-not {\mmfvsrd\M} } } */
57 /* { dg-final { scan-assembler-not {\mstw\M} } } */