RFR: JDK-8305782: Provide MacroAssembler::breakpoint on aarch64 [v2]
Thomas Stuefe
stuefe at openjdk.org
Tue May 2 08:54:28 UTC 2023
On Sun, 30 Apr 2023 11:54:37 GMT, Erik Österlund <eosterlund at openjdk.org> wrote:
> The best way is like this:
>
> ```
> address poo;
>
> void stuff() {
> ... instructions ...
> poo = pc();
> ... instructions ...
> }
> ```
>
> then, in gdb:
>
> ```
> (gdb) b <somewhere after startup>
> breakpoint 2 at 0xabcedf
> (gdb) comm 2
> Type commands for breakpoint(s) 2, one per line.
> End with a line saying just "end".
> >b *poo
> >c
> >end
> (gdb)
> ```
>
> Now, every time you run the program, a breakpoint will be set at `*poo`. And you can continue after the breakpoint.
Thanks, Andrew, that is helpful. I use breakpoint mostly in cases where I have a utility function that gets emitted multiple times, and I don't care which instance I debug, I'm fine with the first one that hits break.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/13401#issuecomment-1531104977
More information about the hotspot-compiler-dev
mailing list