static void
iris_debug_recompile(struct iris_context *ice,
- struct shader_info *info,
+ struct iris_uncompiled_shader *ish,
const struct brw_base_prog_key *key)
{
+ if (!ish)
+ return;
+
+ if (!ish->compiled_once) {
+ ish->compiled_once = true;
+ return;
+ }
+
struct iris_screen *screen = (struct iris_screen *) ice->ctx.screen;
const struct gen_device_info *devinfo = &screen->devinfo;
const struct brw_compiler *c = screen->compiler;
-
- if (!info)
- return;
+ const struct shader_info *info = &ish->nir->info;
c->shader_perf_log(&ice->dbg, "Recompiling %s shader for program %s: %s\n",
_mesa_shader_stage_to_string(info->stage),
return false;
}
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
uint32_t *so_decls =
screen->vtbl.create_so_decl_list(&ish->stream_output,
return false;
}
- if (ish) {
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_TCS, sizeof(*key), key, program,
return false;
}
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
uint32_t *so_decls =
screen->vtbl.create_so_decl_list(&ish->stream_output,
return false;
}
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
uint32_t *so_decls =
screen->vtbl.create_so_decl_list(&ish->stream_output,
return false;
}
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_FS, sizeof(*key), key, program,
return false;
}
- if (ish->compiled_once) {
- iris_debug_recompile(ice, &nir->info, &brw_key.base);
- } else {
- ish->compiled_once = true;
- }
+ iris_debug_recompile(ice, ish, &brw_key.base);
struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_CS, sizeof(*key), key, program,