[llvm] [AMDGPU] Folding imm offset in more cases for scratch access (PR #70634)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 28 21:46:36 PST 2023
================
@@ -4494,14 +4502,78 @@ bool AMDGPUInstructionSelector::isDSOffset2Legal(Register Base, int64_t Offset0,
return KB->signBitIsZero(Base);
}
-bool AMDGPUInstructionSelector::isFlatScratchBaseLegal(
- Register Base, uint64_t FlatVariant) const {
- if (FlatVariant != SIInstrFlags::FlatScratch)
+// Return whether the operation has NoUnsignedWrap property.
+bool isNoUnsignedWrap(MachineInstr *Addr) {
----------------
MaskRay wrote:
I added `static` to make this internal linkage and changed a `};`to `}` in commit 9535e011c7b25ece5e51c0b9e0f2c43a2912a417
https://github.com/llvm/llvm-project/pull/70634
More information about the llvm-commits
mailing list