GDB: S12Z: Add assertion
authorJohn Darrington <john@darrington.wattle.id.au>
Thu, 8 Nov 2018 16:51:22 +0000 (17:51 +0100)
committerJohn Darrington <john@darrington.wattle.id.au>
Tue, 20 Nov 2018 06:36:24 +0000 (07:36 +0100)
gdb/ChangeLog:

* s12z-tdep.c (s12z_frame_cache): Add an assertion.

gdb/ChangeLog
gdb/s12z-tdep.c

index f2b6f5633c0265686f9694faadb1a02c1f954332..252ef5817d03c91f04c1f2ce334318dba9cfb948 100644 (file)
@@ -1,3 +1,7 @@
+2018-11-19  John Darrington <john@darrington.wattle.id.au>
+
+       *s12z-tdep.c (s12z_frame_cache): Add an assertion.
+
 2018-11-19  Simon Marchi  <simon.marchi@polymtl.ca>
 
        * infrun.c (displaced_step_inferior_state) <next>: Remove.
index 79f5772035db09d91b081192bfa9b19ee65c59ef..bd0bd7c0011fb46282801b1d464a21e3ac853220 100644 (file)
@@ -320,6 +320,7 @@ s12z_frame_cache (struct frame_info *this_frame, void **prologue_cache)
     }
   else
     {
+      gdb_assert (this_sp == this_sp_for_id);
       /* The stack pointer of the prev frame is frame_size greater
          than the stack pointer of this frame plus one address
          size (caused by the JSR or BSR).  */