BartmanAbyss / vscode-amiga-debug

One-stop Visual Studio Code Extension to compile, debug and profile Amiga C/C++ programs compiled by the bundled gcc 12.2 with the bundled WinUAE/FS-UAE.
GNU General Public License v3.0
314 stars 39 forks source link

Profiling cpu and hardware registers. #78

Closed rjobling closed 2 years ago

rjobling commented 2 years ago

Would it be possible to add the cpu registers to the profiler view so you can watch them change as the code in the assembly window changes?

Would it be possible to include changes to readable hardware registers, things like vposr/intenar/intreqr/dmaconr? Currently I only see vposw/intena/intreq/dmacon and they only update when written to (unsurprisingly). This would help debugging since you'd be able to see them change as you scrub the profile slider.

On a similar note is it possible to show the hardware registers inside the gdb debugger along with the existing cpu registers?

BartmanAbyss commented 2 years ago

Would it be possible to add the cpu registers to the profiler view so you can watch them change as the code in the assembly window changes?

I'm currently not capturing the registers for each cycle, probably quite a bit of data. But I'll see what I can do.

Would it be possible to include changes to readable hardware registers, things like vposr/intenar/intreqr/dmaconr? Currently I only see vposw/intena/intreq/dmacon and they only update when written to (unsurprisingly). This would help debugging since you'd be able to see them change as you scrub the profile slider.

I'm not actually storing the custom registers in the capture, but recreate them based on the DMA writes.. Have to think about this some more.

On a similar note is it possible to show the hardware registers inside the gdb debugger along with the existing cpu registers?

I guess that's possible.

I'm currently quite busy preparing the next vscode-amiga-debug seminar, so I can have a look at these improvements in November at the earliest.

rjobling commented 2 years ago

Understood!

Maybe there is a subset of readable hardware registers worth recording without inflating the capture too much.

Hopefully that seminar will be broadcast or release shortly after! I've really loved using this system and the improvements!

BartmanAbyss commented 2 years ago

Yes, as far as I understand it the seminar will be streamed.

BartmanAbyss commented 2 years ago

In case you missed it, here's a recording of my seminar about all the new features https://www.youtube.com/watch?v=gQ4tKisnr7Y

rjobling commented 2 years ago

I did see your video and it was great! I hadn't realized the assembler output in the profile had those real world timings, so that'll be really nice to check when really getting down to some serious optimizing.