aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/LiveIntervalAnalysis.cpp
diff options
context:
space:
mode:
authorJim Laskey <jlaskey@mac.com>2006-07-21 21:15:20 +0000
committerJim Laskey <jlaskey@mac.com>2006-07-21 21:15:20 +0000
commitcd4317efcf334be10d9a98008a1445d6e12a7712 (patch)
tree82f4e6381dbe6669926e797094654c0f430ed18c /lib/CodeGen/LiveIntervalAnalysis.cpp
parent60f09928a0d22d5927ff0a40fe9163cf1ba1014a (diff)
Eliminate data relocations by using NULL instead of global empty list.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29250 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveIntervalAnalysis.cpp')
-rw-r--r--lib/CodeGen/LiveIntervalAnalysis.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/CodeGen/LiveIntervalAnalysis.cpp b/lib/CodeGen/LiveIntervalAnalysis.cpp
index fba04670f2..9e0d5d2325 100644
--- a/lib/CodeGen/LiveIntervalAnalysis.cpp
+++ b/lib/CodeGen/LiveIntervalAnalysis.cpp
@@ -639,8 +639,10 @@ void LiveIntervals::computeIntervals()
DEBUG(std::cerr << getInstructionIndex(mi) << "\t" << *mi);
// handle implicit defs
- for (const unsigned* id = tid.ImplicitDefs; *id; ++id)
- handleRegisterDef(mbb, mi, *id);
+ if (tid.ImplicitDefs) {
+ for (const unsigned* id = tid.ImplicitDefs; *id; ++id)
+ handleRegisterDef(mbb, mi, *id);
+ }
// handle explicit defs
for (int i = mi->getNumOperands() - 1; i >= 0; --i) {