]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/infrun.c
* regcache.c (struct regcache): Add ptid_t member.
[thirdparty/binutils-gdb.git] / gdb / infrun.c
index ae530b77e212115361e7b6e0991b91dd063176f8..1557dc70f419e9d2216acdab1ec6b8fd83cfbddb 100644 (file)
@@ -528,7 +528,8 @@ resume (int step, enum target_signal sig)
   if (breakpoint_here_p (read_pc ()) == permanent_breakpoint_here)
     {
       if (gdbarch_skip_permanent_breakpoint_p (current_gdbarch))
-       gdbarch_skip_permanent_breakpoint (current_gdbarch, current_regcache);
+       gdbarch_skip_permanent_breakpoint (current_gdbarch,
+                                          get_current_regcache ());
       else
        error (_("\
 The program is stopped at a permanent breakpoint, but GDB does not know\n\
@@ -2077,7 +2078,8 @@ process_event_stop_test:
        remove_breakpoints ();
        breakpoints_inserted = 0;
        if (!gdbarch_get_longjmp_target_p (current_gdbarch)
-           || !gdbarch_get_longjmp_target (current_gdbarch, &jmp_buf_pc))
+           || !gdbarch_get_longjmp_target (current_gdbarch,
+                                           get_current_frame (), &jmp_buf_pc))
          {
            keep_going (ecs);
            return;
@@ -2456,9 +2458,10 @@ process_event_stop_test:
          function.  That's what tells us (a) whether we want to step
          into it at all, and (b) what prologue we want to run to the
          end of, if we do step into it.  */
-      real_stop_pc = skip_language_trampoline (stop_pc);
+      real_stop_pc = skip_language_trampoline (get_current_frame (), stop_pc);
       if (real_stop_pc == 0)
-       real_stop_pc = gdbarch_skip_trampoline_code (current_gdbarch, stop_pc);
+       real_stop_pc = gdbarch_skip_trampoline_code
+                        (current_gdbarch, get_current_frame (), stop_pc);
       if (real_stop_pc != 0)
        ecs->stop_func_start = real_stop_pc;
 
@@ -2520,8 +2523,9 @@ process_event_stop_test:
                                          stop_pc, ecs->stop_func_name))
     {
       /* Determine where this trampoline returns.  */
-      CORE_ADDR real_stop_pc = gdbarch_skip_trampoline_code
-                                (current_gdbarch, stop_pc);
+      CORE_ADDR real_stop_pc;
+      real_stop_pc = gdbarch_skip_trampoline_code
+                      (current_gdbarch, get_current_frame (), stop_pc);
 
       if (debug_infrun)
         fprintf_unfiltered (gdb_stdlog, "infrun: stepped into solib return tramp\n");
@@ -3215,7 +3219,7 @@ Further execution is probably impossible.\n"));
   if (proceed_to_finish)
     /* NB: The copy goes through to the target picking up the value of
        all the registers.  */
-    regcache_cpy (stop_registers, current_regcache);
+    regcache_cpy (stop_registers, get_current_regcache ());
 
   if (stop_stack_dummy)
     {
@@ -3672,7 +3676,7 @@ save_inferior_status (int restore_stack_info)
 
   inf_status->stop_registers = regcache_dup_no_passthrough (stop_registers);
 
-  inf_status->registers = regcache_dup (current_regcache);
+  inf_status->registers = regcache_dup (get_current_regcache ());
 
   inf_status->selected_frame_id = get_frame_id (get_selected_frame (NULL));
   return inf_status;
@@ -3727,7 +3731,7 @@ restore_inferior_status (struct inferior_status *inf_status)
      (and perhaps other times).  */
   if (target_has_execution)
     /* NB: The register write goes through to the target.  */
-    regcache_cpy (current_regcache, inf_status->registers);
+    regcache_cpy (get_current_regcache (), inf_status->registers);
   regcache_xfree (inf_status->registers);
 
   /* FIXME: If we are being called after stopping in a function which