mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-22 04:10:40 +01:00
aco/gfx12: disable vinterp ddx/ddy optimization
This only seems to work on gfx11 and gfx11.5, and it's only faster on gfx11.5. We could continue to use vinterp, with constants copied to vgprs, but whether that's beneficial depends on the shader. Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Fixes:bee487df48("aco/gfx11.5+: use vinterp for fddx/fddy") Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/12250 (cherry picked from commit7425e71ae0) Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32730>
This commit is contained in:
parent
10f599a8b3
commit
f750108aa9
2 changed files with 6 additions and 2 deletions
|
|
@ -234,7 +234,7 @@
|
|||
"description": "aco/gfx12: disable vinterp ddx/ddy optimization",
|
||||
"nominated": true,
|
||||
"nomination_type": 2,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "bee487df48b19fc3bf792874aa6aff25104e281a",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -8603,8 +8603,12 @@ visit_intrinsic(isel_context* ctx, nir_intrinsic_instr* instr)
|
|||
} else {
|
||||
aco_opcode subrev =
|
||||
instr->def.bit_size == 16 ? aco_opcode::v_subrev_f16 : aco_opcode::v_subrev_f32;
|
||||
|
||||
/* v_interp with constant sources only works on GFX11/11.5,
|
||||
* and it's only faster on GFX11.5.
|
||||
*/
|
||||
bool use_interp = dpp_ctrl1 == dpp_quad_perm(0, 0, 0, 0) && instr->def.bit_size == 32 &&
|
||||
ctx->program->gfx_level >= GFX11_5;
|
||||
ctx->program->gfx_level == GFX11_5;
|
||||
if (!nir_src_is_divergent(&instr->src[0])) {
|
||||
bld.vop2(subrev, Definition(dst), src, src);
|
||||
} else if (use_interp && dpp_ctrl2 == dpp_quad_perm(1, 1, 1, 1)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue