/* Solaris threads debugging interface.
- Copyright (C) 1996-2019 Free Software Foundation, Inc.
+ Copyright (C) 1996-2020 Free Software Foundation, Inc.
This file is part of GDB.
/* See if we have a new thread. */
if (rtnval.tid_p () && rtnval != save_ptid)
{
- thread_info *thr = find_thread_ptid (rtnval);
+ thread_info *thr = find_thread_ptid (current_inferior (), rtnval);
if (thr == NULL || thr->state == THREAD_EXITED)
- add_thread (rtnval);
+ {
+ process_stratum_target *proc_target
+ = current_inferior ()->process_target ();
+ add_thread (proc_target, rtnval);
+ }
}
}
{
ptid_t ptid = ptid_t (inferior_ptid.pid (), lwpid, 0);
struct regcache *regcache
- = get_thread_arch_regcache (ptid, target_gdbarch ());
+ = get_thread_arch_regcache (current_inferior ()->process_target (),
+ ptid, target_gdbarch ());
target_fetch_registers (regcache, -1);
fill_gregset (regcache, (gdb_gregset_t *) gregset, -1);
{
ptid_t ptid = ptid_t (inferior_ptid.pid (), lwpid, 0);
struct regcache *regcache
- = get_thread_arch_regcache (ptid, target_gdbarch ());
+ = get_thread_arch_regcache (current_inferior ()->process_target (),
+ ptid, target_gdbarch ());
supply_gregset (regcache, (const gdb_gregset_t *) gregset);
target_store_registers (regcache, -1);
{
ptid_t ptid = ptid_t (inferior_ptid.pid (), lwpid, 0);
struct regcache *regcache
- = get_thread_arch_regcache (ptid, target_gdbarch ());
+ = get_thread_arch_regcache (current_inferior ()->process_target (),
+ ptid, target_gdbarch ());
target_fetch_registers (regcache, -1);
fill_fpregset (regcache, (gdb_fpregset_t *) fpregset, -1);
{
ptid_t ptid = ptid_t (inferior_ptid.pid (), lwpid, 0);
struct regcache *regcache
- = get_thread_arch_regcache (ptid, target_gdbarch ());
+ = get_thread_arch_regcache (current_inferior ()->process_target (),
+ ptid, target_gdbarch ());
supply_fpregset (regcache, (const gdb_fpregset_t *) fpregset);
target_store_registers (regcache, -1);
return -1;
ptid_t ptid = ptid_t (inferior_ptid.pid (), 0, ti.ti_tid);
- thread_info *thr = find_thread_ptid (ptid);
+ thread_info *thr = find_thread_ptid (current_inferior (), ptid);
if (thr == NULL || thr->state == THREAD_EXITED)
- add_thread (ptid);
+ {
+ process_stratum_target *proc_target
+ = current_inferior ()->process_target ();
+ add_thread (proc_target, ptid);
+ }
return 0;
}