[llvm] r196567 - Fix bug introduced in r196517.
Daniel Jasper
djasper at google.com
Fri Dec 6 00:58:22 PST 2013
Author: djasper
Date: Fri Dec 6 02:58:22 2013
New Revision: 196567
URL: http://llvm.org/viewvc/llvm-project?rev=196567&view=rev
Log:
Fix bug introduced in r196517.
Not only does it trigger -Wparentheses, I think the assert actually
relies on incorrect operator precedence.
Also, the grammar as questionable, but I might not know enough about the
problem at hand.
Modified:
llvm/trunk/lib/CodeGen/MachineScheduler.cpp
Modified: llvm/trunk/lib/CodeGen/MachineScheduler.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineScheduler.cpp?rev=196567&r1=196566&r2=196567&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineScheduler.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineScheduler.cpp Fri Dec 6 02:58:22 2013
@@ -2175,8 +2175,9 @@ void GenericScheduler::SchedBoundary::bu
// exceed the issue width.
const MCSchedClassDesc *SC = DAG->getSchedClass(SU);
unsigned IncMOps = SchedModel->getNumMicroOps(SU->getInstr());
- assert(CurrMOps == 0 || (CurrMOps + IncMOps) <= SchedModel->getIssueWidth() &&
- "Cannot scheduling this instructions MicroOps in the current cycle.");
+ assert(
+ (CurrMOps == 0 || (CurrMOps + IncMOps) <= SchedModel->getIssueWidth()) &&
+ "Cannot schedule this instructions MicroOps in the current cycle.");
unsigned ReadyCycle = (isTop() ? SU->TopReadyCycle : SU->BotReadyCycle);
DEBUG(dbgs() << " Ready @" << ReadyCycle << "c\n");
More information about the llvm-commits
mailing list