i965: more meaningful message for unsupported opcodes.
authorSam Hocevar <sam@zoy.org>
Tue, 23 Sep 2008 15:56:19 +0000 (17:56 +0200)
committerBrian Paul <brian.paul@tungstengraphics.com>
Thu, 25 Sep 2008 15:49:18 +0000 (09:49 -0600)
src/mesa/drivers/dri/i965/brw_vs_emit.c
src/mesa/drivers/dri/i965/brw_wm_emit.c

index 8759826e83b3fa489856cf2728e802804c1956dd..b0b0449f99c46799179321f64971463d1904700f 100644 (file)
@@ -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;
       }
 
index f1c14c98f95eb6f7acd1374574e5429ac3356f63..58c78c4b2c59ee048d48b9111ca77117e4f0428f 100644 (file)
@@ -1302,8 +1302,10 @@ void brw_wm_emit( struct brw_wm_compile *c )
         break;
 
       default:
-       _mesa_printf("unsupport opcode %d in fragment program\n", 
-               inst->opcode);
+        _mesa_printf("Unsupported opcode %i (%s) in fragment shader\n",
+                     inst->opcode, inst->opcode < MAX_OPCODE ?
+                                   _mesa_opcode_string(inst->opcode) :
+                                   "unknown");
       }
       
       for (i = 0; i < 4; i++)