[llvm] [AMDGPU] Use poison instead of undef for non-demanded elements (PR #75914)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 19 02:12:39 PST 2023


nikic wrote:

> > Are these docs public? I had a hard time finding information on what these intrinsics do.
> 
> Mostly yes. https://llvm.org/docs/AMDGPUUsage.html#additional-documentation links to the various ISA public documents (see the MIMG sections for dmask). The intrinsics for the most part directly map to the instructions of the same names. It covers dmask but sometimes unusual edge cases aren't mentioned in the public docs (like I don't see the 0 case mentioned here)

Thanks! Looking at the RDNA 3 docs, it does have a note on this as well:

> If DMASK==0, the TA overrides DMASK=1 and puts zeros in VGPR followed by LWE status if exists. TFE status is not generated since the fetch is dropped.

I went ahead and pushed a commit to skip simplification for the dmask==0 case entirely, as it has special semantics. Does that sound reasonable?

https://github.com/llvm/llvm-project/pull/75914


More information about the llvm-commits mailing list