r300: Removed the duplicate dest register defines.
authorOliver McFadden <z3ro.geek@gmail.com>
Mon, 25 Feb 2008 12:26:48 +0000 (12:26 +0000)
committerOliver McFadden <z3ro.geek@gmail.com>
Sat, 1 Mar 2008 06:33:05 +0000 (06:33 +0000)
src/mesa/drivers/dri/r300/r300_state.c
src/mesa/drivers/dri/r300/r300_vertprog.c
src/mesa/drivers/dri/r300/r300_vertprog.h

index 488ed3d3cc2c460235e2b829b9782a7b69ee84f9..6f9f3fbf5d113720d41380b9741dddf38deb7ee9 100644 (file)
@@ -1659,7 +1659,7 @@ static void r300SetupDefaultVertexProgram(r300ContextPtr rmesa)
 
        for (i = VERT_ATTRIB_POS; i < VERT_ATTRIB_MAX; i++) {
                if (rmesa->state.sw_tcl_inputs[i] != -1) {
-                       prog->program.body.i[program_end + 0] = MAKE_VSF_OP(R300_VPI_OUT_OP_MUL, o_reg++, VSF_FLAG_ALL, VSF_OUT_CLASS_RESULT);
+                       prog->program.body.i[program_end + 0] = MAKE_VSF_OP(R300_VPI_OUT_OP_MUL, o_reg++, VSF_FLAG_ALL, PVS_DST_REG_OUT);
                        prog->program.body.i[program_end + 1] = VSF_REG(rmesa->state.sw_tcl_inputs[i]);
                        prog->program.body.i[program_end + 2] = VSF_ATTR_UNITY(rmesa->state.sw_tcl_inputs[i]);
                        prog->program.body.i[program_end + 3] = VSF_UNITY(rmesa->state.sw_tcl_inputs[i]);
index c1329f13f75266ae30de9b96dc3085fb9d87027d..7e724514b06b10bc479b267d469ac449db1e9aa1 100644 (file)
@@ -174,11 +174,11 @@ static unsigned long t_dst_class(enum register_file file)
 
        switch (file) {
        case PROGRAM_TEMPORARY:
-               return VSF_OUT_CLASS_TMP;
+               return PVS_DST_REG_TEMPORARY;
        case PROGRAM_OUTPUT:
-               return VSF_OUT_CLASS_RESULT;
+               return PVS_DST_REG_OUT;
        case PROGRAM_ADDRESS:
-               return VSF_OUT_CLASS_ADDR;
+               return PVS_DST_REG_A0;
                /*
                   case PROGRAM_INPUT:
                   case PROGRAM_LOCAL_PARAM:
@@ -580,7 +580,7 @@ static GLuint *t_opcode_flr(struct r300_vertex_program *vp,
        inst[0] =
            MAKE_VSF_OP(R300_VPI_OUT_OP_FRC, *u_temp_i,
                        t_dst_mask(vpi->DstReg.WriteMask),
-                       VSF_OUT_CLASS_TMP);
+                       PVS_DST_REG_TEMPORARY);
 
        inst[1] = t_src(vp, &src[0]);
        inst[2] = ZERO_SRC_0;
@@ -994,7 +994,7 @@ static GLuint *t_opcode_xpd(struct r300_vertex_program *vp,
        inst[0] =
            MAKE_VSF_OP(R300_VPI_OUT_OP_MAD, *u_temp_i,
                        t_dst_mask(vpi->DstReg.WriteMask),
-                       VSF_OUT_CLASS_TMP);
+                       PVS_DST_REG_TEMPORARY);
 
        inst[1] = MAKE_VSF_SOURCE(t_src_index(vp, &src[0]), t_swizzle(GET_SWZ(src[0].Swizzle, 1)),      // y
                                  t_swizzle(GET_SWZ(src[0].Swizzle, 2)),        // z
@@ -1149,7 +1149,7 @@ static void r300TranslateVertexShader(struct r300_vertex_program *vp,
                                inst[0] =
                                    MAKE_VSF_OP(R300_VPI_OUT_OP_ADD,
                                                u_temp_i, VSF_FLAG_ALL,
-                                               VSF_OUT_CLASS_TMP);
+                                               PVS_DST_REG_TEMPORARY);
 
                                inst[1] =
                                    MAKE_VSF_SOURCE(t_src_index
@@ -1177,7 +1177,7 @@ static void r300TranslateVertexShader(struct r300_vertex_program *vp,
                                inst[0] =
                                    MAKE_VSF_OP(R300_VPI_OUT_OP_ADD,
                                                u_temp_i, VSF_FLAG_ALL,
-                                               VSF_OUT_CLASS_TMP);
+                                               PVS_DST_REG_TEMPORARY);
 
                                inst[1] =
                                    MAKE_VSF_SOURCE(t_src_index
index 62e5c70a4fe8a9dabffa7f7e56b268c0968d33bc..6f7afec3f3d5ccea93e88dc1ebeac7a71220561b 100644 (file)
 #define VSF_FLAG_ALL  0xf
 #define VSF_FLAG_NONE  0
 
-#define VSF_OUT_CLASS_TMP      0
-#define VSF_OUT_CLASS_ADDR     1
-#define VSF_OUT_CLASS_RESULT   2
-
 /* first DWORD of an instruction */
 
 /* possible operations: