Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [RFA] Patch to fix reverse return from subroutine error
@ 2009-06-11  8:27 Hui Zhu
  2009-06-27 18:59 ` Michael Snyder
  0 siblings, 1 reply; 9+ messages in thread
From: Hui Zhu @ 2009-06-11  8:27 UTC (permalink / raw)
  To: gdb-patches ml; +Cc: Michael Snyder, Marc Khouzam

[-- Attachment #1: Type: text/plain, Size: 661 bytes --]

Hi,

This patch is to fix bug in http://sourceware.org/ml/gdb/2009-06/msg00089.html

2009-06-11  Hui Zhu  <teawater@gmail.com>

	* infrun.c (handle_inferior_event): Reverse return from
	subroutine doesn't use code "infrun: stepped into subroutine".

There still are 3 reverse patches like it need be review:
http://sourceware.org/ml/gdb-patches/2009-05/msg00103.html
http://sourceware.org/ml/gdb-patches/2009-05/msg00104.html
http://sourceware.org/ml/gdb-patches/2009-05/msg00105.html

And other one need to be comment:
http://sourceware.org/ml/gdb-patches/2009-05/msg00078.html

Maybe some nice people can spend sometime on these poor babies.  :)

Thanks,
Hui

[-- Attachment #2: fix-reverse-return-from-subroutine.txt --]
[-- Type: text/plain, Size: 740 bytes --]

---
 infrun.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

--- a/infrun.c
+++ b/infrun.c
@@ -3708,7 +3708,12 @@ infrun: not switching back to stepped th
 		    ecs->event_thread->step_frame_id)
       && (frame_id_eq (frame_unwind_id (get_current_frame ()),
 		       ecs->event_thread->step_frame_id)
-	  || execution_direction == EXEC_REVERSE))
+	  || (execution_direction == EXEC_REVERSE
+	      && ecs->event_thread->step_frame_id.stack_addr_p
+	      && get_frame_id (get_current_frame ()).stack_addr_p
+              && !gdbarch_inner_than (current_gdbarch,
+				      ecs->event_thread->step_frame_id.stack_addr,
+				      get_frame_id (get_current_frame()).stack_addr))))
     {
       CORE_ADDR real_stop_pc;
 

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

end of thread, other threads:[~2009-06-29  0:38 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-11  8:27 [RFA] Patch to fix reverse return from subroutine error Hui Zhu
2009-06-27 18:59 ` Michael Snyder
2009-06-27 19:48   ` Pedro Alves
2009-06-27 19:56     ` Daniel Jacobowitz
2009-06-27 20:59     ` Michael Snyder
2009-06-27 21:12       ` Daniel Jacobowitz
2009-06-28 18:46         ` Michael Snyder
2009-06-28 21:09           ` Daniel Jacobowitz
2009-06-29  0:38             ` Hui Zhu

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