[llvm] [NVPTX] Rework and cleanup FTZ ISel (PR #146410)
Alex MacLean via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 9 09:48:29 PDT 2025
================
@@ -397,45 +403,29 @@ static unsigned getPTXCmpMode(const CondCodeSDNode &CondCode, bool FTZ) {
return CmpMode::LEU;
case ISD::SETUNE:
return CmpMode::NEU;
- case ISD::SETEQ:
- return CmpMode::EQ;
- case ISD::SETGT:
- return CmpMode::GT;
- case ISD::SETGE:
- return CmpMode::GE;
- case ISD::SETLT:
- return CmpMode::LT;
- case ISD::SETLE:
- return CmpMode::LE;
- case ISD::SETNE:
- return CmpMode::NE;
}
}(CondCode.get());
-
- if (FTZ)
- PTXCmpMode |= NVPTX::PTXCmpMode::FTZ_FLAG;
-
- return PTXCmpMode;
+ return CurDAG->getTargetConstant(PTXCmpMode, SDLoc(), MVT::i32);
----------------
AlexMaclean wrote:
Since we know that this is just going to be an operand within another instructions there is no point adding a debug-loc.
https://github.com/llvm/llvm-project/pull/146410
More information about the llvm-commits
mailing list