Commit 6914c06
authored
[WaveTransform] Fine-tune shouldCoalesce target hook (#705)
With upstream PR 168988 the AMDGPU-specific implementation of
shouldCoalesce has been removed and the default implementation is now
used during register coalescing.
In the wave-transform pipeline, the coalescer is invoked twice. First
invocation is immediately after the two-address instruction pass and the
next one after the wave-transform pass. This ensure that the scalar
registers and the WWM values are not coalesced before the wave
transform. It gives us an upper hand as the wave-transform pass may
insert additional SGPR copies which can then be optimized by the second
coalescer invocation.
To achieve this a register class based filtering mechanism is already
available in the feature branch. However, at this stage, the WWM virtual
registers are not introduced before SGPR spill lowering, so the
filtering for them can be safely removed. We should reinstate this check
when WWM values are introduced earlier in the pipeline.1 parent 91f1bb6 commit 6914c06
1 file changed
+8
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3968 | 3968 | | |
3969 | 3969 | | |
3970 | 3970 | | |
3971 | | - | |
3972 | | - | |
3973 | | - | |
3974 | | - | |
3975 | | - | |
3976 | | - | |
3977 | | - | |
3978 | | - | |
3979 | | - | |
3980 | | - | |
3981 | | - | |
3982 | | - | |
3983 | | - | |
3984 | | - | |
3985 | | - | |
3986 | | - | |
3987 | | - | |
3988 | | - | |
3989 | | - | |
3990 | | - | |
| 3971 | + | |
| 3972 | + | |
| 3973 | + | |
| 3974 | + | |
| 3975 | + | |
| 3976 | + | |
| 3977 | + | |
| 3978 | + | |
3991 | 3979 | | |
3992 | 3980 | | |
3993 | 3981 | | |
| |||
0 commit comments