https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77579
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |pinskia at gcc dot
gnu.org
Status|NEW |ASSIGNED
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
So r13-6618-g0b3c630fcc4406 changed it for integral types, we won't form fma in
this case anyways. But with a multiple of power of 2, forming an fma is
actually better.
I am going to look into this further, maybe a target hook to see if you should
form one which normally returns true for most except:
+ if (ANY_INTEGRAL_TYPE_P (type)
+ && !has_single_use (mul_result))
+ return false;
And then aarch64 has a special one for scalar integral types to allow forming
for power of 2 multiples too ...
Mine for now. But I am not sure I will get to it for GCC 16 though. Let's see.