[PATCH] D144254: [llvm][Uniformity] a phi with an undef argument is not always divergent
Sameer Sahasrabuddhe via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 17 03:47:35 PST 2023
sameerds created this revision.
Herald added subscribers: kosarev, kerbowa, hiraditya, jvesely.
Herald added a project: All.
sameerds requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
The uniformity analysis treated an undef argument to phi to be distinct from any
other argument, equivalent to calling PHINode::hasConstantValue() instead of
PHINode::hasConstantOrUndefValue(). Such a phi was reported as divergent. This
is different from the older divergence analysis which treats such a phi as
uniform. Fixed uniformity analysis to match the older behaviour.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D144254
Files:
llvm/include/llvm/ADT/GenericSSAContext.h
llvm/include/llvm/ADT/GenericUniformityImpl.h
llvm/include/llvm/CodeGen/MachineSSAContext.h
llvm/include/llvm/IR/SSAContext.h
llvm/lib/CodeGen/MachineSSAContext.cpp
llvm/lib/IR/SSAContext.cpp
llvm/test/Analysis/DivergenceAnalysis/AMDGPU/phi-undef.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D144254.498311.patch
Type: text/x-patch
Size: 5954 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230217/b2c9aefe/attachment.bin>
More information about the llvm-commits
mailing list