RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-03-01 Thread Ivan Shcherbakov
, February 28, 2022 6:09 PM To: 'Alex Bennée' Cc: 'Peter Maydell' ; m...@redhat.com; qemu-devel@nongnu.org; arm...@redhat.com; 'Paolo Bonzini' Subject: RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping Hi Alex, Thanks for getting back to me. It is definitely the latter case (i.e

RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-28 Thread Ivan Shcherbakov
t again, if you think another way to do it is better, I am very open to it. Best regards, Ivan -Original Message- From: Alex Bennée Sent: Monday, February 28, 2022 2:28 AM To: Ivan Shcherbakov Cc: 'Peter Maydell' ; 'Paolo Bonzini' ; qemu-devel@nongnu.org; arm...@redhat.co

Re: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-28 Thread Alex Bennée
Sent: Thursday, February 24, 2022 7:54 AM > To: 'Alex Bennée' ; 'Peter Maydell' > > Cc: 'Paolo Bonzini' ; qemu-devel@nongnu.org; > arm...@redhat.com; m...@redhat.com > Subject: RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping > >> I haven't looked at th

RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-27 Thread Ivan Shcherbakov
Maydell' Cc: 'Paolo Bonzini' ; qemu-devel@nongnu.org; arm...@redhat.com; m...@redhat.com Subject: RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping > I haven't looked at the rest of the patch -- but can you explain where > whpx is different from how other accelerators handle

RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-24 Thread Ivan Shcherbakov
> I haven't looked at the rest of the patch -- but can you explain where > whpx is different from how other accelerators handle debug such that > it needs to know whether gdb is connected or not ? This mainly comes from the way single-stepping is handled. WHPX needs to know whether you want to

Re: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-24 Thread Alex Bennée
Peter Maydell writes: > On Wed, 23 Feb 2022 at 20:08, Ivan Shcherbakov wrote: >> > >> static GDBState gdbserver_state; >> +static bool gdbserver_is_connected; >> + >> +bool gdb_is_connected(void) >> +{ >> +return gdbserver_is_connected; >> +} > > I haven't looked at the rest of the patch

Re: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-24 Thread Peter Maydell
On Wed, 23 Feb 2022 at 20:08, Ivan Shcherbakov wrote: > > static GDBState gdbserver_state; > +static bool gdbserver_is_connected; > + > +bool gdb_is_connected(void) > +{ > +return gdbserver_is_connected; > +} I haven't looked at the rest of the patch -- but can you explain where whpx is

RE: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-23 Thread Ivan Shcherbakov
Hi Paolo, Thanks for getting back to me. Please see my comments below: >Please use WhpxStepMode and likewise for WhpxBreakpointState. No problem, I have updated the patch. >(In the case of WhpxStepMode I would also consider simply a "bool exclusive" >in whpx_cpu_run). This is a leftover from

Re: [PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-23 Thread Paolo Bonzini
On 2/23/22 06:25, Ivan Shcherbakov wrote: This adds support for breakpoints and stepping when debugging WHPX-accelerated guests with gdb. It enables reliable debugging of the Linux kernel in both single-CPU and SMP modes. Signed-off-by: Ivan Shcherbakov Hi, in general this patch is really

[PATCH 3/3] whpx: Added support for breakpoints and stepping

2022-02-22 Thread Ivan Shcherbakov
This adds support for breakpoints and stepping when debugging WHPX-accelerated guests with gdb. It enables reliable debugging of the Linux kernel in both single-CPU and SMP modes. Signed-off-by: Ivan Shcherbakov --- gdbstub.c| 10 + include/exec/gdbstub.h |