[PATCH] D102212: [AMDGPU] Add Optimize VGPR LiveRange Pass.
Ruiling, Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 10 20:17:56 PDT 2021
ruiling created this revision.
ruiling added reviewers: arsenm, foad, critson, piotr.
Herald added subscribers: kerbowa, hiraditya, t-tye, tpr, dstuttard, yaxunl, mgorny, nhaehnle, jvesely, kzhuravl, MatzeB.
ruiling requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.
This pass aims to optimize VGPR live-range in a typical divergent if-else
control flow. For example:
def(a)
if(cond)
use(a)
... // A
else
use(a)
As AMDGPU access vgpr with respect to active-mask, we can mark `a` as
dead in region A. For details, please refer to the comments in
implementation file.
The pass is disabled by default, the frontend can enable it through
"-amdgpu-opt-vgpr-liverange=true".
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D102212
Files:
llvm/lib/Target/AMDGPU/AMDGPU.h
llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
llvm/lib/Target/AMDGPU/CMakeLists.txt
llvm/lib/Target/AMDGPU/SIOptimizeVGPRLiveRange.cpp
llvm/test/CodeGen/AMDGPU/vgpr-liverange.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D102212.344279.patch
Type: text/x-patch
Size: 29334 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210511/8d68addc/attachment.bin>
More information about the llvm-commits
mailing list