[PATCH] D73815: AMDGPU: Fix divergence analysis of control flow intrinsics

Alexander via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 4 08:49:28 PST 2020


alex-t added a comment.

In D73815#1857100 <https://reviews.llvm.org/D73815#1857100>, @arsenm wrote:

> In D73815#1857088 <https://reviews.llvm.org/D73815#1857088>, @alex-t wrote:
>
> > I agree that current expensive walk on IR should be removed. 
> >  I initially consider it as a temporary solution that allows to switch to the new concept 
> >  of assignment correct register classes keeping in mind to eventually find another way to workaround CF results exceptions.
> >
> > What I conceptually don't like here is mixing the "divergence" and register class notions.
> >  The mask produced by the CF intrinsics is always scalar - not same as always uniform.
>
>
> Scalar is the only modeled concept of uniform we have. We don't currently try to model workgroup uniform, so these should be the same


It should work if we can guarantee that the values produced by the CF intrinsics are only used by the another CF intrinsics.
I mean something like AND/OR the uniform mask with some divergent value and then feeding result to another CF...
but normally this should not happen.
Once again: I like getting rid of requiresUniformRegister but insist on the extended testing.
Also, the trouble with LCSSA use of the uniform mask out of the divergent loop need to be solved anyway.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73815/new/

https://reviews.llvm.org/D73815





More information about the llvm-commits mailing list