For subtargets with full FP16, this is legal for s16, s32, and s64. Without full FP16, it's legal for s32 and s64.
For s128, this is a libcall.
We also support some vector types, but for now, let's just support scalars.
Paths
| Differential D108259
[AArch64][GlobalISel] Legalize scalar G_FMINNUM + G_FMAXNUM ClosedPublic Authored by paquette on Aug 17 2021, 5:33 PM.
Details Summary For subtargets with full FP16, this is legal for s16, s32, and s64. Without full FP16, it's legal for s32 and s64. For s128, this is a libcall. We also support some vector types, but for now, let's just support scalars.
Diff Detail
Event TimelineHerald added subscribers: hiraditya, kristof.beyls, rovka. · View Herald TranscriptAug 17 2021, 5:33 PM This revision is now accepted and ready to land.Aug 17 2021, 11:10 PM This revision now requires changes to proceed.Aug 17 2021, 11:10 PM
This revision is now accepted and ready to land.Aug 18 2021, 12:03 PM Closed by commit rG45e1a6bd2589: [AArch64][GlobalISel] Legalize scalar G_FMINNUM + G_FMAXNUM (authored by paquette). · Explain WhyAug 18 2021, 1:30 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 367314 llvm/lib/Target/AArch64/GISel/AArch64LegalizerInfo.cpp
llvm/test/CodeGen/AArch64/GlobalISel/legalize-fmaxnum.mir
llvm/test/CodeGen/AArch64/GlobalISel/legalize-fminnum.mir
llvm/test/CodeGen/AArch64/GlobalISel/legalizer-info-validation.mir
|
Is this actually needed? We don't support any non-pow-2 FP types right?