X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=src%2Fopcode2c.pl;h=a80f651fe78feb0ef0a78f3fec40cd78443c671d;hb=47a60dcfbfdb7a29bd933a850292b752970f2af0;hp=4741f07e908a9f2670ef3a12a6f7475b9adea183;hpb=761e720501ec14ecedc371fe601b7abcf882d4b6;p=emu8051.git diff --git a/src/opcode2c.pl b/src/opcode2c.pl index 4741f07..a80f651 100755 --- a/src/opcode2c.pl +++ b/src/opcode2c.pl @@ -610,7 +610,7 @@ for ($i=0 ; $i< 256; $i++) { print INST_IMP "unsigned int reladdr = ((char) memory_read8(PGM_MEM_ID, cpu8051.pc)) + (cpu8051.pc + 1);\n"; print INST_IMP "cpu8051_WriteD( _PSW_, ( cpu8051_ReadD( _PSW_ ) & 0x7F ) );\n"; print INST_IMP "if ( destination < source ) cpu8051_WriteD( _PSW_, ( cpu8051_ReadD( _PSW_ ) | 0x80 ) );\n"; - print INST_IMP "if ( destination != source ) cpu8051.pc = reladdr;\n"; + print INST_IMP "if ( destination != source ) cpu8051.pc = reladdr; else cpu8051.pc++; \n"; } # PUSH