[llvm] [CodeGen] Add const to getAddrModeArguments argument. NFC. (PR #122335)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 9 10:57:47 PST 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-backend-amdgpu
Author: Jay Foad (jayfoad)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/122335.diff
3 Files Affected:
- (modified) llvm/include/llvm/CodeGen/TargetLowering.h (+3-3)
- (modified) llvm/lib/Target/AMDGPU/SIISelLowering.cpp (+1-1)
- (modified) llvm/lib/Target/AMDGPU/SIISelLowering.h (+3-3)
``````````diff
diff --git a/llvm/include/llvm/CodeGen/TargetLowering.h b/llvm/include/llvm/CodeGen/TargetLowering.h
index 3751aac4df8ead..ce58777655e063 100644
--- a/llvm/include/llvm/CodeGen/TargetLowering.h
+++ b/llvm/include/llvm/CodeGen/TargetLowering.h
@@ -2795,9 +2795,9 @@ class TargetLoweringBase {
/// possible to be done in the address mode for that operand. This hook lets
/// targets also pass back when this should be done on intrinsics which
/// load/store.
- virtual bool getAddrModeArguments(IntrinsicInst * /*I*/,
- SmallVectorImpl<Value*> &/*Ops*/,
- Type *&/*AccessTy*/) const {
+ virtual bool getAddrModeArguments(const IntrinsicInst * /*I*/,
+ SmallVectorImpl<Value *> & /*Ops*/,
+ Type *& /*AccessTy*/) const {
return false;
}
diff --git a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
index 992f7ed99d3bb7..239de272cc66e4 100644
--- a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
+++ b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
@@ -1486,7 +1486,7 @@ void SITargetLowering::CollectTargetIntrinsicOperands(
}
}
-bool SITargetLowering::getAddrModeArguments(IntrinsicInst *II,
+bool SITargetLowering::getAddrModeArguments(const IntrinsicInst *II,
SmallVectorImpl<Value *> &Ops,
Type *&AccessTy) const {
Value *Ptr = nullptr;
diff --git a/llvm/lib/Target/AMDGPU/SIISelLowering.h b/llvm/lib/Target/AMDGPU/SIISelLowering.h
index 299c8f5f739235..eba268798e6b31 100644
--- a/llvm/lib/Target/AMDGPU/SIISelLowering.h
+++ b/llvm/lib/Target/AMDGPU/SIISelLowering.h
@@ -315,9 +315,9 @@ class SITargetLowering final : public AMDGPUTargetLowering {
SmallVectorImpl<SDValue> &Ops,
SelectionDAG &DAG) const override;
- bool getAddrModeArguments(IntrinsicInst * /*I*/,
- SmallVectorImpl<Value*> &/*Ops*/,
- Type *&/*AccessTy*/) const override;
+ bool getAddrModeArguments(const IntrinsicInst *I,
+ SmallVectorImpl<Value *> &Ops,
+ Type *&AccessTy) const override;
bool isLegalFlatAddressingMode(const AddrMode &AM, unsigned AddrSpace) const;
bool isLegalGlobalAddressingMode(const AddrMode &AM) const;
``````````
</details>
https://github.com/llvm/llvm-project/pull/122335
More information about the llvm-commits
mailing list