diff options
author | Simon Marchi <simon.marchi@polymtl.ca> | 2017-03-13 18:51:40 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@ericsson.com> | 2017-03-13 18:51:40 -0400 |
commit | edb5fb00a6865884f99be01a9e97f44243a9deb9 (patch) | |
tree | 64c58626dd35d50e9104181c502aa52157d33723 | |
parent | 551196862e4e9dfda510f59c53b0a3ff3153e4ed (diff) | |
download | gdb-edb5fb00a6865884f99be01a9e97f44243a9deb9.zip gdb-edb5fb00a6865884f99be01a9e97f44243a9deb9.tar.gz gdb-edb5fb00a6865884f99be01a9e97f44243a9deb9.tar.bz2 |
aix-thread: Use ptid from regcache instead of inferior_ptid
gdb/ChangeLog:
* aix-thread.c (aix_thread_fetch_registers,
aix_thread_store_registers): Use regcache->ptid instead of
inferior_ptid.
-rw-r--r-- | gdb/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/aix-thread.c | 14 |
2 files changed, 13 insertions, 7 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index ea293a4..d49f96f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,11 @@ 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca> + * aix-thread.c (aix_thread_fetch_registers, + aix_thread_store_registers): Use regcache->ptid instead of + inferior_ptid. + +2017-03-13 Simon Marchi <simon.marchi@polymtl.ca> + * aarch64-linux-nat.c (fetch_gregs_from_thread, store_gregs_to_thread, fetch_fpregs_from_thread, store_fpregs_to_thread): Use regcache->ptid instead of diff --git a/gdb/aix-thread.c b/gdb/aix-thread.c index cf1a462..3fbe96a 100644 --- a/gdb/aix-thread.c +++ b/gdb/aix-thread.c @@ -1297,8 +1297,8 @@ fetch_regs_kernel_thread (struct regcache *regcache, int regno, } } -/* Fetch register REGNO if != -1 or all registers otherwise in the - thread/process specified by inferior_ptid. */ +/* Fetch register REGNO if != -1 or all registers otherwise from the + thread/process connected to REGCACHE. */ static void aix_thread_fetch_registers (struct target_ops *ops, @@ -1308,11 +1308,11 @@ aix_thread_fetch_registers (struct target_ops *ops, pthdb_tid_t tid; struct target_ops *beneath = find_target_beneath (ops); - if (!PD_TID (inferior_ptid)) + if (!PD_TID (regcache_get_ptid (regcache))) beneath->to_fetch_registers (beneath, regcache, regno); else { - thread = find_thread_ptid (inferior_ptid); + thread = find_thread_ptid (regcache_get_ptid (regcache)); tid = thread->priv->tid; if (tid == PTHDB_INVALID_TID) @@ -1652,7 +1652,7 @@ store_regs_kernel_thread (const struct regcache *regcache, int regno, } /* Store gdb's current view of the register set into the - thread/process specified by inferior_ptid. */ + thread/process connected to REGCACHE. */ static void aix_thread_store_registers (struct target_ops *ops, @@ -1662,11 +1662,11 @@ aix_thread_store_registers (struct target_ops *ops, pthdb_tid_t tid; struct target_ops *beneath = find_target_beneath (ops); - if (!PD_TID (inferior_ptid)) + if (!PD_TID (regcache_get_ptid (regcache))) beneath->to_store_registers (beneath, regcache, regno); else { - thread = find_thread_ptid (inferior_ptid); + thread = find_thread_ptid (regcache_get_ptid (regcache)); tid = thread->priv->tid; if (tid == PTHDB_INVALID_TID) |