From 0711d68fa77df0cd4e4882d98b27541cccbb4468 Mon Sep 17 00:00:00 2001 From: Evan Cheng Date: Mon, 30 Jun 2008 20:45:06 +0000 Subject: Split scheduling from instruction selection. llvm-svn: 52923 --- llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'llvm/lib/CodeGen') diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index 1124f37d2e8..8cfc334c025 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -43,9 +43,10 @@ #include "llvm/Target/TargetLowering.h" #include "llvm/Target/TargetMachine.h" #include "llvm/Target/TargetOptions.h" -#include "llvm/Support/MathExtras.h" -#include "llvm/Support/Debug.h" #include "llvm/Support/Compiler.h" +#include "llvm/Support/Debug.h" +#include "llvm/Support/MathExtras.h" +#include "llvm/Support/Timer.h" #include using namespace llvm; @@ -5354,7 +5355,14 @@ void SelectionDAGISel::CodeGenAndEmitDAG(SelectionDAG &DAG) { // Third, instruction select all of the operations to machine code, adding the // code to the MachineBasicBlock. - InstructionSelectBasicBlock(DAG); + InstructionSelect(DAG); + + // Emit machine code to BB. This can change 'BB' to the last block being + // inserted into. + ScheduleAndEmitDAG(DAG); + + // Perform target specific isel post processing. + InstructionSelectPostProcessing(DAG); DOUT << "Selected machine code:\n"; DEBUG(BB->dump()); -- cgit v1.2.3