aboutsummaryrefslogtreecommitdiff
path: root/gdb/ppc-linux-tdep.c
diff options
context:
space:
mode:
authorYao Qi <yao.qi@linaro.org>2017-11-02 15:15:42 +0000
committerYao Qi <yao.qi@linaro.org>2017-11-02 15:15:42 +0000
commitf26ae15b471aaddee81d9d6c03af1cb0f2081735 (patch)
treea4c1114f2089ec6e0ea63653eb26978e2d3c6fc5 /gdb/ppc-linux-tdep.c
parent6c6e9412e930c96f48b8ee78a389437328f5283c (diff)
downloadgdb-f26ae15b471aaddee81d9d6c03af1cb0f2081735.zip
gdb-f26ae15b471aaddee81d9d6c03af1cb0f2081735.tar.gz
gdb-f26ae15b471aaddee81d9d6c03af1cb0f2081735.tar.bz2
Construct readonly regcache without address space
The address space is useless to readonly regcache, so this patch removes the parameter to construct readonly regcache. address_space was added in regcache by 6c95b8d, but for read-write regcache. regcache::aspace is used for various breakpoint/watchpoint checking, and these regcache are not read-only regcache. gdb: 2017-11-02 Yao Qi <yao.qi@linaro.org> * frame.c (do_frame_register_read): Remove aspace. * jit.c (jit_frame_sniffer): Likwise. * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise. * regcache.c (regcache::regcache): Pass nullptr. (regcache_print): Caller updated. * regcache.h (regcache::regcache): Remove one constructor parameter aspace.
Diffstat (limited to 'gdb/ppc-linux-tdep.c')
-rw-r--r--gdb/ppc-linux-tdep.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/gdb/ppc-linux-tdep.c b/gdb/ppc-linux-tdep.c
index d01cff8..847908a 100644
--- a/gdb/ppc-linux-tdep.c
+++ b/gdb/ppc-linux-tdep.c
@@ -1361,10 +1361,9 @@ ppu2spu_sniffer (const struct frame_unwind *self,
{
struct ppu2spu_cache *cache
= FRAME_OBSTACK_CALLOC (1, struct ppu2spu_cache);
-
- const address_space *aspace = get_frame_address_space (this_frame);
std::unique_ptr<struct regcache> regcache
- (new struct regcache (data.gdbarch, aspace));
+ (new struct regcache (data.gdbarch));
+
regcache_save (regcache.get (), ppu2spu_unwind_register, &data);
cache->frame_id = frame_id_build (base, func);