nv30: add some opcodes.
authorStephane Marchesin <marchesin@icps.u-strasbg.fr>
Mon, 18 Aug 2008 01:00:25 +0000 (03:00 +0200)
committerStephane Marchesin <marchesin@icps.u-strasbg.fr>
Mon, 18 Aug 2008 01:00:25 +0000 (03:00 +0200)
src/gallium/drivers/nv30/nv30_fragprog.c
src/gallium/drivers/nv30/nv30_vertprog.c

index d3693fd..02f30ad 100644 (file)
@@ -526,6 +526,12 @@ nv30_fragprog_parse_instruction(struct nv30_fpc *fpc,
        case TGSI_OPCODE_MUL:
                arith(fpc, sat, MUL, dst, mask, src[0], src[1], none);
                break;
+       case TGSI_OPCODE_NOISE1:
+       case TGSI_OPCODE_NOISE2:
+       case TGSI_OPCODE_NOISE3:
+       case TGSI_OPCODE_NOISE4:
+               arith(fpc, sat, SFL, dst, mask, none, none, none);
+               break;
        case TGSI_OPCODE_POW:
                arith(fpc, sat, POW, dst, mask, src[0], src[1], none);
                break;
@@ -557,6 +563,9 @@ nv30_fragprog_parse_instruction(struct nv30_fpc *fpc,
        case TGSI_OPCODE_SGE:
                arith(fpc, sat, SGE, dst, mask, src[0], src[1], none);
                break;
+       case TGSI_OPCODE_SGT:
+               arith(fpc, sat, SGT, dst, mask, src[0], src[1], none);
+               break;
        case TGSI_OPCODE_SLT:
                arith(fpc, sat, SLT, dst, mask, src[0], src[1], none);
                break;
@@ -730,6 +739,8 @@ nv30_fragprog_translate(struct nv30_context *nv30,
        struct tgsi_parse_context parse;
        struct nv30_fpc *fpc = NULL;
 
+       tgsi_dump(fp->pipe.tokens,0);
+
        fpc = CALLOC(1, sizeof(struct nv30_fpc));
        if (!fpc)
                return;
index 6c075cd..7282455 100644 (file)
@@ -4,6 +4,7 @@
 
 #include "pipe/p_shader_tokens.h"
 #include "tgsi/tgsi_parse.h"
+#include "tgsi/tgsi_dump.h"
 
 #include "nv30_context.h"
 #include "nv30_state.h"
@@ -457,6 +458,9 @@ nv30_vertprog_parse_instruction(struct nv30_vpc *vpc,
        case TGSI_OPCODE_SGE:
                arith(vpc, 0, OP_SGE, dst, mask, src[0], src[1], none);
                break;
+       case TGSI_OPCODE_SGT:
+               arith(vpc, 0, OP_SGT, dst, mask, src[0], src[1], none);
+               break;
        case TGSI_OPCODE_SLT:
                arith(vpc, 0, OP_SLT, dst, mask, src[0], src[1], none);
                break;
@@ -570,6 +574,8 @@ nv30_vertprog_translate(struct nv30_context *nv30,
        struct tgsi_parse_context parse;
        struct nv30_vpc *vpc = NULL;
 
+       tgsi_dump(vp->pipe.tokens,0);
+
        vpc = CALLOC(1, sizeof(struct nv30_vpc));
        if (!vpc)
                return;