diff options
author | Andrew Kaylor <andrew.kaylor@intel.com> | 2016-02-08 22:52:51 +0000 |
---|---|---|
committer | Andrew Kaylor <andrew.kaylor@intel.com> | 2016-02-08 22:52:51 +0000 |
commit | 1224488e0cabe25c462642ba4639b3fe71b3b4f1 (patch) | |
tree | 393228950c5c514b56a79a4d4255ae1da515232f /llvm/lib/CodeGen/CalcSpillWeights.cpp | |
parent | 52f6c262d9dc09948b1395c7e3133ddcf59ed09d (diff) | |
download | bcm5719-llvm-1224488e0cabe25c462642ba4639b3fe71b3b4f1.tar.gz bcm5719-llvm-1224488e0cabe25c462642ba4639b3fe71b3b4f1.zip |
[regalloc][WinEH] Do not mark intervals as not spillable if they contain a regmask
Differential Revision: http://reviews.llvm.org/D16831
llvm-svn: 260164
Diffstat (limited to 'llvm/lib/CodeGen/CalcSpillWeights.cpp')
-rw-r--r-- | llvm/lib/CodeGen/CalcSpillWeights.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/CalcSpillWeights.cpp b/llvm/lib/CodeGen/CalcSpillWeights.cpp index abc655ac34c..26aa46fb6c2 100644 --- a/llvm/lib/CodeGen/CalcSpillWeights.cpp +++ b/llvm/lib/CodeGen/CalcSpillWeights.cpp @@ -213,8 +213,11 @@ VirtRegAuxInfo::calculateSpillWeightAndHint(LiveInterval &li) { if (!Spillable) return; - // Mark li as unspillable if all live ranges are tiny. - if (li.isZeroLength(LIS.getSlotIndexes())) { + // Mark li as unspillable if all live ranges are tiny and the interval + // is not live at any reg mask. If the interval is live at a reg mask + // spilling may be required. + if (li.isZeroLength(LIS.getSlotIndexes()) && + !li.isLiveAtIndexes(LIS.getRegMaskSlots())) { li.markNotSpillable(); return; } |