[AMDGPU] Fix adjustWritemask subreg handling
authorStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Wed, 23 Dec 2020 22:15:23 +0000 (14:15 -0800)
committerStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Wed, 23 Dec 2020 22:43:31 +0000 (14:43 -0800)
commit747f67e034a924cf308f4c0f1bb6b1fa46bd9fbe
treeec0709e06dece1a769af09ae373c9e83a1843584
parentbe89d7460b63508a6a277050395c14a4fa74b031
[AMDGPU] Fix adjustWritemask subreg handling

If we happen to extract a non-dword subreg that breaks the
logic of the function and it may shrink the dmask because
it does not recognize the use of a lane(s).

This bug is next to impossible to trigger with the current
lowering in the BE, but it breaks in one of my future patches.

Differential Revision: https://reviews.llvm.org/D93782
llvm/lib/Target/AMDGPU/SIISelLowering.cpp