[llvm] 80fc9bc - [Hexagon] Use getSigned() for signed value
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 9 07:14:11 PST 2025
Author: Nikita Popov
Date: 2025-12-09T16:13:59+01:00
New Revision: 80fc9bc17715cb4e68ec233ae1db668ac321e777
URL: https://github.com/llvm/llvm-project/commit/80fc9bc17715cb4e68ec233ae1db668ac321e777
DIFF: https://github.com/llvm/llvm-project/commit/80fc9bc17715cb4e68ec233ae1db668ac321e777.diff
LOG: [Hexagon] Use getSigned() for signed value
Added:
Modified:
llvm/lib/Target/Hexagon/HexagonISelLowering.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp b/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp
index bae9d705f5a7a..025e5b087abed 100644
--- a/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp
@@ -2527,7 +2527,7 @@ HexagonTargetLowering::getBuildVectorConstInts(ArrayRef<SDValue> Values,
// Make sure to always cast to IntTy.
if (auto *CN = dyn_cast<ConstantSDNode>(V.getNode())) {
const ConstantInt *CI = CN->getConstantIntValue();
- Consts[i] = ConstantInt::get(IntTy, CI->getValue().getSExtValue());
+ Consts[i] = ConstantInt::getSigned(IntTy, CI->getValue().getSExtValue());
} else if (auto *CN = dyn_cast<ConstantFPSDNode>(V.getNode())) {
const ConstantFP *CF = CN->getConstantFPValue();
APInt A = CF->getValueAPF().bitcastToAPInt();
More information about the llvm-commits
mailing list