[PATCH] D144162: [AMDGPU] Replace LegacyDA with Uniformity Analysis in AnnotateUniformValues
Anshil Gandhi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 28 08:28:04 PST 2023
gandhi21299 added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUAnnotateUniformValues.cpp:81
void AMDGPUAnnotateUniformValues::visitBranchInst(BranchInst &I) {
- if (DA->isUniform(&I))
+ if (!UA->hasDivergentTerminator(*I.getParent()))
setUniformMetadata(&I);
----------------
foad wrote:
> sameerds wrote:
> > sameerds wrote:
> > > I am not sure we should be doing this. Smells like a bug in the UA!
> > D144699 allows the original "isUniform()" call to work as expected on a BranchInst.
> Did you mean to change this back to `isUniform`? (I don't really mind either way.)
Yea I meant to change this back, great catch!
================
Comment at: llvm/test/CodeGen/AMDGPU/i1-copy-from-loop.ll:28
; SI-NEXT: s_cmp_gt_u32 s14, 3
-; SI-NEXT: s_cbranch_scc1 .LBB0_1
+; SI-NEXT: s_cselect_b64 s[12:13], -1, 0
+; SI-NEXT: s_and_b64 vcc, exec, s[12:13]
----------------
foad wrote:
> This is a regression.
Should I handle all the regressions in a seperate patch?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144162/new/
https://reviews.llvm.org/D144162
More information about the llvm-commits
mailing list