summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-02-05 03:52:29 +0000
committerChris Lattner <sabre@nondot.org>2002-02-05 03:52:29 +0000
commitd30f989cdaf8e996c3c0f0497b50bff4bb649021 (patch)
tree9fafda92b0026b5d17fdf85ded5df7ab339bf487 /llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp
parentf1223ace96046e0cc768c2bffd8218cc4d6d7897 (diff)
downloadbcm5719-llvm-d30f989cdaf8e996c3c0f0497b50bff4bb649021.tar.gz
bcm5719-llvm-d30f989cdaf8e996c3c0f0497b50bff4bb649021.zip
* Code Cleanups
* Removal dependencies on Type.h & remove uses of getTypeID() llvm-svn: 1718
Diffstat (limited to 'llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp')
-rw-r--r--llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp26
1 files changed, 12 insertions, 14 deletions
diff --git a/llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp b/llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp
index 938ab1b8512..01e4879cf87 100644
--- a/llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp
+++ b/llvm/lib/CodeGen/RegAlloc/PhyRegAlloc.cpp
@@ -20,6 +20,7 @@
#include "llvm/Target/TargetMachine.h"
#include "llvm/Target/MachineFrameInfo.h"
#include "llvm/Method.h"
+#include "llvm/Type.h"
#include <iostream>
#include <math.h>
using std::cerr;
@@ -1164,22 +1165,19 @@ void PhyRegAlloc::markUnusableSugColors()
// this method allocate a new spill position on the stack.
//----------------------------------------------------------------------------
-void PhyRegAlloc::allocateStackSpace4SpilledLRs()
-{
- if(DEBUG_RA ) cerr << "\nsetting LR stack offsets ...\n";
+void PhyRegAlloc::allocateStackSpace4SpilledLRs() {
+ if (DEBUG_RA) cerr << "\nsetting LR stack offsets ...\n";
- // hash map iterator
- LiveRangeMapType::const_iterator HMI = (LRI.getLiveRangeMap())->begin();
- LiveRangeMapType::const_iterator HMIEnd = (LRI.getLiveRangeMap())->end();
+ LiveRangeMapType::const_iterator HMI = LRI.getLiveRangeMap()->begin();
+ LiveRangeMapType::const_iterator HMIEnd = LRI.getLiveRangeMap()->end();
- for( ; HMI != HMIEnd ; ++HMI ) {
- if(HMI->first && HMI->second) {
- LiveRange *L = HMI->second; // get the LiveRange
- if( ! L->hasColor() )
- // NOTE: ** allocating the size of long Type **
- L->setSpillOffFromFP(mcInfo.allocateSpilledValue(TM, Type::LongTy));
- }
- } // for all LR's in hash map
+ for( ; HMI != HMIEnd ; ++HMI) {
+ if (HMI->first && HMI->second) {
+ LiveRange *L = HMI->second; // get the LiveRange
+ if (!L->hasColor()) // NOTE: ** allocating the size of long Type **
+ L->setSpillOffFromFP(mcInfo.allocateSpilledValue(TM, Type::LongTy));
+ }
+ } // for all LR's in hash map
}
OpenPOWER on IntegriCloud