Or translate LazDebuggerFpGDBMI to use gdbserver.
That should be easy, since it just needs to insert the commands to gdb that set the remote.... (and maybe async gdb commands)
My preference is to move away from gdb since it needs a patch (which has been around since 2016) to work properly with the separate memory spaces of avr.
Well, it is possible to add new backends to the IDE. Including based new one on FpDebug.
I myself have currently no plans to write such a backend, as my TODO is quite full.
The Structure in the IDE:
- IDE: ide/DebugManager and debugger/*
- DebuggerIntf: The base class for the backend.
- LazDebugger***: The backend (gdb/lldb wrapper / FpDebug wrapper) components/lazdebuggers/* and components/lazdebuggergdbmi
- FpDebug (package): (if used)
The package FpDebug contains:
- Dwarf Reader: Currently elf, windows, and mac
- Dwarf Parser: Independent of platform (OS/CPU). Can have dependent subclasses (such as for FPC)
- Controller: Run/Pause/Stepping: Has platform dependend subclasses
If you want to control gdb-server without gdb, you need to implement everything that the gdb-part does. I.e. I do not know if gdb or gdb-server control the stepping.
To start this is the protocol.
Also a dwarf reader for the exe format involved.
Cpu specific register reader
With that you would be able to read memory, so watches would work.
Then it depends what is needed for running/stopping/pausing ....
ASM single stepping should be fairly easy.
With look line based stepping can build on that, with an added (partial) disassembler... (with luck)
Some of that would go into FpDebug, and patches can be accepted.
The protocol would go into a new backend.
---
Also there is no full support for memory spaces in fpdebug yet. There are one or 2 places where it has prepared code....
However that might not be to hard to change (adding bit offsets to addresses had turned out simple, so adding an address space would hopefully be similar)