Fix PR5262: when folding select into PHI, make sure all operands are available
authorTorok Edwin <edwintorok@gmail.com>
Wed, 21 Oct 2009 10:49:00 +0000 (10:49 +0000)
committerTorok Edwin <edwintorok@gmail.com>
Wed, 21 Oct 2009 10:49:00 +0000 (10:49 +0000)
commit0739bd0ab2babc99f589cc8e88209b540c3732da
treeda6b6a03f699274e3296e41a37199b87416fd4d4
parent4e4bba5c80cc1168d244397f3fe09f301237638a
Fix PR5262: when folding select into PHI, make sure all operands are available
in the PHI's Basic Block. This uses a conservative approach, because we don't
have dominator info in instcombine.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84754 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/InstructionCombining.cpp
test/Transforms/InstCombine/crash.ll
test/Transforms/InstCombine/fold-intophi.ll [new file with mode: 0644]