prog_print: Add support for printing the TXD opcode.
authorKenneth Graunke <kenneth@whitecape.org>
Tue, 26 Apr 2011 23:14:06 +0000 (16:14 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 28 Apr 2011 21:51:29 +0000 (14:51 -0700)
Reviewed-by: Brian Paul <brianp@vmware.com>
src/mesa/program/prog_print.c

index 484596af760664529a2fc1dab2036669c36863b6..7c3b4909e73ec97b0636c632faaf7fef2514e2ac 100644 (file)
@@ -647,6 +647,7 @@ _mesa_fprint_instruction_opt(FILE *f,
    case OPCODE_TXP:
    case OPCODE_TXL:
    case OPCODE_TXB:
+   case OPCODE_TXD:
       fprintf(f, "%s", _mesa_opcode_string(inst->Opcode));
       if (inst->SaturateMode == SATURATE_ZERO_ONE)
          fprintf(f, "_SAT");
@@ -654,6 +655,12 @@ _mesa_fprint_instruction_opt(FILE *f,
       fprint_dst_reg(f, &inst->DstReg, mode, prog);
       fprintf(f, ", ");
       fprint_src_reg(f, &inst->SrcReg[0], mode, prog);
+      if (inst->Opcode == OPCODE_TXD) {
+         fprintf(f, ", ");
+         fprint_src_reg(f, &inst->SrcReg[1], mode, prog);
+         fprintf(f, ", ");
+         fprint_src_reg(f, &inst->SrcReg[2], mode, prog);
+      }
       fprintf(f, ", texture[%d], ", inst->TexSrcUnit);
       switch (inst->TexSrcTarget) {
       case TEXTURE_1D_INDEX:   fprintf(f, "1D");    break;