[llvm] 6181c19 - [AMDGPU][NFC] Remove isConstantAddr
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 16 17:49:34 PDT 2022
Author: LiaoChunyu
Date: 2022-06-17T08:49:29+08:00
New Revision: 6181c192837d799c320030bb227b655b83577130
URL: https://github.com/llvm/llvm-project/commit/6181c192837d799c320030bb227b655b83577130
DIFF: https://github.com/llvm/llvm-project/commit/6181c192837d799c320030bb227b655b83577130.diff
LOG: [AMDGPU][NFC] Remove isConstantAddr
fix isConstantAddr defined but not used
Reviewed By: rampitec
Differential Revision: https://reviews.llvm.org/D127959
Added:
Modified:
llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.cpp b/llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.cpp
index b994b53c21db0..09dbd2150db68 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.cpp
@@ -116,7 +116,6 @@ struct AMDGPUPerfHint {
bool isGlobalAddr(const Value *V) const;
bool isLocalAddr(const Value *V) const;
- bool isConstantAddr(const Value *V) const;
};
static std::pair<const Value *, const Type *> getMemoryInstrPtrAndType(
@@ -336,15 +335,6 @@ AMDGPUPerfHint::makeMemAccessInfo(Instruction *Inst) const {
return MAI;
}
-bool AMDGPUPerfHint::isConstantAddr(const Value *V) const {
- if (auto PT = dyn_cast<PointerType>(V->getType())) {
- unsigned As = PT->getAddressSpace();
- return As == AMDGPUAS::CONSTANT_ADDRESS ||
- As == AMDGPUAS::CONSTANT_ADDRESS_32BIT;
- }
- return false;
-}
-
bool AMDGPUPerfHint::MemAccessInfo::isLargeStride(
MemAccessInfo &Reference) const {
More information about the llvm-commits
mailing list