Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remoteType=cspect: watchpoints, unit tests #18

Open
maziac opened this issue Apr 30, 2020 · 3 comments
Open

remoteType=cspect: watchpoints, unit tests #18

maziac opened this issue Apr 30, 2020 · 3 comments
Labels
cspect A problem inside CSpect (or most probably inside CSpect)

Comments

@maziac
Copy link
Owner

maziac commented Apr 30, 2020

DeZog/CSpect (v2.12.22):

  • Watchpoints work unreliable. Under unknown circumstances a watchpoint (aka CSpect read-breakpoint) might prevent simple stepping. In that case do not enable watchpoints (do not use "-wpmem enable".
  • Z80 unit tests do not work. Most probably because of the Watchpoints issue as, even if wpmem is not used, the unit tests use watchpoints internally.
@maziac maziac changed the title remoteType=cspect: watchpoints, stepping, unit tests remoteType=cspect: watchpoints, unit tests May 9, 2020
@maziac maziac added the cspect A problem inside CSpect (or most probably inside CSpect) label May 21, 2020
@maziac
Copy link
Owner Author

maziac commented May 21, 2020

Here is a way to reproduce the problem even without DeZog or the DeZog plugin involved.
z80-sample-program.nex.zip

    org $8000
main:
    ; Disable interrupts
    ;di
    ei
    defb 0xDD, 0x01 ; CSpect break
    ld sp,stack_top

    ; CLS
    call clear_screen

Now I start CSpect (2.12.22):
mono CSpect.exe -w4 -exit -brk -tv z80-sample-program.nex

And set a read-breakpoint at 0x8023.

Bildschirmfoto_2020-04-30_um_10 46 51

Then I step (F8). The debugger right away jumps into the interrupt.
And I step over (F8) the complete interrupt.

image

And step-out.

image

Now it becomes interesting.
The next step (F8) does not step-over the "LD SP,..." but again brings me to the ISR:

image

Stepping out and trying to step-over "LD SP,..." again leads to the same result: It is not possible to step-over "LD SP,...".

If I use the same program but disable the interrupts at the start (DI) then the debugger doesn't enter the ISR but it is also not possible to step-over the "LD SP,...".

Note: "LD SP,..." is here just by accident, I experienced this behavior also for other instructions.

@maziac
Copy link
Owner Author

maziac commented Mar 6, 2021

Watchpoint are disabled for cspect and unit tests now.
Still the issue remains in cspect.

@maziac
Copy link
Owner Author

maziac commented Nov 16, 2022

The described behavior (screen shots) is different with CSpect 2.16.6.
Anyhow I ran into a similar problem (was not able to step over an instruction) when enabling watchpoints.
So, the problem seems to remain.
The Watchpoints keep being disabled also for DeZog 3.0 for CSpect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cspect A problem inside CSpect (or most probably inside CSpect)
Projects
None yet
Development

No branches or pull requests

1 participant