mesa/src/intel
Paulo Zanoni 85751506ab elk: don't use instr->const_index[] directly
From what I understand, use of const_index[] by the driver is
dangerous and should be avoided, as commits such as a6330ed4d0
("nir: add ACCESS to load_uniforms") may result in the indexes
changing, breaking the driver. Switch to using the parameter names in
order to make the code more future-proof.

For elk_fs_nir.cpp and elk_vec4_tes.cpp we can verify in the generated
nir_intrinsics.c that the wanted value is actually
nir_intrinsic_base().

For elk_nir.c, according to Caio Oliveira:

  "The code is checking for certain load/store via the is_input() and
   is_output() checks a few lines above. I've checked all them have
   BASE at 0."

Thanks to Ian Romanick for his guidance regarding this patch.

Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39438>
2026-03-10 01:03:42 +00:00
..
blorp intel/blorp: drop unused BLORP_BATCH_COMPUTE_ENGINE flag 2026-03-06 20:42:05 +00:00
ci intel/ci: Document recent Intel flakes 2026-03-09 17:42:03 +00:00
common intel/l3: Add Xe3P (GFX_VERx10==350) 2026-03-04 11:10:34 -08:00
compiler elk: don't use instr->const_index[] directly 2026-03-10 01:03:42 +00:00
decoder intel/decoder: update warning message when buildtype=release 2026-03-09 20:01:01 +00:00
dev intel/dev: Add NVL-P PCI IDs (with FORCE_PROBE required) 2026-03-06 19:01:06 +00:00
ds intel: Include available counter descriptions in the perfetto counter spec 2026-03-06 08:47:16 +00:00
executor meson: make dep_lua a disabler 2025-11-21 21:48:57 +00:00
genxml intel/genxml: Add gen125_rt.xml to default_imports in intel_genxml.py 2026-03-04 10:08:41 -08:00
isl intel/isl: Build for Xe3P (GFX_VERx10 == 350) 2026-03-04 11:10:34 -08:00
mda intel/mda: Use -W for color words diff and -U for regular unified diff 2026-01-28 22:11:11 +00:00
nullhw-layer build: avoid redefining unreachable() which is standard in C23 2025-07-31 17:49:42 +00:00
perf intel/perf: Add HSW verx10 to intel_perf_query_result_write_mdapi() 2026-02-23 18:00:52 +00:00
shaders intel/shaders: Build for Xe3P (GFX_VERx10 == 350) 2026-03-04 11:10:34 -08:00
tools intel/dev: Add URB min/max entries for Mesh and Task 2026-03-06 19:01:06 +00:00
vulkan anv: don't try to fast clear D/S with multiview 2026-03-09 22:49:05 +00:00
vulkan_hasvk hasvk: Advertise VK_KHR_maintenance6 2026-03-02 23:16:11 +00:00
meson.build brw: Move into a new src/intel/compiler/brw subdirectory 2025-10-09 07:01:47 +00:00