From 092bc51cdbfb08e0ec4473963df806af09b26370 Mon Sep 17 00:00:00 2001 From: Owen Anderson Date: Thu, 9 Jul 2009 18:44:09 +0000 Subject: As Chris pointed out, we don't actually need to pass the context around here. llvm-svn: 75161 --- llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 4 ++-- llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'llvm/lib/CodeGen/SelectionDAG') diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 260996fac7a..2d154942c75 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -811,11 +811,11 @@ SelectionDAG::SelectionDAG(TargetLowering &tli, FunctionLoweringInfo &fli) } void SelectionDAG::init(MachineFunction &mf, MachineModuleInfo *mmi, - DwarfWriter *dw, LLVMContext* C) { + DwarfWriter *dw) { MF = &mf; MMI = mmi; DW = dw; - Context = C; + Context = mf.getFunction()->getContext(); } SelectionDAG::~SelectionDAG() { diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index d815523d825..485545c63a5 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -319,7 +319,7 @@ bool SelectionDAGISel::runOnFunction(Function &Fn) { MachineModuleInfo *MMI = getAnalysisIfAvailable(); DwarfWriter *DW = getAnalysisIfAvailable(); - CurDAG->init(*MF, MMI, DW, Context); + CurDAG->init(*MF, MMI, DW); FuncInfo->set(Fn, *MF, *CurDAG, EnableFastISel); SDL->init(GFI, *AA); -- cgit v1.2.3