Skip to content

Commit

Permalink
CRITICAL: Removed faulty if-condition in scheduleNextREGEvent() (#857)
Browse files Browse the repository at this point in the history
  • Loading branch information
dirkwhoffmann committed Jan 3, 2025
1 parent 43e94a4 commit 1dcd676
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
15 changes: 10 additions & 5 deletions Emulator/Components/Agnus/AgnusEvents.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,8 @@ Agnus::scheduleNextREGEvent()
Cycle next = changeRecorder.trigger();

// Schedule a register change event for that cycle
if (next < trigger[SLOT_REG]) scheduleAbs<SLOT_REG>(next, REG_CHANGE);
// if (next < trigger[SLOT_REG]) scheduleAbs<SLOT_REG>(next, REG_CHANGE);
scheduleAbs<SLOT_REG>(next, REG_CHANGE);
}

void
Expand Down Expand Up @@ -297,12 +298,16 @@ Agnus::serviceREGEvent(Cycle until)

if (syncEvent) {

// Call the logic analyzer of requested
// Let the logic analyzer probe all observed signals
if (syncEvent & EVFL::PROBE) { logicAnalyzer.recordSignals(pos.h); }

// Keep the event scheduled to reenter the function in the next cycle

} else {

// Schedule next event
scheduleNextREGEvent();
}

// Schedule next event
scheduleNextREGEvent();
}

#define LO_NONE(x) { serviceBPLEventLores<x>(); }
Expand Down
2 changes: 0 additions & 2 deletions Emulator/Misc/LogicAnalyzer/LogicAnalyzer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,6 @@ LogicAnalyzer::recordSignals(isize hpos)

auto hprev = agnus.pos.hPrev();

trace(true, "LogicAnalyzer::recordSignals\n");

assert(hpos >= 0 && hpos < HPOS_CNT);

// Only proceed if this is the main instance
Expand Down

0 comments on commit 1dcd676

Please sign in to comment.