BRK and CONT work the same
This commit is contained in:
@@ -703,22 +703,10 @@ execute_program( GLcontext *ctx,
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case OPCODE_BRK: /* break out of loop */
|
case OPCODE_BRK: /* break out of loop */
|
||||||
{
|
/* fall-through */
|
||||||
#if 0
|
case OPCODE_CONT: /* continue loop */
|
||||||
/* The location of the ENDLOOP instruction is saved in the
|
/* Subtract 1 here since we'll do pc++ at end of for-loop */
|
||||||
* BGNLOOP instruction. Get that instruction and jump to
|
|
||||||
* its BranchTarget + 1.
|
|
||||||
*/
|
|
||||||
const struct prog_instruction *loopBeginInst
|
|
||||||
= program->Base.Instructions + inst->BranchTarget;
|
|
||||||
ASSERT(loopBeginInst->Opcode == OPCODE_BGNLOOP);
|
|
||||||
ASSERT(loopBeginInst->BranchTarget >= 0);
|
|
||||||
/* we'll add one at bottom of for-loop */
|
|
||||||
pc = loopBeginInst->BranchTarget;
|
|
||||||
#else
|
|
||||||
pc = inst->BranchTarget - 1;
|
pc = inst->BranchTarget - 1;
|
||||||
#endif
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
case OPCODE_CAL: /* Call subroutine */
|
case OPCODE_CAL: /* Call subroutine */
|
||||||
{
|
{
|
||||||
@@ -750,10 +738,6 @@ execute_program( GLcontext *ctx,
|
|||||||
store_vector4( inst, machine, result );
|
store_vector4( inst, machine, result );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case OPCODE_CONT: /* continue loop */
|
|
||||||
/* Subtract 1 here since we'll do pc++ at end of for-loop */
|
|
||||||
pc = inst->BranchTarget - 1;
|
|
||||||
break;
|
|
||||||
case OPCODE_COS:
|
case OPCODE_COS:
|
||||||
{
|
{
|
||||||
GLfloat a[4], result[4];
|
GLfloat a[4], result[4];
|
||||||
|
Reference in New Issue
Block a user