[PATCH] D18443: [Verifier] Reject PHIs using definitions from own block.

Sanjoy Das via llvm-commits llvm-commits at lists.llvm.org
Sat Mar 26 11:44:28 PDT 2016

sanjoy accepted this revision.
This revision is now accepted and ready to land.

Comment at: lib/IR/Verifier.cpp:3402
@@ +3401,3 @@
+  // unless it is a PHI node that never can use defs from its own block
+  // (eg. other PHIs)
+  if (!isa<PHINode>(I) && InstsInThisBlock.count(Op))
Nit: missing period.

Comment at: test/Transforms/LoopVectorize/phi-hang.ll:3
@@ -2,3 +2,3 @@
 ; PR15384
 define void @test1(i32 %arg) {
Meinersbur wrote:
> I assumed it would be a test for non-strict phi nodes, the PR doesn't mention anything specific. So I looked up the commit message of r176366 which says:
> > LoopVectorize: Don't hang forever if a PHI only has skipped PHI uses.
> so I changed %tmp6 to %tmp to see whether it still hangs in 176365 and it does. I am therefore assuming the %tmp6 was unintentional.
Great, thanks for doing all this!


More information about the llvm-commits mailing list