diff options
author | Andre Maasikas <[email protected]> | 2010-09-02 11:03:38 +0300 |
---|---|---|
committer | Andre Maasikas <[email protected]> | 2010-09-09 11:08:11 +0300 |
commit | 5697bf166082119593bf1297028d03a7938eacfb (patch) | |
tree | ab0675653947814e79e2f72560e9ce287a37c1d2 /src | |
parent | ae21956be29c027659568e17f1cf72d1931c4d61 (diff) |
r600: remove mask from output intructions
in case of relative addressing we never get to know which comps
were really written.
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/r600/evergreen_fragprog.c | 7 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r600/evergreen_vertprog.c | 8 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r600/r700_assembler.c | 14 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r600/r700_assembler.h | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r600/r700_fragprog.c | 7 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r600/r700_vertprog.c | 8 |
6 files changed, 1 insertions, 45 deletions
diff --git a/src/mesa/drivers/dri/r600/evergreen_fragprog.c b/src/mesa/drivers/dri/r600/evergreen_fragprog.c index 0d31b1dcf10..fb1f53a3642 100644 --- a/src/mesa/drivers/dri/r600/evergreen_fragprog.c +++ b/src/mesa/drivers/dri/r600/evergreen_fragprog.c @@ -99,7 +99,6 @@ void evergreen_Map_Fragment_Program(r700_AssemblerBase *pAsm, { unsigned int unBit; unsigned int i; - GLuint ui; /* match fp inputs with vp exports. */ struct evergreen_vertex_program_cont *vpc = @@ -246,12 +245,6 @@ void evergreen_Map_Fragment_Program(r700_AssemblerBase *pAsm, pAsm->pR700Shader->depthIsExported = 1; } - pAsm->pucOutMask = (unsigned char*) MALLOC(pAsm->number_of_exports); - for(ui=0; ui<pAsm->number_of_exports; ui++) - { - pAsm->pucOutMask[ui] = 0x0; - } - pAsm->flag_reg_index = pAsm->number_used_registers++; pAsm->uFirstHelpReg = pAsm->number_used_registers; diff --git a/src/mesa/drivers/dri/r600/evergreen_vertprog.c b/src/mesa/drivers/dri/r600/evergreen_vertprog.c index bdd9a9eb121..291158009df 100644 --- a/src/mesa/drivers/dri/r600/evergreen_vertprog.c +++ b/src/mesa/drivers/dri/r600/evergreen_vertprog.c @@ -200,7 +200,6 @@ void evergreen_Map_Vertex_Program(GLcontext *ctx, struct evergreen_vertex_program *vp, struct gl_vertex_program *mesa_vp) { - GLuint ui; r700_AssemblerBase *pAsm = &(vp->r700AsmCode); unsigned int num_inputs; @@ -226,13 +225,6 @@ void evergreen_Map_Vertex_Program(GLcontext *ctx, pAsm->number_used_registers += pAsm->number_of_exports; - pAsm->pucOutMask = (unsigned char*) MALLOC(pAsm->number_of_exports); - - for(ui=0; ui<pAsm->number_of_exports; ui++) - { - pAsm->pucOutMask[ui] = 0x0; - } - /* Map temporary registers (GPRs) */ pAsm->starting_temp_register_number = pAsm->number_used_registers; diff --git a/src/mesa/drivers/dri/r600/r700_assembler.c b/src/mesa/drivers/dri/r600/r700_assembler.c index d639fe002bd..9c5a5053d97 100644 --- a/src/mesa/drivers/dri/r600/r700_assembler.c +++ b/src/mesa/drivers/dri/r600/r700_assembler.c @@ -1413,17 +1413,6 @@ static GLboolean next_ins(r700_AssemblerBase *pAsm) if (pAsm->D.dst.rtype == DST_REG_OUT) { assert(pAsm->D.dst.reg >= pAsm->starting_export_register_number); - - if (pAsm->D.dst.op3) - { - // There is no mask for OP3 instructions, so all channels are written - pAsm->pucOutMask[pAsm->D.dst.reg - pAsm->starting_export_register_number] = 0xF; - } - else - { - pAsm->pucOutMask[pAsm->D.dst.reg - pAsm->starting_export_register_number] - |= (unsigned char)pAsm->pILInst[pAsm->uiCurInst].DstReg.WriteMask; - } } //reset for next inst. @@ -7751,7 +7740,7 @@ GLboolean Process_Export(r700_AssemblerBase* pAsm, { assert(starting_register_number >= pAsm->starting_export_register_number); - ucWriteMask = pAsm->pucOutMask[starting_register_number - pAsm->starting_export_register_number]; + ucWriteMask = 0x0F; /* exports Z as a float into Red channel */ if (GL_TRUE == is_depth_export) ucWriteMask = 0x1; @@ -8087,7 +8076,6 @@ GLboolean Process_Vertex_Exports(r700_AssemblerBase *pR700AsmCode, GLboolean Clean_Up_Assembler(r700_AssemblerBase *pR700AsmCode) { - FREE(pR700AsmCode->pucOutMask); FREE(pR700AsmCode->pInstDeps); if(NULL != pR700AsmCode->subs) diff --git a/src/mesa/drivers/dri/r600/r700_assembler.h b/src/mesa/drivers/dri/r600/r700_assembler.h index d357b0e3ec0..c7c7ab2d4ff 100644 --- a/src/mesa/drivers/dri/r600/r700_assembler.h +++ b/src/mesa/drivers/dri/r600/r700_assembler.h @@ -414,8 +414,6 @@ typedef struct r700_AssemblerBase unsigned char ucVP_AttributeMap[VERT_ATTRIB_MAX]; unsigned char ucVP_OutputMap[VERT_RESULT_MAX]; - unsigned char * pucOutMask; - //----------------------------------------------------------------------------------- // flow control members //----------------------------------------------------------------------------------- diff --git a/src/mesa/drivers/dri/r600/r700_fragprog.c b/src/mesa/drivers/dri/r600/r700_fragprog.c index 6fdd93a3302..217b0e27a4a 100644 --- a/src/mesa/drivers/dri/r600/r700_fragprog.c +++ b/src/mesa/drivers/dri/r600/r700_fragprog.c @@ -99,7 +99,6 @@ void Map_Fragment_Program(r700_AssemblerBase *pAsm, { unsigned int unBit; unsigned int i; - GLuint ui; /* match fp inputs with vp exports. */ struct r700_vertex_program_cont *vpc = @@ -245,12 +244,6 @@ void Map_Fragment_Program(r700_AssemblerBase *pAsm, } } - pAsm->pucOutMask = (unsigned char*) MALLOC(pAsm->number_of_exports); - for(ui=0; ui<pAsm->number_of_exports; ui++) - { - pAsm->pucOutMask[ui] = 0x0; - } - pAsm->flag_reg_index = pAsm->number_used_registers++; pAsm->uFirstHelpReg = pAsm->number_used_registers; diff --git a/src/mesa/drivers/dri/r600/r700_vertprog.c b/src/mesa/drivers/dri/r600/r700_vertprog.c index 7ed4b7d2387..2fee5b4433e 100644 --- a/src/mesa/drivers/dri/r600/r700_vertprog.c +++ b/src/mesa/drivers/dri/r600/r700_vertprog.c @@ -201,7 +201,6 @@ void Map_Vertex_Program(GLcontext *ctx, struct r700_vertex_program *vp, struct gl_vertex_program *mesa_vp) { - GLuint ui; r700_AssemblerBase *pAsm = &(vp->r700AsmCode); unsigned int num_inputs; @@ -227,13 +226,6 @@ void Map_Vertex_Program(GLcontext *ctx, pAsm->number_used_registers += pAsm->number_of_exports; - pAsm->pucOutMask = (unsigned char*) MALLOC(pAsm->number_of_exports); - - for(ui=0; ui<pAsm->number_of_exports; ui++) - { - pAsm->pucOutMask[ui] = 0x0; - } - /* Map temporary registers (GPRs) */ pAsm->starting_temp_register_number = pAsm->number_used_registers; |