aboutsummaryrefslogtreecommitdiff
path: root/cpu/cpu.go
diff options
context:
space:
mode:
Diffstat (limited to 'cpu/cpu.go')
-rw-r--r--cpu/cpu.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/cpu/cpu.go b/cpu/cpu.go
index 113adf0..b8b0a1e 100644
--- a/cpu/cpu.go
+++ b/cpu/cpu.go
@@ -111,6 +111,11 @@ func (c *CPU) interrupt(vector uint16, brk bool) {
c.PC = c.read16(vector)
}
+// burns cycles without running anything, used while dma holds the cpu
+func (c *CPU) Stall(cycles int) {
+ c.Cycles += uint64(cycles)
+}
+
func (c *CPU) Step() int {
if c.Jammed {
c.Cycles++