From 60a128fe8172826837fd6f91ae323aaa07ba7607 Mon Sep 17 00:00:00 2001 From: Erico Nunes Date: Sun, 5 May 2019 10:51:43 +0200 Subject: [PATCH] lima/ir: print names of unsupported intrinsics While lima still doesn't support some kinds of intrinsics, it is more helpful to display the name of the unsupported instr->intrinsic to make debugging easier. Signed-off-by: Erico Nunes Reviewed-by: Qiang Yu --- src/gallium/drivers/lima/ir/gp/nir.c | 3 ++- src/gallium/drivers/lima/ir/pp/nir.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/lima/ir/gp/nir.c b/src/gallium/drivers/lima/ir/gp/nir.c index 8cd8d2f67e0..f95957e8892 100644 --- a/src/gallium/drivers/lima/ir/gp/nir.c +++ b/src/gallium/drivers/lima/ir/gp/nir.c @@ -201,7 +201,8 @@ static bool gpir_emit_intrinsic(gpir_block *block, nir_instr *ni) return true; } default: - gpir_error("unsupported nir_intrinsic_instr %d\n", instr->intrinsic); + gpir_error("unsupported nir_intrinsic_instr %s\n", + nir_intrinsic_infos[instr->intrinsic].name); return false; } } diff --git a/src/gallium/drivers/lima/ir/pp/nir.c b/src/gallium/drivers/lima/ir/pp/nir.c index bdf54b227c6..6cb90701fd3 100644 --- a/src/gallium/drivers/lima/ir/pp/nir.c +++ b/src/gallium/drivers/lima/ir/pp/nir.c @@ -266,7 +266,8 @@ static ppir_node *ppir_emit_intrinsic(ppir_block *block, nir_instr *ni) return &snode->node; default: - ppir_error("unsupported nir_intrinsic_instr %d\n", instr->intrinsic); + ppir_error("unsupported nir_intrinsic_instr %s\n", + nir_intrinsic_infos[instr->intrinsic].name); return NULL; } } -- 2.30.2