diff --git a/src/asahi/clc/asahi_clc.c b/src/asahi/clc/asahi_clc.c index 059160fccbb..826b874099f 100644 --- a/src/asahi/clc/asahi_clc.c +++ b/src/asahi/clc/asahi_clc.c @@ -98,8 +98,6 @@ compile(void *memctx, const uint32_t *spirv, size_t spirv_size) NIR_PASS(_, nir, nir_lower_printf, &(const struct nir_lower_printf_options){ - .buffer_address = LIBAGX_PRINTF_BUFFER_ADDRESS, - .max_buffer_size = LIBAGX_PRINTF_BUFFER_SIZE - 8, }); /* We have to lower away local constant initializers right before we diff --git a/src/asahi/compiler/agx_compile.c b/src/asahi/compiler/agx_compile.c index 07ca606844c..775d5e43aef 100644 --- a/src/asahi/compiler/agx_compile.c +++ b/src/asahi/compiler/agx_compile.c @@ -6,6 +6,7 @@ */ #include "agx_compile.h" +#include "asahi/clc/asahi_clc.h" #include "asahi/layout/layout.h" #include "compiler/nir/nir_builder.h" #include "util/bitset.h" @@ -3775,6 +3776,9 @@ agx_compile_shader_nir(nir_shader *nir, struct agx_shader_key *key, if (nir->info.stage == MESA_SHADER_FRAGMENT) info->tag_write_disable = !nir->info.writes_memory; + NIR_PASS(_, nir, nir_lower_printf_buffer, LIBAGX_PRINTF_BUFFER_ADDRESS, + LIBAGX_PRINTF_BUFFER_SIZE - 8); + bool needs_libagx = true /* TODO: Optimize */; NIR_PASS(_, nir, nir_lower_frag_coord_to_pixel_coord);