| 1 |
/* { dg-do compile { target { powerpc*-*-* } } } */ |
| 2 |
/* { dg-skip-if "" { powerpc*-*-darwin* } } */ |
| 3 |
/* { dg-require-effective-target ilp32 } */ |
| 4 |
/* { dg-require-effective-target powerpc_fprs } */ |
| 5 |
/* { dg-options "-O2 -mdejagnu-cpu=power5 -ffast-math" } */ |
| 6 |
/* { dg-final { scan-assembler-not "lfiwax" } } */ |
| 7 |
/* { dg-final { scan-assembler-not "lfiwzx" } } */ |
| 8 |
/* { dg-final { scan-assembler-times "fcfid " 10 } } */ |
| 9 |
/* { dg-final { scan-assembler-not "fcfids " } } */ |
| 10 |
/* { dg-final { scan-assembler-not "fcfidus " } } */ |
| 11 |
/* { dg-final { scan-assembler-not "fcfidu " } } */ |
| 12 |
/* { dg-final { scan-assembler-not "xscvsxddp " } } */ |
| 13 |
/* { dg-final { scan-assembler-not "xscvuxddp " } } */ |
| 14 |
|
| 15 |
void int_to_float (float *dest, int *src) |
| 16 |
{ |
| 17 |
*dest = (float) *src; |
| 18 |
} |
| 19 |
|
| 20 |
void int_to_double (double *dest, int *src) |
| 21 |
{ |
| 22 |
*dest = (double) *src; |
| 23 |
} |
| 24 |
|
| 25 |
void uint_to_float (float *dest, unsigned int *src) |
| 26 |
{ |
| 27 |
*dest = (float) *src; |
| 28 |
} |
| 29 |
|
| 30 |
void uint_to_double (double *dest, unsigned int *src) |
| 31 |
{ |
| 32 |
*dest = (double) *src; |
| 33 |
} |
| 34 |
|
| 35 |
void llong_to_float (float *dest, long long *src) |
| 36 |
{ |
| 37 |
*dest = (float) *src; |
| 38 |
} |
| 39 |
|
| 40 |
void llong_to_double (double *dest, long long *src) |
| 41 |
{ |
| 42 |
*dest = (double) *src; |
| 43 |
} |
| 44 |
|
| 45 |
void ullong_to_float (float *dest, unsigned long long *src) |
| 46 |
{ |
| 47 |
*dest = (float) *src; |
| 48 |
} |
| 49 |
|
| 50 |
void ullong_to_double (double *dest, unsigned long long *src) |
| 51 |
{ |
| 52 |
*dest = (double) *src; |
| 53 |
} |