[PATCH] overzealous instcombine of fptrunc(OP(fpext(x), fpext(y)))
scanon at apple.com
Wed Nov 27 10:48:06 PST 2013
InstCombiner::visitFPTrunc is currently overzealous and does some "optimizations" that it shouldn't (because they change results). The attached patch reins it in so that we still get the benefit of this optimization for common cases, but we get rid of the misbehavior, and adds some test cases for situations where the optimization *shouldn't* happen.
Thanks to Pascal Quoc for bringing the issue to my attention (http://blog.frama-c.com/index.php?post/2013/09/25/The-problem-with-differential-testing-is-that-at-least-one-of-the-compilers-must-get-it-right).
This is also <rdar://problem/15080092>.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the llvm-commits