We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad73a43 commit 8aba95dCopy full SHA for 8aba95d
llvm/lib/Target/RISCV/Utils/RISCVMatInt.cpp
@@ -64,7 +64,7 @@ void generateInstSeq(int64_t Val, bool IsRV64, InstSeq &Res) {
64
// performed when the recursion returns.
65
66
int64_t Lo12 = SignExtend64<12>(Val);
67
- int64_t Hi52 = (Val + 0x800) >> 12;
+ int64_t Hi52 = ((uint64_t)Val + 0x800ull) >> 12;
68
int ShiftAmount = 12 + findFirstSet((uint64_t)Hi52);
69
Hi52 = SignExtend64(Hi52 >> (ShiftAmount - 12), 64 - ShiftAmount);
70
0 commit comments