Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Michael Snyder <msnyder@vmware.com>
To: Jakob Engblom <jakob@virtutech.com>
Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Subject: Re: GDB MI Reverse Commands added [1 of 3]
Date: Thu, 27 Aug 2009 01:13:00 -0000	[thread overview]
Message-ID: <4A95D7A0.6070509@vmware.com> (raw)
In-Reply-To: <00ce01ca265a$ccb66ca0$662345e0$@com>

Jakob Engblom wrote:
> Here are the patches adding the MI commands for reverse execution to gdb.
> 
> Changelog entry: "Added reverse debugging support to gdb MI"

Jakob, thanks for this contribution.  We need an actual
contributor's name for the changelog!  Here's the format:


2009-06-17  Ulrich Weigand  <uweigand@de.ibm.com>

	* mi/mi-main.c (mi_cmd_data_list_register_names): Use selected
	frame architecture instead of current_gdbarch.
	(mi_cmd_data_list_changed_registers): Likewise.
	(mi_cmd_data_list_register_values): Likewise.  Pass selected
	frame to get_register.

By the way, some of these changes don't actually seem to change 
anything.  I guess we can apply them as is, but could you just
check to see if something went wrong or got left out?

I'm looking at for instance these...



> *************** mi_cmd_exec_interrupt (char *command, ch
> *** 252,258 ****
>       {
>         if (!any_running ())
>         error ("Inferior not running.");
> !
>         interrupt_target_1 (1);
>       }
>     else if (argc == 2 && strcmp (argv[0], "--thread-group") == 0)
> --- 307,313 ----
>       {
>         if (!any_running ())
>         error ("Inferior not running.");
> !
>         interrupt_target_1 (1);
>       }
>     else if (argc == 2 && strcmp (argv[0], "--thread-group") == 0)
> *************** void
> *** 349,355 ****
>   mi_cmd_thread_info (char *command, char **argv, int argc)
>   {
>     int thread = -1;
> !
>     if (argc != 0 && argc != 1)
>       error ("Invalid MI command");
> 
> --- 404,410 ----
>   mi_cmd_thread_info (char *command, char **argv, int argc)
>   {
>     int thread = -1;
> !
>     if (argc != 0 && argc != 1)
>       error ("Invalid MI command");
> 
> *************** print_one_inferior (struct inferior *inf
> *** 367,373 ****
>     ui_out_field_fmt (uiout, "id", "%d", inferior->pid);
>     ui_out_field_string (uiout, "type", "process");
>     ui_out_field_int (uiout, "pid", inferior->pid);
> !
>     do_cleanups (back_to);
>     return 0;
>   }
> --- 422,428 ----
>     ui_out_field_fmt (uiout, "id", "%d", inferior->pid);
>     ui_out_field_string (uiout, "type", "process");
>     ui_out_field_int (uiout, "pid", inferior->pid);
> !
>     do_cleanups (back_to);
>     return 0;
>   }
> *************** mi_cmd_list_thread_groups (char *command
> *** 433,446 ****
>         int pid = atoi (id);
>         if (!in_inferior_list (pid))
>         error ("Invalid thread group id '%s'", id);
> !       print_thread_info (uiout, -1, pid);
>       }
>     else
>       {
>         make_cleanup_ui_out_list_begin_end (uiout, "groups");
>         iterate_over_inferiors (print_one_inferior, NULL);
>       }
> !
>     do_cleanups (back_to);
>   }
> 
> --- 488,501 ----
>         int pid = atoi (id);
>         if (!in_inferior_list (pid))
>         error ("Invalid thread group id '%s'", id);
> !       print_thread_info (uiout, -1, pid);
>       }
>     else
>       {
>         make_cleanup_ui_out_list_begin_end (uiout, "groups");
>         iterate_over_inferiors (print_one_inferior, NULL);
>       }
> !
>     do_cleanups (back_to);
>   }
> 
> *************** get_register (struct frame_info *frame,
> *** 713,719 ****
>   }
> 
>   /* Write given values into registers. The registers and values are
> !    given as pairs.  The corresponding MI command is
>      -data-write-register-values <format> [<regnum1> <value1>...<regnumN>
> <valueN>]*/
>   void
>   mi_cmd_data_write_register_values (char *command, char **argv, int argc)
> --- 768,774 ----
>   }
> 
>   /* Write given values into registers. The registers and values are
> !    given as pairs.  The corresponding MI command is
>      -data-write-register-values <format> [<regnum1> <value1>...<regnumN>
> <valueN>]*/
>   void
>   mi_cmd_data_write_register_values (char *command, char **argv, int argc)
> *************** mi_cmd_data_evaluate_expression (char *c
> *** 810,816 ****
>   /* DATA-MEMORY-READ:
> 
>      ADDR: start address of data to be dumped.
> !    WORD-FORMAT: a char indicating format for the ``word''.  See
>      the ``x'' command.
>      WORD-SIZE: size of each ``word''; 1,2,4, or 8 bytes.
>      NR_ROW: Number of rows.
> --- 865,871 ----
>   /* DATA-MEMORY-READ:
> 
>      ADDR: start address of data to be dumped.
> !    WORD-FORMAT: a char indicating format for the ``word''.  See
>      the ``x'' command.
>      WORD-SIZE: size of each ``word''; 1,2,4, or 8 bytes.
>      NR_ROW: Number of rows.
> *************** mi_cmd_data_evaluate_expression (char *c
> *** 823,829 ****
> 
>      {addr="...",rowN={wordN="..." ,... [,ascii="..."]}, ...}
> 
> !    Returns:
>      The number of bytes read is SIZE*ROW*COL. */
> 
>   void
> --- 878,884 ----
> 
>      {addr="...",rowN={wordN="..." ,... [,ascii="..."]}, ...}
> 
> !    Returns:
>      The number of bytes read is SIZE*ROW*COL. */
> 
>   void
> *************** mi_cmd_data_read_memory (char *command,
> *** 1019,1025 ****
>      ADDR: start address of the row in the memory grid where the memory
>      cell is, if OFFSET_COLUMN is specified.  Otherwise, the address of
>      the location to write to.
> !    FORMAT: a char indicating format for the ``word''.  See
>      the ``x'' command.
>      WORD_SIZE: size of each ``word''; 1,2,4, or 8 bytes
>      VALUE: value to be written into the memory address.
> --- 1074,1080 ----
>      ADDR: start address of the row in the memory grid where the memory
>      cell is, if OFFSET_COLUMN is specified.  Otherwise, the address of
>      the location to write to.
> !    FORMAT: a char indicating format for the ``word''.  See
>      the ``x'' command.
>      WORD_SIZE: size of each ``word''; 1,2,4, or 8 bytes
>      VALUE: value to be written into the memory address.
> *************** mi_cmd_enable_timings (char *command, ch
> *** 1112,1118 ****
>       }
>     else
>       goto usage_error;
> !
>     return;
> 
>    usage_error:
> --- 1167,1173 ----
>       }
>     else
>       goto usage_error;
> !
>     return;
> 
>    usage_error:
> *************** mi_cmd_list_features (char *command, cha
> *** 1125,1140 ****
>     if (argc == 0)
>       {
>         struct cleanup *cleanup = NULL;
> !       cleanup = make_cleanup_ui_out_list_begin_end (uiout, "features");
> 
>         ui_out_field_string (uiout, NULL, "frozen-varobjs");
>         ui_out_field_string (uiout, NULL, "pending-breakpoints");
>         ui_out_field_string (uiout, NULL, "thread-info");
> !
>   #if HAVE_PYTHON
>         ui_out_field_string (uiout, NULL, "python");
>   #endif
> !
>         do_cleanups (cleanup);
>         return;
>       }
> --- 1180,1195 ----
>     if (argc == 0)
>       {
>         struct cleanup *cleanup = NULL;
> !       cleanup = make_cleanup_ui_out_list_begin_end (uiout, "features");
> 
>         ui_out_field_string (uiout, NULL, "frozen-varobjs");
>         ui_out_field_string (uiout, NULL, "pending-breakpoints");
>         ui_out_field_string (uiout, NULL, "thread-info");
> !
>   #if HAVE_PYTHON
>         ui_out_field_string (uiout, NULL, "python");
>   #endif
> !
>         do_cleanups (cleanup);
>         return;
>       }
> *************** mi_cmd_list_target_features (char *comma
> *** 1148,1158 ****
>     if (argc == 0)
>       {
>         struct cleanup *cleanup = NULL;
> !       cleanup = make_cleanup_ui_out_list_begin_end (uiout, "features");
> 
>         if (target_can_async_p ())
>         ui_out_field_string (uiout, NULL, "async");
> !
>         do_cleanups (cleanup);
>         return;
>       }
> --- 1203,1213 ----
>     if (argc == 0)
>       {
>         struct cleanup *cleanup = NULL;
> !       cleanup = make_cleanup_ui_out_list_begin_end (uiout, "features");
> 
>         if (target_can_async_p ())
>         ui_out_field_string (uiout, NULL, "async");
> !
>         do_cleanups (cleanup);
>         return;
>       }


... and so on...


  reply	other threads:[~2009-08-27  0:46 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-26 14:38 Jakob Engblom
2009-08-27  1:13 ` Michael Snyder [this message]
2009-08-31 13:26   ` Jakob Engblom
2009-08-31 19:56     ` Michael Snyder
2009-09-01  6:37       ` Jakob Engblom
2009-09-01 19:08         ` Michael Snyder
2009-08-27  2:06 ` Michael Snyder
2009-08-31 13:15   ` Jakob Engblom
2009-08-31 20:29   ` Tom Tromey
2009-09-02  8:16   ` Vladimir Prus
2009-09-10 21:09     ` Michael Snyder
2009-09-10 21:10       ` Michael Snyder
2010-01-13 20:32     ` Jakob Engblom
2010-01-13 20:36       ` Vladimir Prus
2010-01-13 20:44         ` Michael Snyder
2009-12-15 19:39   ` Michael Snyder
2009-12-16  7:54     ` Vladimir Prus
2009-12-16  7:57       ` Vladimir Prus
2009-12-17 14:40         ` Jakob Engblom
2009-12-21 10:06           ` Vladimir Prus
2009-12-22 11:34             ` Jakob Engblom
2009-12-22 11:48               ` Vladimir Prus
2010-01-13 13:15                 ` Jakob Engblom
2009-12-22 18:22               ` Michael Snyder
2010-01-13 13:16                 ` Jakob Engblom
2010-02-12 21:33                 ` Michael Snyder
2009-08-27  3:11 ` Hui Zhu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4A95D7A0.6070509@vmware.com \
    --to=msnyder@vmware.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jakob@virtutech.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox