diff --git a/llvm/include/llvm/CodeGen/FastISel.h b/llvm/include/llvm/CodeGen/FastISel.h index f91bd692accad8..95e8004cc09c7a 100644 --- a/llvm/include/llvm/CodeGen/FastISel.h +++ b/llvm/include/llvm/CodeGen/FastISel.h @@ -278,9 +278,7 @@ class FastISel { Register getRegForGEPIndex(MVT PtrVT, const Value *Idx); /// Retained for ABI compatibility in release branch. - Register getRegForGEPIndex(const Value *Idx) { - return getRegForGEPIndex(TLI.getPointerTy(DL), Idx); - } + Register getRegForGEPIndex(const Value *Idx); /// We're checking to see if we can fold \p LI into \p FoldInst. Note /// that we could have a sequence where multiple LLVM IR instructions are diff --git a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp index 246acc7f405837..398381a8164b2b 100644 --- a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp @@ -397,6 +397,10 @@ Register FastISel::getRegForGEPIndex(MVT PtrVT, const Value *Idx) { return IdxN; } +Register FastISel::getRegForGEPIndex(const Value *Idx) { + return getRegForGEPIndex(TLI.getPointerTy(DL), Idx); +} + void FastISel::recomputeInsertPt() { if (getLastLocalValue()) { FuncInfo.InsertPt = getLastLocalValue();