[llvm] r279497 - [lanai] Exit early in Mem Alu combiner if sentinel reach.
Jacques Pienaar via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 22 18:04:41 PDT 2016
Author: jpienaar
Date: Mon Aug 22 20:04:41 2016
New Revision: 279497
URL: http://llvm.org/viewvc/llvm-project?rev=279497&view=rev
Log:
[lanai] Exit early in Mem Alu combiner if sentinel reach.
LanaiMemAluCombiner could try to query the debug value of a list sentinel. Add check to exit early instead.
Modified:
llvm/trunk/lib/Target/Lanai/LanaiMemAluCombiner.cpp
Modified: llvm/trunk/lib/Target/Lanai/LanaiMemAluCombiner.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Lanai/LanaiMemAluCombiner.cpp?rev=279497&r1=279496&r2=279497&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Lanai/LanaiMemAluCombiner.cpp (original)
+++ llvm/trunk/lib/Target/Lanai/LanaiMemAluCombiner.cpp Mon Aug 22 20:04:41 2016
@@ -339,6 +339,9 @@ MbbIterator LanaiMemAluCombiner::findClo
while (First != Last) {
Decrement ? --First : ++First;
+ if (First == Last)
+ break;
+
// Skip over debug instructions
if (First->isDebugValue())
continue;
More information about the llvm-commits
mailing list