[PATCH] D121312: [IROutliner] Avoid reusing PHINodes that have already been matched when merging outlined functions' phi node blocks
Andrew Litteken via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 9 10:58:36 PST 2022
AndrewLitteken created this revision.
AndrewLitteken added a reviewer: paquette.
Herald added subscribers: ormris, hiraditya.
Herald added a project: All.
AndrewLitteken requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
https://godbolt.org/z/63r5hzKsT
When there are two external phi nodes for two different outlined regions, when compressing the created phi nodes between the two regions, the matching for the second phi node in the second region matches the first phi node created for the first region rather than the second phi node created for the first region. This adds an extra output path where there should not be one.
The fix is the ignore phi nodes that have already been matched for each region.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D121312
Files:
llvm/lib/Transforms/IPO/IROutliner.cpp
llvm/test/Transforms/IROutliner/duplicate-merging-phis.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D121312.414157.patch
Type: text/x-patch
Size: 7621 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220309/5335099b/attachment.bin>
More information about the llvm-commits
mailing list