mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-29 12:20:10 +01:00
nir: gather dual slot input information
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25394>
This commit is contained in:
parent
cb66fddd81
commit
b1bbe4e190
3 changed files with 6 additions and 0 deletions
|
|
@ -508,6 +508,8 @@ gather_intrinsic_info(nir_intrinsic_instr *instr, nir_shader *shader,
|
|||
shader->info.patch_inputs_read_indirectly |= slot_mask;
|
||||
} else {
|
||||
shader->info.inputs_read |= slot_mask;
|
||||
if (nir_intrinsic_io_semantics(instr).high_dvec2)
|
||||
shader->info.dual_slot_inputs |= slot_mask;
|
||||
shader->info.inputs_read_16bit |= slot_mask_16bit;
|
||||
if (!nir_src_is_const(*nir_get_io_offset_src(instr))) {
|
||||
shader->info.inputs_read_indirectly |= slot_mask;
|
||||
|
|
@ -926,6 +928,7 @@ nir_shader_gather_info(nir_shader *shader, nir_function_impl *entrypoint)
|
|||
}
|
||||
|
||||
shader->info.inputs_read = 0;
|
||||
shader->info.dual_slot_inputs = 0;
|
||||
shader->info.outputs_written = 0;
|
||||
shader->info.outputs_read = 0;
|
||||
shader->info.inputs_read_16bit = 0;
|
||||
|
|
|
|||
|
|
@ -2397,6 +2397,7 @@ print_shader_info(const struct shader_info *info, FILE *fp)
|
|||
print_nz_unsigned(fp, "num_images", info->num_images);
|
||||
|
||||
print_nz_x64(fp, "inputs_read", info->inputs_read);
|
||||
print_nz_x64(fp, "dual_slot_inputs", info->dual_slot_inputs);
|
||||
print_nz_x64(fp, "outputs_written", info->outputs_written);
|
||||
print_nz_x64(fp, "outputs_read", info->outputs_read);
|
||||
|
||||
|
|
|
|||
|
|
@ -167,6 +167,8 @@ typedef struct shader_info {
|
|||
|
||||
/* Which inputs are actually read */
|
||||
uint64_t inputs_read;
|
||||
/* Which inputs occupy 2 slots. */
|
||||
uint64_t dual_slot_inputs;
|
||||
/* Which outputs are actually written */
|
||||
uint64_t outputs_written;
|
||||
/* Which outputs are actually read */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue