summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorVikram S. Adve <vadve@cs.uiuc.edu>2001-07-30 18:48:43 +0000
committerVikram S. Adve <vadve@cs.uiuc.edu>2001-07-30 18:48:43 +0000
commitda0c7d89bc4f6d0587f083ed8a0006da2043fea0 (patch)
treed7b99cf5f8d19fc5f5d04b9cff7f0ad0307dd2b0 /llvm
parent32b5d841bad8be0c2b9269629d70306b22c93895 (diff)
downloadbcm5719-llvm-da0c7d89bc4f6d0587f083ed8a0006da2043fea0.tar.gz
bcm5719-llvm-da0c7d89bc4f6d0587f083ed8a0006da2043fea0.zip
Record machine instructions in the vector for each basic block.
llvm-svn: 331
Diffstat (limited to 'llvm')
-rw-r--r--llvm/lib/CodeGen/InstrSelection/InstrSelection.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/InstrSelection/InstrSelection.cpp b/llvm/lib/CodeGen/InstrSelection/InstrSelection.cpp
index 9cc054ca4de..4b389b732ce 100644
--- a/llvm/lib/CodeGen/InstrSelection/InstrSelection.cpp
+++ b/llvm/lib/CodeGen/InstrSelection/InstrSelection.cpp
@@ -96,6 +96,20 @@ bool SelectInstructionsForMethod(Method* method, TargetMachine &Target) {
PrintMachineInstructions(method);
}
+ //
+ // Record instructions in the vector for each basic block
+ //
+ for (Method::iterator BI = method->begin(); BI != method->end(); ++BI)
+ {
+ MachineCodeForBasicBlock& bbMvec = (*BI)->getMachineInstrVec();
+ for (BasicBlock::iterator II = (*BI)->begin(); II != (*BI)->end(); ++II)
+ {
+ MachineCodeForVMInstr& mvec = (*II)->getMachineInstrVec();
+ for (unsigned i=0; i < mvec.size(); i++)
+ bbMvec.push_back(mvec[i]);
+ }
+ }
+
return false;
}
OpenPOWER on IntegriCloud