mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-28 12:30:09 +01:00
nir: Unvendor sampler_lod_parameters(_pan)
Will be used by etnaviv too. Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com> Reviewed-by: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35753>
This commit is contained in:
parent
c25f612b56
commit
ec9a2aa2e4
4 changed files with 5 additions and 5 deletions
|
|
@ -1608,7 +1608,7 @@ intrinsic("load_frag_coord_zw_pan", [2], dest_comp=1, indices=[COMPONENT], flags
|
|||
|
||||
# Loads the sampler paramaters <min_lod, max_lod, lod_bias>
|
||||
# src[] = { sampler_index }
|
||||
load("sampler_lod_parameters_pan", [1], flags=[CAN_ELIMINATE, CAN_REORDER])
|
||||
load("sampler_lod_parameters", [1], flags=[CAN_ELIMINATE, CAN_REORDER])
|
||||
|
||||
# Like load_output but using a specified render target and conversion descriptor
|
||||
# src[] = { target, sample, conversion }
|
||||
|
|
|
|||
|
|
@ -348,7 +348,7 @@ pan_preload_get_blend_shaders(struct pan_fb_preload_cache *cache,
|
|||
|
||||
/*
|
||||
* Early Mali GPUs did not respect sampler LOD clamps or bias, so the Midgard
|
||||
* compiler inserts lowering code with a load_sampler_lod_parameters_pan sysval
|
||||
* compiler inserts lowering code with a load_sampler_lod_parameters sysval
|
||||
* that we need to lower. Our samplers do not use LOD clamps or bias, so we
|
||||
* lower to the identity settings and let constant folding get rid of the
|
||||
* unnecessary lowering.
|
||||
|
|
@ -357,7 +357,7 @@ static bool
|
|||
lower_sampler_parameters(nir_builder *b, nir_intrinsic_instr *intr,
|
||||
UNUSED void *data)
|
||||
{
|
||||
if (intr->intrinsic != nir_intrinsic_load_sampler_lod_parameters_pan)
|
||||
if (intr->intrinsic != nir_intrinsic_load_sampler_lod_parameters)
|
||||
return false;
|
||||
|
||||
const nir_const_value constants[4] = {
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ sysval_for_intrinsic(unsigned arch, nir_intrinsic_instr *intr, unsigned *offset)
|
|||
*offset = 8;
|
||||
return PAN_SYSVAL(SSBO, nir_src_as_uint(intr->src[0]));
|
||||
|
||||
case nir_intrinsic_load_sampler_lod_parameters_pan:
|
||||
case nir_intrinsic_load_sampler_lod_parameters:
|
||||
/* This is only used for a workaround on Mali-T720, where we don't
|
||||
* support dynamic samplers.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ nir_lod_errata_instr(nir_builder *b, nir_tex_instr *tex, void *data)
|
|||
nir_def *sampler = nir_imm_int(b, tex->texture_index);
|
||||
|
||||
/* Let's grab the sampler parameters */
|
||||
nir_def *params = nir_load_sampler_lod_parameters_pan(b, 3, 32, sampler);
|
||||
nir_def *params = nir_load_sampler_lod_parameters(b, 3, 32, sampler);
|
||||
|
||||
/* Extract the individual components */
|
||||
nir_def *min_lod = nir_channel(b, params, 0);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue