Skip to content

honor debugger created/modified breakpoints (possibly also watchpoints) #319

Open
@GitMensch

Description

@GitMensch

So far we delete every breakpoint, then explicit create the ones that come from the debugging frontent.

It would be nice to automatically adjust the frontend list when done on the debugger side.

Easiest way to reproduce: start debugging of a program that has a breakpoint in line 10 and stop there, then enter "b 11".
The MI return is

=breakpoint-created,bkpt={number="2",type="breakpoint",disp="keep",enabled="y",addr="0x00007fffe747af6b",func="main",file="/tmp/testme_symlinked.c",fullname="/tmp/testme.c",line="11",thread-groups=["i1"],times="0",original-location="/tmp/testme.c:11"} 

Expectation: also visible in the frontend (and therefore also adjustable on the frontend).

Similar: when breakpoints are disabled, their condition changed or even the breakpoint is deleted on the debugging console (the first two return a breakpoint-modified and the last a breakpoint-deleted event as noted below) - should also be done in the UI.

=breakpoint-modified,bkpt={number="2",type="breakpoint",disp="keep",enabled="n",addr="0x00007fffe747af6b",func="main",file="/tmp/testme_symlinked.c",fullname="/tmp/testme.c",line="11",thread-groups=["i1"],times="0",original-location="/tmp/testme.c:11"} 
=breakpoint-modified,bkpt={number="2",type="breakpoint",disp="keep",enabled="n",addr="0x00007fffe747af6b",func="main",file="/tmp/testme_symlinked.c",fullname="/tmp/testme.c",line="11",thread-groups=["i1"],cond="1 == 2",times="0",original-location="/tmp/testme.c:11"} 
=breakpoint-deleted,id="2" 

Watchpoints are similar but additional include a "what" field, for example ,what="*(char(*)[10])(0x7fffe783c090)" and a type field as follows: ,type="hw watchpoint" (depending on the type also as read watchpoint, acc watchpoint or (plain software watchpoint) watchpoint) ; they commonly have no addr, func, file or fullname.

All kinds of breakpoints may have a script field (containing the commands, adjusting those would also be a breakpoint-modified event).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions