ac/nir/nggc: Don't stop applying reusable variables at prim export.
This was a mistake that prevented reusing variables in shaders with late primitive export. Fossil DB stats on Sienna Cichlid with NGGC on: Totals from 6547 (5.09% of 128647) affected shaders: VGPRs: 323368 -> 323824 (+0.14%); split: -0.03%, +0.18% SpillSGPRs: 45 -> 4865 (+10711.11%) CodeSize: 34208732 -> 33855952 (-1.03%); split: -1.21%, +0.18% MaxWaves: 142538 -> 142456 (-0.06%); split: +0.04%, -0.09% Instrs: 6654252 -> 6606432 (-0.72%); split: -0.89%, +0.17% Latency: 30527770 -> 30452769 (-0.25%); split: -0.42%, +0.18% InvThroughput: 5604540 -> 5609450 (+0.09%); split: -0.04%, +0.13% VClause: 121531 -> 120448 (-0.89%); split: -1.17%, +0.27% SClause: 195388 -> 177902 (-8.95%); split: -9.14%, +0.19% Copies: 617949 -> 636397 (+2.99%); split: -0.44%, +3.42% Branches: 228184 -> 228281 (+0.04%); split: -0.09%, +0.13% PreSGPRs: 271395 -> 343555 (+26.59%); split: -0.01%, +26.60% PreVGPRs: 277650 -> 277710 (+0.02%); split: -0.01%, +0.03% Signed-off-by: Timur Kristóf <timur.kristof@gmail.com> Reviewed-by: Daniel Schürmann <daniel@schuermann.dev> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12246>
This commit is contained in:
parent
59de9620b4
commit
02bba6aab5
|
@ -840,8 +840,7 @@ apply_reusable_variables(nir_builder *b, lower_ngg_nogs_state *nogs_state)
|
|||
/* When we found any of these intrinsics, it means
|
||||
* we reached the top part and we must stop.
|
||||
*/
|
||||
if (intrin->intrinsic == nir_intrinsic_alloc_vertices_and_primitives_amd ||
|
||||
intrin->intrinsic == nir_intrinsic_export_primitive_amd)
|
||||
if (intrin->intrinsic == nir_intrinsic_alloc_vertices_and_primitives_amd)
|
||||
goto done;
|
||||
|
||||
if (intrin->intrinsic != nir_intrinsic_store_deref)
|
||||
|
|
Loading…
Reference in New Issue