Skip to content

Commit b5fff4e

Browse files
remove dead code
1 parent 0075167 commit b5fff4e

File tree

6 files changed

+71
-350
lines changed

6 files changed

+71
-350
lines changed

llvm/lib/Target/SPIRV/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ add_llvm_target(SPIRVCodeGen
2020
SPIRVCallLowering.cpp
2121
SPIRVInlineAsmLowering.cpp
2222
SPIRVCommandLine.cpp
23-
SPIRVDuplicatesTracker.cpp
2423
SPIRVEmitIntrinsics.cpp
2524
SPIRVGlobalRegistry.cpp
2625
SPIRVInstrInfo.cpp

llvm/lib/Target/SPIRV/SPIRVDuplicatesTracker.cpp

Lines changed: 0 additions & 136 deletions
This file was deleted.

llvm/lib/Target/SPIRV/SPIRVDuplicatesTracker.h

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -211,23 +211,7 @@ class SPIRVGeneralDuplicatesTracker {
211211
SPIRVDuplicatesTracker<MachineInstr> MT;
212212
SPIRVDuplicatesTracker<SPIRV::SpecialTypeDescriptor> ST;
213213

214-
// NOTE: using MOs instead of regs to get rid of MF dependency to be able
215-
// to use flat data structure.
216-
// NOTE: replacing DenseMap with MapVector doesn't affect overall correctness
217-
// but makes LITs more stable, should prefer DenseMap still due to
218-
// significant perf difference.
219-
using SPIRVReg2EntryTy =
220-
MapVector<MachineOperand *, SPIRV::DTSortableEntry *>;
221-
222-
template <typename T>
223-
void prebuildReg2Entry(SPIRVDuplicatesTracker<T> &DT,
224-
SPIRVReg2EntryTy &Reg2Entry,
225-
const SPIRVInstrInfo *TII);
226-
227214
public:
228-
void buildDepsGraph(std::vector<SPIRV::DTSortableEntry *> &Graph,
229-
const SPIRVInstrInfo *TII, MachineModuleInfo *MMI);
230-
231215
void add(const Type *Ty, const MachineFunction *MF, Register R) {
232216
TT.add(unifyPtrType(Ty), MF, R);
233217
}

llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,7 @@ class SPIRVGlobalRegistry {
9090
DenseMap<Value *, CallInst *> AssignPtrTypeInstr;
9191

9292
// Maps OpVariable and OpFunction-related v-regs to its LLVM IR definition.
93-
DenseMap<std::pair<const MachineFunction *, Register>, const Value *>
94-
Reg2GO;
93+
DenseMap<std::pair<const MachineFunction *, Register>, const Value *> Reg2GO;
9594

9695
// Add a new OpTypeXXX instruction without checking for duplicates.
9796
SPIRVType *createSPIRVType(const Type *Type, MachineIRBuilder &MIRBuilder,
@@ -155,12 +154,6 @@ class SPIRVGlobalRegistry {
155154
return DT.find(F, MF);
156155
}
157156

158-
void buildDepsGraph(std::vector<SPIRV::DTSortableEntry *> &Graph,
159-
const SPIRVInstrInfo *TII,
160-
MachineModuleInfo *MMI = nullptr) {
161-
DT.buildDepsGraph(Graph, TII, MMI);
162-
}
163-
164157
void setBound(unsigned V) { Bound = V; }
165158
unsigned getBound() { return Bound; }
166159

0 commit comments

Comments
 (0)