Skip to content

Commit

Permalink
cpu: check if HW breakpoints are enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
JaCzekanski committed Apr 23, 2020
1 parent 2296d8c commit 9da5fad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cpu/cpu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ void CPU::saveStateForException() {
}

void CPU::handleHardwareBreakpoints() {
if (((PC ^ cop0.bpcm) & cop0.bpc) == 0) {
if (cop0.dcic.codeBreakpointEnabled() && ((PC ^ cop0.bpcm) & cop0.bpc) == 0) {
cop0.dcic.codeBreakpointHit = 1;
cop0.dcic.breakpointHit = 1;
instructions::exception(this, COP0::CAUSE::Exception::breakpoint);
Expand Down

0 comments on commit 9da5fad

Please sign in to comment.