X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=src%2Fopcode2c.pl;h=a80f651fe78feb0ef0a78f3fec40cd78443c671d;hb=47a60dcfbfdb7a29bd933a850292b752970f2af0;hp=95b9455bbf83b474ec487354f74cb0af34046c1d;hpb=60f3340a9f321271f5ea96df2ccfc248f67bfd2f;p=emu8051.git diff --git a/src/opcode2c.pl b/src/opcode2c.pl index 95b9455..a80f651 100755 --- a/src/opcode2c.pl +++ b/src/opcode2c.pl @@ -215,8 +215,6 @@ for ($i=0 ; $i< 256; $i++) { print INST_IMP " ","*"x76,"/\n"; print INST_IMP "int\n"; print INST_IMP "cpu8051_OP_$a_opcodehex[$i](void)\n"; -# TEST hugo new... -# print INST_DEF "int OP_$a_opcodehex[$i]( );\n"; print INST_IMP "{\n"; if( $i == 0x85 ) { @@ -612,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