[PATCH] D39960: [InstCombine] In foldSelectOpOp reuse existing selects if present
John Brawn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 13 08:24:52 PST 2017
john.brawn created this revision.
Herald added a reviewer: dberlin.
Currently foldSelectOpOp only optimises selects where the operands have only one use, in order to avoid a proliferation of select instructions. If we can reuse an existing select then we can relax this constraint.
This kind of pattern can happen when GVN PRE phi translation introduces a phi then later both of the phis become selects.
Repository:
rL LLVM
https://reviews.llvm.org/D39960
Files:
lib/Transforms/InstCombine/InstCombineSelect.cpp
test/Transforms/InstCombine/select-reuse.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39960.122659.patch
Type: text/x-patch
Size: 4751 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171113/493cb876/attachment.bin>
More information about the llvm-commits
mailing list