|
Description
Ian Shillingford
New Gerrit change created: https://git.eclipse.org/r/123392 I don't know if we can get this in in time for 9.5 as we are already in the release candidate phase. If not it will be available in the nightly build for 9.6 soon (in a week or so, once 9.6 nightly builds start). Created attachment 274215 [details] extended remote screenshot I have submitted a possible implementation. There is some new API. So for the N&N into whichever version it goes: Feature change: extended-remote mode for GDB Hardware Debugging - When debugging with the GDB Hardware Debugging launch configuration users can now specify whether to use "extended-remote" mode when connecting to the target. <screenshot> See Bug 535143. API change: Extensions of the org.eclipse.cdt.debug.gdbjtag.core.JTagDevice extension point can now optionally implement the IGDBJtagConnection2 interface to provide commands to do a GDB extended-remote mode connection and control how the "Use extended-remote mode" checkbox is presented to the user in the Launch Configuration. Too late for 9.5. Relates to bug 535163. I will revisit this bug in the coming week to make an appropriate update to target milestone. This bug was assigned and targeted at a now released milestone. As that milestone has now passed, the milestone field has been cleared. If this bug has been fixed, please set the milestone to the version it was fixed in and marked the bug as resolved. Jonah and all, looking at this with fresh eyes. I think it might be preferable to generalize for any remote connection type (protocol). That way, an extender could support exotic/legacy protocols such as "rdi", "kvm", something in-house, or some future mainline GDB protocol.
We could add a new method to the existing IGDBJtagConnection interface:
default void doTarget(String protocol, String connection, Collection<String> commands) {
if ("remote".equals(protocol)) {
doRemote(connection, commands);
} // else not supported
}
The DefaultGDBJtagConnectionImpl.doTarget() implementation would support any protocol. Some of the existing "JTAG device" implementations would support both "remote" and "extended-remote" protocols.
The UI would allow selection of the protocol from a drop-down list. The content of that list would be updated on "JTAG device" selection change. The default protocol would be be the zeroth item in the protocol list.
We could describe the ordered list of supported protocols in XML by extending the JtagDevice schema in a compatible manner (default to "remote" only if not specified):
<device protocols="remote,extended-remote" ... >
This seems a bit more elegant than using another new IGDBJtagConnection interface method:
default Collection<String> getProtocols() {
return List.of("remote");
}
because the list of supported protocols has some affinity with the default connection string that is also provided by XML.
In the case of the BlackMagic probe, only the "extended-remote" protocol would be listed in the JtagDevice XML and so the correct protocol would be selected when the BlackMagic probe is selected.
Comments?
(In reply to John Dallaway from comment #8) > Comments? @John - your idea seems sounds. (In reply to Jonah Graham from comment #9) > (In reply to John Dallaway from comment #8) > > Comments? > > @John - your idea seems sounds. @John, I 2nd what Jonah wrote. Created attachment 288463 [details]
Target protocol selection screenshot
New Gerrit change created: https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192863 Gerrit change https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192863 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=90627bfa830f27f12646637bb30865d8a9f2ed13 New Gerrit change created: https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192874 Gerrit change https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192874 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=38ff9d67eaca40b91a7a9631ba4a3311e7271de8 New Gerrit change created: https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192882 Gerrit change https://git.eclipse.org/r/c/cdt/org.eclipse.cdt/+/192882 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=e16e7ea5cb30f725027f71de641f61371688115c Thanks John! On behalf of the hardware debug community I am grateful for your ongoing maintenance of this part of the code base! |