[llvm] r251885 - RegisterPressure: Improve assert message
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 2 17:53:36 PST 2015
Author: matze
Date: Mon Nov 2 19:53:36 2015
New Revision: 251885
URL: http://llvm.org/viewvc/llvm-project?rev=251885&view=rev
Log:
RegisterPressure: Improve assert message
Modified:
llvm/trunk/lib/CodeGen/RegisterPressure.cpp
Modified: llvm/trunk/lib/CodeGen/RegisterPressure.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/RegisterPressure.cpp?rev=251885&r1=251884&r2=251885&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/RegisterPressure.cpp (original)
+++ llvm/trunk/lib/CodeGen/RegisterPressure.cpp Mon Nov 2 19:53:36 2015
@@ -862,7 +862,8 @@ getUpwardPressureDelta(const MachineInst
unsigned MNew = MOld;
// Ignore DeadDefs here because they aren't captured by PressureChange.
unsigned PNew = POld + PDiffI->getUnitInc();
- assert((PDiffI->getUnitInc() >= 0) == (PNew >= POld) && "PSet overflow");
+ assert((PDiffI->getUnitInc() >= 0) == (PNew >= POld)
+ && "PSet overflow/underflow");
if (PNew > MOld)
MNew = PNew;
// Check if current pressure has exceeded the limit.
More information about the llvm-commits
mailing list