[PATCH] D127392: [InstCombine] Combine consecutive loads which are being merged to form a wider load.
Biplob Mishra via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 9 03:49:19 PDT 2022
bipmis created this revision.
bipmis added reviewers: dmgreen, spatel, RKSimon.
bipmis added projects: LLVM, All.
Herald added a subscriber: hiraditya.
bipmis requested review of this revision.
The patch simplifies some of the patterns as below
1. (zExt(L1) << shift1) | (zExt(L2) << shift2) -> zExt(L3) << shift1
2. (? | (zExt(L1) << shift1)) | (zExt(L2) << shift2) -> ? | (zExt(L3) << shift1)
The pattern is indicative of the fact that the loads are being merged to a wider load and the only use of this pattern is with a wider load. In this case for a non-atomic/non-volatile loads reduce the pattern to a combined load which would improve the cost of inlining, unrolling, vectorization etc.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D127392
Files:
llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
llvm/test/Transforms/InstCombine/or-load.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D127392.435486.patch
Type: text/x-patch
Size: 24620 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220609/40b058a9/attachment-0001.bin>
More information about the llvm-commits
mailing list