Browse Source

iris: Move iris_debug_recompile calls before uploading.

Order of operations is important, otherwise we'll find the program we
just uploaded as the "old" compile and get confused why nothing is
different between the two keys.

Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
tags/19.1-branchpoint
Kenneth Graunke 6 years ago
parent
commit
4c3c417b00
1 changed files with 33 additions and 33 deletions
  1. 33
    33
      src/gallium/drivers/iris/iris_program.c

+ 33
- 33
src/gallium/drivers/iris/iris_program.c View File

return false; return false;
} }


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

uint32_t *so_decls = uint32_t *so_decls =
ice->vtbl.create_so_decl_list(&ish->stream_output, ice->vtbl.create_so_decl_list(&ish->stream_output,
&vue_prog_data->vue_map); &vue_prog_data->vue_map);
prog_data, so_decls, system_values, num_system_values, prog_data, so_decls, system_values, num_system_values,
num_cbufs); num_cbufs);


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }
return false; return false;
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_TCS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

if (ish) { if (ish) {
if (ish->compiled_once) { if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key); iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} }
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_TCS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }
return false; return false;
} }


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

uint32_t *so_decls = uint32_t *so_decls =
ice->vtbl.create_so_decl_list(&ish->stream_output, ice->vtbl.create_so_decl_list(&ish->stream_output,
&vue_prog_data->vue_map); &vue_prog_data->vue_map);
prog_data, so_decls, system_values, num_system_values, prog_data, so_decls, system_values, num_system_values,
num_cbufs); num_cbufs);


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }
return false; return false;
} }


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

uint32_t *so_decls = uint32_t *so_decls =
ice->vtbl.create_so_decl_list(&ish->stream_output, ice->vtbl.create_so_decl_list(&ish->stream_output,
&vue_prog_data->vue_map); &vue_prog_data->vue_map);
prog_data, so_decls, system_values, num_system_values, prog_data, so_decls, system_values, num_system_values,
num_cbufs); num_cbufs);


if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else {
ish->compiled_once = true;
}

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }
return false; return false;
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_FS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

if (ish->compiled_once) { if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key); iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else { } else {
ish->compiled_once = true; ish->compiled_once = true;
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_FS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }
return false; return false;
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_CS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

if (ish->compiled_once) { if (ish->compiled_once) {
iris_debug_recompile(ice, &nir->info, key->program_string_id, key); iris_debug_recompile(ice, &nir->info, key->program_string_id, key);
} else { } else {
ish->compiled_once = true; ish->compiled_once = true;
} }


struct iris_compiled_shader *shader =
iris_upload_shader(ice, IRIS_CACHE_CS, sizeof(*key), key, program,
prog_data, NULL, system_values, num_system_values,
num_cbufs);

ralloc_free(mem_ctx); ralloc_free(mem_ctx);
return shader; return shader;
} }

Loading…
Cancel
Save