mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-02 16:38:09 +02:00
nir: drop printf_base_identifier
superseded. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33380>
This commit is contained in:
parent
e3bc6eafc8
commit
bf48eae1f9
6 changed files with 1 additions and 18 deletions
|
|
@ -6864,7 +6864,6 @@ bool nir_lower_helper_writes(nir_shader *shader, bool lower_plain_stores);
|
|||
typedef struct nir_lower_printf_options {
|
||||
unsigned max_buffer_size;
|
||||
unsigned ptr_bit_size;
|
||||
bool use_printf_base_identifier;
|
||||
bool hash_format_strings;
|
||||
} nir_lower_printf_options;
|
||||
|
||||
|
|
|
|||
|
|
@ -348,7 +348,6 @@ visit_intrinsic(nir_intrinsic_instr *instr, struct divergence_state *state)
|
|||
case nir_intrinsic_load_polygon_stipple_buffer_amd:
|
||||
case nir_intrinsic_load_printf_buffer_address:
|
||||
case nir_intrinsic_load_printf_buffer_size:
|
||||
case nir_intrinsic_load_printf_base_identifier:
|
||||
case nir_intrinsic_load_core_id_agx:
|
||||
case nir_intrinsic_load_samples_log2_agx:
|
||||
case nir_intrinsic_load_active_subgroup_count_agx:
|
||||
|
|
|
|||
|
|
@ -1285,10 +1285,6 @@ intrinsic("printf", src_comp=[1, 1], dest_comp=1, bit_sizes=[32])
|
|||
# the driver to at least provide a base location and size
|
||||
system_value("printf_buffer_address", 1, bit_sizes=[32,64])
|
||||
system_value("printf_buffer_size", 1, bit_sizes=[32])
|
||||
# If driver wants to have all printfs from various shaders merged into a
|
||||
# single output buffer, it needs each shader to have its own base identifier
|
||||
# from which each printf is indexed.
|
||||
system_value("printf_base_identifier", 1, bit_sizes=[32])
|
||||
# Abort the program, triggering device fault. The invoking thread halts
|
||||
# immediately. Other threads eventually terminate.
|
||||
#
|
||||
|
|
|
|||
|
|
@ -69,11 +69,7 @@ lower_printf_intrin(nir_builder *b, nir_intrinsic_instr *prntf, void *_options)
|
|||
}
|
||||
|
||||
nir_def *fmt_str_id = prntf->src[0].ssa;
|
||||
if (options->use_printf_base_identifier) {
|
||||
fmt_str_id = nir_iadd(b,
|
||||
nir_load_printf_base_identifier(b),
|
||||
fmt_str_id);
|
||||
} else if (options->hash_format_strings) {
|
||||
if (options->hash_format_strings) {
|
||||
/* Rather than store the index of the format string, instead store the
|
||||
* hash of the format string itself. This is invariant across shaders
|
||||
* which may be more convenient.
|
||||
|
|
|
|||
|
|
@ -669,7 +669,6 @@ fn compile_nir_to_args(
|
|||
|
||||
let printf_opts = nir_lower_printf_options {
|
||||
ptr_bit_size: 0,
|
||||
use_printf_base_identifier: false,
|
||||
hash_format_strings: false,
|
||||
max_buffer_size: dev.printf_buffer_size() as u32,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -40,12 +40,6 @@ lower_printf_intrinsics(nir_builder *b, nir_intrinsic_instr *intrin, void *_)
|
|||
nir_load_reloc_const_intel(b, BRW_SHADER_RELOC_PRINTF_BUFFER_ADDR_HIGH)));
|
||||
return true;
|
||||
|
||||
case nir_intrinsic_load_printf_base_identifier:
|
||||
nir_def_replace(
|
||||
&intrin->def,
|
||||
nir_load_reloc_const_intel(b, BRW_SHADER_RELOC_PRINTF_BASE_IDENTIFIER));
|
||||
return true;
|
||||
|
||||
case nir_intrinsic_load_printf_buffer_size:
|
||||
nir_def_replace(
|
||||
&intrin->def,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue