]> granicus.if.org Git - llvm/commit
Fix invalid cast in instcombine UMul/ZExt idiom
authorSerge Guelton <sguelton@quarkslab.com>
Mon, 10 Jul 2017 16:51:40 +0000 (16:51 +0000)
committerSerge Guelton <sguelton@quarkslab.com>
Mon, 10 Jul 2017 16:51:40 +0000 (16:51 +0000)
commit65eefa7f01381abcf94b13fd5df5dc0e657b7c51
treece14ca6788738bed958739d7ecac966b237b341d
parentb6988767a83875c8d0a64a1c0ff9cdf962d556ab
Fix invalid cast in instcombine UMul/ZExt idiom

Fixes https://bugs.llvm.org/show_bug.cgi?id=25454

Do not assume IRBuilder creates Instruction where it can create Value.
Do not assume idiom operands are constant, leave generalisation ot the IRBuilder.

Differential Revision: https://reviews.llvm.org/D35114

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@307554 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCompares.cpp
test/Transforms/InstCombine/2017-07-07-UMul-ZExt.ll [new file with mode: 0644]