Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH] Make "set disassemble-next-line on" can work with DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME
@ 2014-04-25  4:55 Hui Zhu
  2014-04-25 19:46 ` Pedro Alves
  0 siblings, 1 reply; 3+ messages in thread
From: Hui Zhu @ 2014-04-25  4:55 UTC (permalink / raw)
  To: gdb-patches ml

When GDB debug DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME, even if
"set disassemble-next-line on", it will not output the asm code:
(gdb) set disassemble-next-line on
(gdb) si
<signal handler called>
(gdb)
<signal handler called>
(gdb)
<signal handler called>

So make this patch make they can work together, it will become:
(gdb) si
<signal handler called>
=> 0xffffffff816bfb09 <int_with_check+0>:    65 48 8b 0c 25 c8 c7 00 
00    mov    %gs:0xc7c8,%rcx
(gdb)
<signal handler called>
=> 0xffffffff816bfb12 <int_with_check+9>:    48 81 e9 d8 1f 00 00   
  sub    $0x1fd8,%rcx
(gdb)
<signal handler called>
=> 0xffffffff816bfb19 <int_with_check+16>:    8b 51 10  mov    
0x10(%rcx),%edx

Thanks,
Hui

2014-04-25  Hui Zhu  <hui@codesourcery.com>

     * stack.c (print_frame_info): Call do_gdb_disassembly with
     DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME.

--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -836,6 +836,13 @@ print_frame_info (struct frame_info *fra
        ui_out_text (uiout, "\n");
        annotate_frame_end ();

+      /* If disassemble-next-line is set to auto or on output the next
+     instruction.  */
+      if (disassemble_next_line == AUTO_BOOLEAN_AUTO
+      || disassemble_next_line == AUTO_BOOLEAN_TRUE)
+    do_gdb_disassembly (get_frame_arch (frame), 1,
+                get_frame_pc (frame), get_frame_pc (frame) + 1);
+
        do_cleanups (uiout_cleanup);
        return;
      }


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Make "set disassemble-next-line on" can work with DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME
  2014-04-25  4:55 [PATCH] Make "set disassemble-next-line on" can work with DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME Hui Zhu
@ 2014-04-25 19:46 ` Pedro Alves
  2014-04-27 14:27   ` Hui Zhu
  0 siblings, 1 reply; 3+ messages in thread
From: Pedro Alves @ 2014-04-25 19:46 UTC (permalink / raw)
  To: Hui Zhu; +Cc: gdb-patches ml

On 04/25/2014 05:55 AM, Hui Zhu wrote:

> 2014-04-25  Hui Zhu  <hui@codesourcery.com>
> 
>      * stack.c (print_frame_info): Call do_gdb_disassembly with
>      DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME.

OK, thanks.

-- 
Pedro Alves


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Make "set disassemble-next-line on" can work with DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME
  2014-04-25 19:46 ` Pedro Alves
@ 2014-04-27 14:27   ` Hui Zhu
  0 siblings, 0 replies; 3+ messages in thread
From: Hui Zhu @ 2014-04-27 14:27 UTC (permalink / raw)
  To: Pedro Alves; +Cc: Hui Zhu, gdb-patches ml

On Sat, Apr 26, 2014 at 3:46 AM, Pedro Alves <palves@redhat.com> wrote:
> On 04/25/2014 05:55 AM, Hui Zhu wrote:
>
>> 2014-04-25  Hui Zhu  <hui@codesourcery.com>
>>
>>      * stack.c (print_frame_info): Call do_gdb_disassembly with
>>      DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME.
>
> OK, thanks.

Commited as https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=433e77fad1fda55408db072de18dcd4f9116289e

Thanks,
Hui

>
> --
> Pedro Alves


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-04-27 14:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-04-25  4:55 [PATCH] Make "set disassemble-next-line on" can work with DUMMY_FRAME, SIGTRAMP_FRAME and ARCH_FRAME Hui Zhu
2014-04-25 19:46 ` Pedro Alves
2014-04-27 14:27   ` Hui Zhu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox