[Python-checkins] python/dist/src/Python compile.c,2.304,2.305
rhettinger at users.sourceforge.net
rhettinger at users.sourceforge.net
Thu Jun 24 05:25:42 EDT 2004
Update of /cvsroot/python/python/dist/src/Python
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3806
Modified Files:
compile.c
Log Message:
Move NOP to end of code transformation.
Index: compile.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/compile.c,v
retrieving revision 2.304
retrieving revision 2.305
diff -C2 -d -r2.304 -r2.305
*** compile.c 21 Jun 2004 16:31:15 -0000 2.304
--- compile.c 24 Jun 2004 09:25:39 -0000 2.305
***************
*** 393,397 ****
switch (opcode) {
! /* Replace UNARY_NOT JUMP_IF_FALSE with NOP JUMP_IF_TRUE */
case UNARY_NOT:
if (codestr[i+1] != JUMP_IF_FALSE ||
--- 393,398 ----
switch (opcode) {
! /* Replace UNARY_NOT JUMP_IF_FALSE POP_TOP with
! with JUMP_IF_TRUE POP_TOP NOP */
case UNARY_NOT:
if (codestr[i+1] != JUMP_IF_FALSE ||
***************
*** 402,407 ****
if (codestr[tgt] != POP_TOP)
continue;
! codestr[i] = NOP;
! codestr[i+1] = JUMP_IF_TRUE;
break;
--- 403,411 ----
if (codestr[tgt] != POP_TOP)
continue;
! j = GETARG(codestr, i+1) + 1;
! codestr[i] = JUMP_IF_TRUE;
! SETARG(codestr, i, j);
! codestr[i+3] = POP_TOP;
! codestr[i+4] = NOP;
break;
More information about the Python-checkins
mailing list