mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 05:08:08 +02:00
nir/spirv: print extension name in fail msg
Reviewed-by: Karol Herbst <kherbst@redhat.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Signed-off-by: Karol Herbst <kherbst@redhat.com>
This commit is contained in:
parent
9ce0360f76
commit
d4280561f5
1 changed files with 5 additions and 4 deletions
|
|
@ -383,19 +383,20 @@ static void
|
|||
vtn_handle_extension(struct vtn_builder *b, SpvOp opcode,
|
||||
const uint32_t *w, unsigned count)
|
||||
{
|
||||
const char *ext = (const char *)&w[2];
|
||||
switch (opcode) {
|
||||
case SpvOpExtInstImport: {
|
||||
struct vtn_value *val = vtn_push_value(b, w[1], vtn_value_type_extension);
|
||||
if (strcmp((const char *)&w[2], "GLSL.std.450") == 0) {
|
||||
if (strcmp(ext, "GLSL.std.450") == 0) {
|
||||
val->ext_handler = vtn_handle_glsl450_instruction;
|
||||
} else if ((strcmp((const char *)&w[2], "SPV_AMD_gcn_shader") == 0)
|
||||
} else if ((strcmp(ext, "SPV_AMD_gcn_shader") == 0)
|
||||
&& (b->options && b->options->caps.gcn_shader)) {
|
||||
val->ext_handler = vtn_handle_amd_gcn_shader_instruction;
|
||||
} else if ((strcmp((const char *)&w[2], "SPV_AMD_shader_trinary_minmax") == 0)
|
||||
} else if ((strcmp(ext, "SPV_AMD_shader_trinary_minmax") == 0)
|
||||
&& (b->options && b->options->caps.trinary_minmax)) {
|
||||
val->ext_handler = vtn_handle_amd_shader_trinary_minmax_instruction;
|
||||
} else {
|
||||
vtn_fail("Unsupported extension");
|
||||
vtn_fail("Unsupported extension: %s", ext);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue