[llvm] 248fba0 - AMDGPU: Remove pointless setOperationAction for xint_to_fp
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 21 20:24:59 PST 2023
Author: Matt Arsenault
Date: 2023-12-22T11:24:35+07:00
New Revision: 248fba0cd806a0f6bf4b0f12979f2185f2bed111
URL: https://github.com/llvm/llvm-project/commit/248fba0cd806a0f6bf4b0f12979f2185f2bed111
DIFF: https://github.com/llvm/llvm-project/commit/248fba0cd806a0f6bf4b0f12979f2185f2bed111.diff
LOG: AMDGPU: Remove pointless setOperationAction for xint_to_fp
The legalize action for uint_to_fp/sint_to_fp uses the source integer
type, not the result FP type so setting an action on an FP type does
nothing.
Added:
Modified:
llvm/lib/Target/AMDGPU/SIISelLowering.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
index 4f4bc45e49b43e..fc119aa61d01a2 100644
--- a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
+++ b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
@@ -540,10 +540,7 @@ SITargetLowering::SITargetLowering(const TargetMachine &TM,
MVT::f16, Custom);
setOperationAction({ISD::SINT_TO_FP, ISD::UINT_TO_FP}, MVT::i16, Custom);
-
- setOperationAction(
- {ISD::FP_TO_SINT, ISD::FP_TO_UINT, ISD::SINT_TO_FP, ISD::UINT_TO_FP},
- MVT::f16, Promote);
+ setOperationAction({ISD::FP_TO_SINT, ISD::FP_TO_UINT}, MVT::f16, Promote);
// F16 - VOP2 Actions.
setOperationAction({ISD::BR_CC, ISD::SELECT_CC}, MVT::f16, Expand);
More information about the llvm-commits
mailing list