[InstCombine] check uses before creating instructions for fmul distribution
authorSanjay Patel <spatel@rotateright.com>
Mon, 26 Mar 2018 14:25:43 +0000 (14:25 +0000)
committerSanjay Patel <spatel@rotateright.com>
Mon, 26 Mar 2018 14:25:43 +0000 (14:25 +0000)
commit2455fef497a09cf358daf43ea910eb5a23542980
tree0fdae7187c3cba3d0ba732ad96908e62921b7814
parent67df1cf597974fdd0ec8828688e89acfc5862c49
[InstCombine] check uses before creating instructions for fmul distribution

As the tests show, we could create extra instructions without any obvious benefit.

llvm-svn: 328498
llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
llvm/test/Transforms/InstCombine/fmul.ll