Skip to content

Commit

Permalink
z80.h: fix IM0
Browse files Browse the repository at this point in the history
  • Loading branch information
floooh committed Jan 2, 2025
1 parent 41715c6 commit 38b6774
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion chips/z80.h
Original file line number Diff line number Diff line change
Expand Up @@ -2718,7 +2718,7 @@ uint64_t z80_tick(z80_t* cpu, uint64_t pins) {
case 1637: pins|=(Z80_M1|Z80_IORQ);_step(); // int_im0 T:1
case 1638: _wait();cpu->opcode=_z80_get_db(pins);_step(); // int_im0 T:2
case 1639: pins=_z80_refresh(cpu,pins);_step(); // int_im0 T:3
case 1640: cpu->step=cpu->opcode; cpu->addr=cpu->hl;_step(); // int_im0 T:4
case 1640: cpu->addr=cpu->hl;_goto(cpu->opcode);_step(); // int_im0 T:4
case 1641: _fetch(); // int_im0 T:5
case 1642: cpu->iff1=cpu->iff2=false;_step(); // int_im1 T:0
case 1643: pins|=(Z80_M1|Z80_IORQ);_step(); // int_im1 T:1
Expand Down
2 changes: 1 addition & 1 deletion codegen/z80_desc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ int_im0:
- { type: generic, tcycles: 1, action: "_wait();cpu->opcode=_z80_get_db(pins)" }
# combined refresh and branch to loaded instruction cycle
- { type: generic, tcycles: 1, action: "pins=_z80_refresh(cpu,pins)" }
- { type: generic, tcycles: 1, action: "cpu->step=cpu->opcode; cpu->addr=cpu->hl" }
- { type: generic, tcycles: 1, action: "cpu->addr=cpu->hl;_goto(cpu->opcode)" }

int_im1:
flags: { special: true }
Expand Down

0 comments on commit 38b6774

Please sign in to comment.