I find it rather difficult to debug the i965 code generator. Attached
is a trivial patch that makes one of the errors a bit more helpful.

Cheers,
-- 
Sam.
>From 4b606cbaa15e34da27c096202df8c9570ad51459 Mon Sep 17 00:00:00 2001
From: Sam Hocevar <[EMAIL PROTECTED]>
Date: Tue, 23 Sep 2008 17:56:19 +0200
Subject: [PATCH]   i965: more meaningful message for unsupported opcodes.

---
 src/mesa/drivers/dri/i965/brw_vs_emit.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_vs_emit.c b/src/mesa/drivers/dri/i965/brw_vs_emit.c
index 8759826..b0b0449 100644
--- a/src/mesa/drivers/dri/i965/brw_vs_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_vs_emit.c
@@ -1155,7 +1155,10 @@ void brw_vs_emit(struct brw_vs_compile *c )
       case OPCODE_ENDSUB:
 	 break;
       default:
-	 _mesa_printf("Unsupport opcode %d in vertex shader\n", inst->Opcode);
+	 _mesa_printf("Unsupported opcode %i (%s) in vertex shader\n",
+		      inst->Opcode, inst->Opcode < MAX_OPCODE ?
+				    _mesa_opcode_string(inst->Opcode) :
+				    "unknown");
 	 break;
       }
 
-- 
1.5.6.5

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Mesa3d-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to