[PATCH] D127829: NFC: restructure code for CreateControlFlowHub()

Ruiling, Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 15 00:11:50 PDT 2022


ruiling created this revision.
ruiling added reviewers: sameerds, bcahoon.
Herald added a subscriber: hiraditya.
Herald added a project: All.
ruiling requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This is just moving code around to make it easy to follow and prepare
for the next change to reduce number of live values.

BasicBlockUtils: Add a new way for CreateControlFlowHub()

The existing way of creating the predicate in the guard blocks is using
a boolean value per outgoing block. This would be increase the number of
live booleans as we are having more outgoing blocks. The new way added in
this change is to store one integer to represent the outgoing block we
want to branch to, then at each guard block, an integer equality check
will be performed to decide which a specific outgoing block will be
taken.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D127829

Files:
  llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
  llvm/lib/Transforms/Utils/UnifyLoopExits.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D127829.437055.patch
Type: text/x-patch
Size: 14332 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220615/ffdaa436/attachment.bin>


More information about the llvm-commits mailing list