[PATCH] D44627: [CallSiteSplitting] Only record conditions up to the IDom(call site).

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 19 07:53:35 PDT 2018


fhahn created this revision.
fhahn added reviewers: davide, junbuml.

We can stop recording conditions once we reached the immediate dominator
for the block containing the call site. Conditions in predecessors of the
that node will be the same for all paths to the call site and splitting
is not beneficial.

This patch makes CallSiteSplitting dependent on the DT anlysis. because
the immediate dominators seem to be the easiest way of finding the node
to stop at.

I had to update some exiting tests, because they were checking for
conditions that were true/false on all paths to the call site.


https://reviews.llvm.org/D44627

Files:
  lib/Transforms/Scalar/CallSiteSplitting.cpp
  test/Transforms/CallSiteSplitting/callsite-split-or-phi.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44627.138927.patch
Type: text/x-patch
Size: 10127 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180319/925d2ae8/attachment.bin>


More information about the llvm-commits mailing list