projects
/
emu8051.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ae50fa4
)
Fix error with RETI instruction
author
Hugo Villeneuve
<hugo@hugovil.com>
Mon, 4 Nov 2013 15:16:04 +0000
(10:16 -0500)
committer
Hugo Villeneuve
<hugo@hugovil.com>
Wed, 6 Nov 2013 03:17:17 +0000
(22:17 -0500)
The stack pointer was not updated correctly.
Error reported and fixed by Anthony (antliu at gmail.com).
src/opcode2c.pl
patch
|
blob
|
history
diff --git
a/src/opcode2c.pl
b/src/opcode2c.pl
index
0b11438
..
29c1c41
100755
(executable)
--- a/
src/opcode2c.pl
+++ b/
src/opcode2c.pl
@@
-483,6
+483,7
@@
for ($i=0 ; $i< 256; $i++) {
print INST_IMP "unsigned char SP = cpu8051_ReadD( _SP_ );\n";
print INST_IMP "cpu8051.pc = ( cpu8051_ReadI( SP-- ) << 8 );\n";
print INST_IMP "cpu8051.pc += cpu8051_ReadI( SP-- );\n";
+ print INST_IMP "cpu8051_WriteD( _SP_, SP );\n";
}
# RLC