]> granicus.if.org Git - llvm/commit
[InstCombine] Propagate fast math flags through selects
authorJay Foad <jay.foad@gmail.com>
Wed, 7 Aug 2019 15:16:28 +0000 (15:16 +0000)
committerJay Foad <jay.foad@gmail.com>
Wed, 7 Aug 2019 15:16:28 +0000 (15:16 +0000)
commitdc389f37ff12f9038f536af7788bc0c8189a8af3
treee37e9bfed3dacbf8896cc01c074bdce397420072
parent1401bc8ab174d9a25e502c7a301e837614598888
[InstCombine] Propagate fast math flags through selects

Summary:
In SimplifySelectsFeedingBinaryOp, propagate fast math flags from the
outer op into both arms of the new select, to take advantage of
simplifications that require fast math flags.

Reviewers: mcberg2017, majnemer, spatel, arsenm, xbolva00

Subscribers: wdng, javed.absar, kristof.beyls, hiraditya, llvm-commits

Tags: #llvm

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@368175 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstructionCombining.cpp
test/Transforms/InstCombine/select_arithmetic.ll