https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111867

--- Comment #4 from Iain Sandoe <iains at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #3)
> (In reply to Andrew Pinski from comment #2)
> > Maybe something like:
> > diff --git a/gcc/config/aarch64/aarch64.cc b/gcc/config/aarch64/aarch64.cc
> > index 62b1ae0652f..db2dde84329 100644
> > --- a/gcc/config/aarch64/aarch64.cc
> > +++ b/gcc/config/aarch64/aarch64.cc
> > @@ -23788,7 +23788,8 @@ aarch64_float_const_representable_p (rtx x)
> >      return false;
> > 
> >    if (GET_MODE (x) == VOIDmode
> > -      || (GET_MODE (x) == HFmode && !TARGET_FP_F16INST))
> > +      || (GET_MODE (x) == HFmode && !TARGET_FP_F16INST)
> > +      || (GET_MODE (x) == BFmode))
> >      return false;
> > 
> >    r = *CONST_DOUBLE_REAL_VALUE (x);

Yeah that fixes this case; re-running the testsuite to see if that clears any
other bf16 fails.


> That is there are no fmov instructions for bfmode constants ...

Although I notice there's a spare bit pattern in the "ftype" field [0b10) in
the fmov insn... but I guess that's being kept for something more useful than
bf16.

Reply via email to