Commit 4d2140c4 authored by Erico Nunes's avatar Erico Nunes

lima/ir: print name of unsupported nir_op

lima ppir and gpir often hit unsupported alu nir_op instructions at this
stage of development. Printing the raw nir_op is not very helpful, since
the list of nir_op is an unnumbered enum that is generated during the
build, so it's annoying to figure out what is the missing
implementation.
Just print the name as pointed out by cwabbott some time ago on IRC.
Signed-off-by: Erico Nunes's avatarErico Nunes <nunes.erico@gmail.com>
parent 54c5d57b
......@@ -126,7 +126,7 @@ static bool gpir_emit_alu(gpir_block *block, nir_instr *ni)
int op = nir_to_gpir_opcodes[instr->op];
if (op < 0) {
gpir_error("unsupported nir_op %d\n", instr->op);
gpir_error("unsupported nir_op: %s\n", nir_op_infos[instr->op].name);
return false;
}
......
......@@ -157,7 +157,7 @@ static ppir_node *ppir_emit_alu(ppir_block *block, nir_instr *ni)
int op = nir_to_ppir_opcodes[instr->op];
if (op < 0) {
ppir_error("unsupported nir_op %d\n", instr->op);
ppir_error("unsupported nir_op: %s\n", nir_op_infos[instr->op].name);
return NULL;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment