[PATCH] D85954: [InstCombine] Move handling of gc.relocate in a gc.statepoint

Serguei Katkov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 13 20:27:16 PDT 2020


skatkov created this revision.
skatkov added reviewers: reames, dantrushin.
Herald added a subscriber: hiraditya.
Herald added a project: LLVM.
skatkov requested review of this revision.

The only def for gc.relocate is a gc.statepoint. But real dependency is not
described by def-use chain. Instead this dependency is encoded by indecies
of operands in gc-live bundle of statepoint as integer constants in gc.relocate.

InstCombine operates by def-use chain. As a result when value in gc-live bundle
is simplified the gc.statepoint itself is not simplified but it might simplify dependent
gc.relocates. To trigger the optimization of gc.relocate we now unconditionally trigger
check of all dependent gc.relocates by adding them to worklist.

This CL handles of gc.relocates as process of gc.statepoint optimization considering
gc.statepoint and related gc.relocate as whole entity.


https://reviews.llvm.org/D85954

Files:
  llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D85954.285549.patch
Type: text/x-patch
Size: 5992 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200814/fa09da23/attachment.bin>


More information about the llvm-commits mailing list