Commit 55b34c2
committed
[AMDGPU] Remove scope check in SIInsertWaitcnts::generateWaitcntInstBefore
This change was motivated by CK where many VMCNT(0)'s were generated due
to instructions lacking !alias.scope metadata. The two causes of this were
1) LowerLDSModule not tacking on scope metadata on a single LDS variable
2) IPSCCP pass before inliner replacing noalias ptr derivative with a
global value, which made inliner unable to track it back to the noalias
ptr argument.
However, it turns out that IPSCCP losing the scope information was largely
ineffectual as ScopedNoAliasAA was able to handle asymmetric condition,
where one MemLoc was missing scope, and still return NoAlias result.
AMDGPU however was checking for existence of scope in SIInsertWaitcnts and
conservatively treating it as aliasing all and inserted VMCNT(0) before
DS_READs, forcing it to wait for all previous LDS DMA instructions.
Since we know that ScopedNoAliasAA can handle asymmetry, we should also
allow AA query to determine if two MIs may alias.
Remove confusing comments, redundant check-prefix, move function attribute
turn into positive checks via script1 parent 8ae3aea commit 55b34c2
File tree
2 files changed
+1
-8
lines changed- llvm
- lib/Target/AMDGPU
- test/CodeGen/AMDGPU
2 files changed
+1
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1941 | 1941 | | |
1942 | 1942 | | |
1943 | 1943 | | |
1944 | | - | |
1945 | | - | |
1946 | | - | |
1947 | | - | |
1948 | | - | |
1949 | | - | |
1950 | | - | |
| 1944 | + | |
1951 | 1945 | | |
1952 | 1946 | | |
1953 | 1947 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
30 | 29 | | |
31 | 30 | | |
32 | 31 | | |
| |||
0 commit comments