[InstCombine] allow fdiv with constant dividend folds with less than full -ffast...
authorSanjay Patel <spatel@rotateright.com>
Mon, 19 Feb 2018 21:46:52 +0000 (21:46 +0000)
committerSanjay Patel <spatel@rotateright.com>
Mon, 19 Feb 2018 21:46:52 +0000 (21:46 +0000)
commit1d14779aed200632328b38b04a89575b0a89c38b
tree44adc1b1490c79508a8ff0d75ac581ea08f499e7
parent49a9d1a4e6f06299f6c87d693e585d388808f643
[InstCombine] allow fdiv with constant dividend folds with less than full -ffast-math

It's possible that we could allow this either 'arcp' or 'reassoc' alone, but this
should be conservatively better than what we have right now. GCC allows this with
only -freciprocal-math.

The last test is changed to show a case that is expected to fold, but we need D43398.

llvm-svn: 325533
llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
llvm/test/Transforms/InstCombine/fdiv.ll