mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
nir: fix gathering patch IO usage with lowered IO
Fixes: 17af07024d - nir: gather all IO info from IO intrinsics
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7622>
This commit is contained in:
parent
aadfdb962f
commit
e78c089aae
1 changed files with 12 additions and 0 deletions
|
|
@ -313,7 +313,19 @@ gather_intrinsic_info(nir_intrinsic_instr *instr, nir_shader *shader,
|
|||
if (nir_intrinsic_infos[instr->intrinsic].index_map[NIR_INTRINSIC_IO_SEMANTICS] > 0) {
|
||||
nir_io_semantics semantics = nir_intrinsic_io_semantics(instr);
|
||||
|
||||
if (semantics.location >= VARYING_SLOT_PATCH0) {
|
||||
/* Generic per-patch I/O. */
|
||||
assert((shader->info.stage == MESA_SHADER_TESS_EVAL &&
|
||||
instr->intrinsic == nir_intrinsic_load_input) ||
|
||||
(shader->info.stage == MESA_SHADER_TESS_CTRL &&
|
||||
(instr->intrinsic == nir_intrinsic_load_output ||
|
||||
instr->intrinsic == nir_intrinsic_store_output)));
|
||||
|
||||
semantics.location -= VARYING_SLOT_PATCH0;
|
||||
}
|
||||
|
||||
slot_mask = BITFIELD64_RANGE(semantics.location, semantics.num_slots);
|
||||
assert(util_bitcount64(slot_mask) == semantics.num_slots);
|
||||
}
|
||||
|
||||
switch (instr->intrinsic) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue