diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-12-21 19:50:05 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-12-21 19:50:05 +0000 |
commit | a2a98fd0ddd2ae277be7cdd62aae92f6c5155e07 (patch) | |
tree | 1b77ec8fedaf4f4680702ec8dff9bbc2ff660566 /lib/CodeGen/ExecutionDepsFix.cpp | |
parent | e6949b13997e6d31aa4719a0e80c4b6b405e42a9 (diff) |
Move common code into an MRI function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147071 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/ExecutionDepsFix.cpp')
-rw-r--r-- | lib/CodeGen/ExecutionDepsFix.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/CodeGen/ExecutionDepsFix.cpp b/lib/CodeGen/ExecutionDepsFix.cpp index 4ec75cdfec..c057c1bcdc 100644 --- a/lib/CodeGen/ExecutionDepsFix.cpp +++ b/lib/CodeGen/ExecutionDepsFix.cpp @@ -654,11 +654,10 @@ bool ExeDepsFix::runOnMachineFunction(MachineFunction &mf) { bool anyregs = false; for (TargetRegisterClass::const_iterator I = RC->begin(), E = RC->end(); I != E; ++I) - for (const unsigned *AI = TRI->getOverlaps(*I); *AI; ++AI) - if (MF->getRegInfo().isPhysRegUsed(*AI)) { - anyregs = true; - break; - } + if (MF->getRegInfo().isPhysRegOrOverlapUsed(*I)) { + anyregs = true; + break; + } if (!anyregs) return false; // Initialize the AliasMap on the first use. |