[llvm] r175961 - Make some fixes for LiveInterval repair with debug info. Debug value
David Blaikie
dblaikie at gmail.com
Sat Feb 23 12:26:50 PST 2013
On Sat, Feb 23, 2013 at 12:23 PM, Cameron Zwarich <zwarich at apple.com> wrote:
> This code isn't yet enabled by default yet.
>
It can be enabled with a flag?
> Running it on test-suite with -g caused assertions to fail, so I assumed
> that was good enough.
>
Generally we prefer to have regression tests checked in with code changes -
the test suite is used to catch things we failed to test but we take the
opportunity to fix/improve the regression test coverage when the test-suite
uncovers something.
>
>
> Cameron
>
> On Feb 23, 2013, at 10:43 AM, David Blaikie <dblaikie at gmail.com> wrote:
>
>
>
>
> On Sat, Feb 23, 2013 at 2:25 AM, Cameron Zwarich <zwarich at apple.com>wrote:
>
>> Author: zwarich
>> Date: Sat Feb 23 04:25:25 2013
>> New Revision: 175961
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=175961&view=rev
>> Log:
>> Make some fixes for LiveInterval repair with debug info. Debug value
>> MachineInstrs don't have a slot index.
>>
>> Modified:
>> llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
>> llvm/trunk/lib/CodeGen/SlotIndexes.cpp
>>
>
> test cases?
>
>
>>
>> Modified: llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
>> URL:
>> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp?rev=175961&r1=175960&r2=175961&view=diff
>>
>> ==============================================================================
>> --- llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp (original)
>> +++ llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp Sat Feb 23 04:25:25
>> 2013
>> @@ -1056,6 +1056,8 @@ LiveIntervals::repairIntervalsInRange(Ma
>> for (MachineBasicBlock::iterator I = End; I != Begin;) {
>> --I;
>> MachineInstr *MI = I;
>> + if (MI->isDebugValue())
>> + continue;
>> for (MachineInstr::const_mop_iterator MOI = MI->operands_begin(),
>> MOE = MI->operands_end(); MOI != MOE; ++MOI) {
>> if (MOI->isReg() &&
>> @@ -1087,8 +1089,10 @@ LiveIntervals::repairIntervalsInRange(Ma
>> for (MachineBasicBlock::iterator I = End; I != Begin;) {
>> --I;
>> MachineInstr *MI = I;
>> - SlotIndex instrIdx = getInstructionIndex(MI);
>> + if (MI->isDebugValue())
>> + continue;
>>
>> + SlotIndex instrIdx = getInstructionIndex(MI);
>> bool isStartValid = getInstructionFromIndex(LII->start);
>> bool isEndValid = getInstructionFromIndex(LII->end);
>>
>>
>> Modified: llvm/trunk/lib/CodeGen/SlotIndexes.cpp
>> URL:
>> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SlotIndexes.cpp?rev=175961&r1=175960&r2=175961&view=diff
>>
>> ==============================================================================
>> --- llvm/trunk/lib/CodeGen/SlotIndexes.cpp (original)
>> +++ llvm/trunk/lib/CodeGen/SlotIndexes.cpp Sat Feb 23 04:25:25 2013
>> @@ -208,7 +208,7 @@ void SlotIndexes::repairIndexesInRange(M
>> for (MachineBasicBlock::iterator I = End; I != Begin;) {
>> --I;
>> MachineInstr *MI = I;
>> - if (mi2iMap.find(MI) == mi2iMap.end())
>> + if (!MI->isDebugValue() && mi2iMap.find(MI) == mi2iMap.end())
>> insertMachineInstrInMaps(MI);
>> }
>> }
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130223/a73c5f89/attachment.html>
More information about the llvm-commits
mailing list