/* { dg-do compile { target { powerpc*-*-* && ilp32 } } } */
/* { dg-skip-if "" { powerpc*-*-darwin* } { "*" } { "" } } */
/* { dg-require-effective-target powerpc_vsx_ok } */
/* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power7" } } */
/* { dg-options "-O2 -msoft-float -mcpu=power7" } */

/* PR 47151: libgcc fails to build when using --with-cpu=power7 due to a missed
   TARGET_HARD_FLOAT test.  */
unsigned long long
func (float a)
{
  const float dfa = a;
  const unsigned int hi = dfa / 0x1p32f;
  const unsigned int lo = dfa - (float) hi * 0x1p32f;
  return ((unsigned long long) hi << (4 * 8)) | lo;
}
