aboutsummaryrefslogtreecommitdiff
path: root/gdb/regcache.c
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2015-05-13 20:47:33 +0200
committerJan Kratochvil <jan.kratochvil@redhat.com>2015-05-13 20:50:11 +0200
commitbd49952bd7fbe616e2cb488e8080502f2338aaa2 (patch)
treedcd35ad3616260cc411e808fc451f8b8537876ef /gdb/regcache.c
parent46c03469b37d2ccb6a1eaa3ea4e21c57d07246fc (diff)
downloadfsf-binutils-gdb-bd49952bd7fbe616e2cb488e8080502f2338aaa2.zip
fsf-binutils-gdb-bd49952bd7fbe616e2cb488e8080502f2338aaa2.tar.gz
fsf-binutils-gdb-bd49952bd7fbe616e2cb488e8080502f2338aaa2.tar.bz2
Make regcache_cpy_no_passthrough static
regcache_cpy_no_passthrough is no longer used for a standalone call. gdb/ChangeLog 2015-05-13 Jan Kratochvil <jan.kratochvil@redhat.com> * regcache.c (regcache_cpy_no_passthrough): New declaration. (regcache_cpy_no_passthrough): Make it static, add function comment. * regcache.h (regcache_dup, regcache_cpy): Reduce/update their comment. (regcache_cpy_no_passthrough): Remove declaration.
Diffstat (limited to 'gdb/regcache.c')
-rw-r--r--gdb/regcache.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/gdb/regcache.c b/gdb/regcache.c
index 366eba0..86e648a 100644
--- a/gdb/regcache.c
+++ b/gdb/regcache.c
@@ -391,6 +391,9 @@ do_cooked_read (void *src, int regnum, gdb_byte *buf)
return regcache_cooked_read (regcache, regnum, buf);
}
+static void regcache_cpy_no_passthrough (struct regcache *dst,
+ struct regcache *src);
+
void
regcache_cpy (struct regcache *dst, struct regcache *src)
{
@@ -407,7 +410,12 @@ regcache_cpy (struct regcache *dst, struct regcache *src)
regcache_cpy_no_passthrough (dst, src);
}
-void
+/* Copy/duplicate the contents of a register cache. Unlike regcache_cpy,
+ which is pass-through, this does not go through to the target.
+ Only values values already in the cache are transferred. The SRC and DST
+ buffers must not overlap. */
+
+static void
regcache_cpy_no_passthrough (struct regcache *dst, struct regcache *src)
{
gdb_assert (src != NULL && dst != NULL);