https://bugs.kde.org/show_bug.cgi?id=473687

            Bug ID: 473687
           Summary: Implement qDefaultExecAndArgs and qMachineId for vgdb
    Classification: Developer tools
           Product: valgrind
           Version: unspecified
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: jsew...@acm.org
          Reporter: m...@klomp.org
                CC: ahajk...@redhat.com
  Target Milestone: ---

qDefaultExecAndArgs and qMachineId are proposed new gdb remote packets
described in this gdb patch series:
https://inbox.sourceware.org/gdb-patches/cover.1692200989.git.aburg...@redhat.com/

The implementation of qDefaultExecAndArgs is trivial (since we don't have any,
we just return "U"):

diff --git a/coregrind/vgdb.c b/coregrind/vgdb.c
index c024ffca6..59c9bb4b4 100644
--- a/coregrind/vgdb.c
+++ b/coregrind/vgdb.c
@@ -1354,6 +1354,7 @@ void do_multi_mode(int check_trials, int in_port)
 #define QENVIRONMENTUNSET "QEnvironmentUnset"
 #define QSETWORKINGDIR "QSetWorkingDir"
 #define QTSTATUS "qTStatus"
+#define QDEFAULTEXECANDARGS "qDefaultExecAndArgs"

        if (strncmp(QSUPPORTED, buf, strlen(QSUPPORTED)) == 0) {
           DEBUG(1, "CASE %s\n", QSUPPORTED);
@@ -1600,6 +1601,10 @@ void do_multi_mode(int check_trials, int in_port)
           DEBUG(1, "Got qfThreadInfo\n");
           /* There are no threads yet, reply 'l' end of list. */
           send_packet ("l", noackmode);
+       } else if (strcmp(QDEFAULTEXECANDARGS, buf) == 0) {
+          DEBUG(1, "Got qDefaultExecAndArgs\n");
+          /* We don't have any.  */
+          send_packet ("U", noackmode);
        } else if (buf[0] != '\0') {
           // We didn't understand.
           DEBUG(1, "Unknown packet received: '%s'\n", buf);

This immediately makes run/start work without having to set remote exec-file.

qMachineId is a bit more complicated, but would automatically set sysroot to /

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to