The current way to configure the gdbserver "remote" debugging is to:
- set the
remote boolean to true
- add necessary information in the
target field (e.g., 1.2.3.4:6789).
-
"request": "attach",
"executable": "./bin/executable",
"target": "1.2.3.4:6789",
"cwd": "${workspaceRoot}",
"remote": true
The current way to configure the gdbserver "extended remote" debugging is to:
- set the
remote boolean to false (or not at all)...which seems counter-intuitive
- add necessary information in the
target field including extended-remote (e.g., extended-remote 1.2.3.4:6789)
-
"request": "attach",
"executable": "./bin/executable",
"target": "extended-remote 1.2.3.4:6789",
"cwd": "${workspaceRoot}",
"remote": false
From a user perspective, it seems odd that for extended-remote debugging, you would not set the remote boolean. Additionally, having the target commands be different (where one requires the extended-remote, but the other doesn't require the remote) at the beginning is also inconsistent.
It would seem that the remote boolean could go away (i.e., deprecate the option) and that the regular remote debugging could just be specified in the same way that the extended remote is, with a remote prefix in the target property. I think, at least from a user perspective, this would seem more consistent.
Additionally, internally the paths seem to needlessly diverge since the extended-remote is processed via MI2::attach, whereas the regular remote is processed via MI2::connect. It would seem the logic for both of these could be very similar internally.
Furthermore, standardizing on this might better position the extension to support other capabilities in the future, such as loading a core file (i.e., target-select core <file>).
The current way to configure the gdbserver "remote" debugging is to:
remoteboolean totruetargetfield (e.g.,1.2.3.4:6789).The current way to configure the gdbserver "extended remote" debugging is to:
remoteboolean tofalse(or not at all)...which seems counter-intuitivetargetfield includingextended-remote(e.g.,extended-remote 1.2.3.4:6789)From a user perspective, it seems odd that for
extended-remotedebugging, you would not set theremoteboolean. Additionally, having thetargetcommands be different (where one requires theextended-remote, but the other doesn't require theremote) at the beginning is also inconsistent.It would seem that the
remoteboolean could go away (i.e., deprecate the option) and that the regular remote debugging could just be specified in the same way that the extended remote is, with aremoteprefix in thetargetproperty. I think, at least from a user perspective, this would seem more consistent.Additionally, internally the paths seem to needlessly diverge since the
extended-remoteis processed viaMI2::attach, whereas the regularremoteis processed viaMI2::connect. It would seem the logic for both of these could be very similar internally.Furthermore, standardizing on this might better position the extension to support other capabilities in the future, such as loading a core file (i.e.,
target-select core <file>).