aboutsummaryrefslogtreecommitdiff
path: root/gdb/rs6000-aix-tdep.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2023-01-31 14:38:30 -0700
committerTom Tromey <tom@tromey.com>2023-02-13 15:22:16 -0700
commitefaf1ae025cbef5438d2fe943dd010b773d757ac (patch)
treed51e1d379430439462d5cb1358c642e679647f12 /gdb/rs6000-aix-tdep.c
parentcdf3de175d41acec85d6c3cc8b599f79658edb06 (diff)
downloadgdb-efaf1ae025cbef5438d2fe943dd010b773d757ac.zip
gdb-efaf1ae025cbef5438d2fe943dd010b773d757ac.tar.gz
gdb-efaf1ae025cbef5438d2fe943dd010b773d757ac.tar.bz2
Turn remaining value_contents functions into methods
This turns the remaining value_contents functions -- value_contents, value_contents_all, value_contents_for_printing, and value_contents_for_printing_const -- into methods of value. It also converts the static functions require_not_optimized_out and require_available to be private methods. Approved-By: Simon Marchi <simon.marchi@efficios.com>
Diffstat (limited to 'gdb/rs6000-aix-tdep.c')
-rw-r--r--gdb/rs6000-aix-tdep.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/gdb/rs6000-aix-tdep.c b/gdb/rs6000-aix-tdep.c
index 579f85f..15602c8 100644
--- a/gdb/rs6000-aix-tdep.c
+++ b/gdb/rs6000-aix-tdep.c
@@ -367,7 +367,7 @@ rs6000_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
gdb_assert (len <= 8);
- target_float_convert (value_contents (arg).data (), type, reg_val,
+ target_float_convert (arg->contents ().data (), type, reg_val,
reg_type);
regcache->cooked_write (fp_regnum, reg_val);
++f_argno;
@@ -382,7 +382,7 @@ rs6000_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
gdb_byte word[PPC_MAX_REGISTER_SIZE];
memset (word, 0, reg_size);
memcpy (word,
- ((char *) value_contents (arg).data ()) + argbytes,
+ ((char *) arg->contents ().data ()) + argbytes,
(len - argbytes) > reg_size
? reg_size : len - argbytes);
regcache->cooked_write (tdep->ppc_gp0_regnum + 3 + ii, word);
@@ -406,9 +406,9 @@ rs6000_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
|| type->code () == TYPE_CODE_CHAR)
/* Sign or zero extend the "int" into a "word". */
store_unsigned_integer (word, reg_size, byte_order,
- unpack_long (type, value_contents (arg).data ()));
+ unpack_long (type, arg->contents ().data ()));
else
- memcpy (word, value_contents (arg).data (), len);
+ memcpy (word, arg->contents ().data (), len);
regcache->cooked_write (tdep->ppc_gp0_regnum + 3 +ii, word);
}
++argno;
@@ -469,7 +469,7 @@ ran_out_of_registers_for_arguments:
if (argbytes)
{
write_memory (sp + 24 + (ii * 4),
- value_contents (arg).data () + argbytes,
+ arg->contents ().data () + argbytes,
len - argbytes);
++argno;
ii += ((len - argbytes + 3) & -4) / 4;
@@ -492,11 +492,11 @@ ran_out_of_registers_for_arguments:
gdb_assert (len <= 8);
regcache->cooked_write (tdep->ppc_fp0_regnum + 1 + f_argno,
- value_contents (arg).data ());
+ arg->contents ().data ());
++f_argno;
}
- write_memory (sp + 24 + (ii * 4), value_contents (arg).data (), len);
+ write_memory (sp + 24 + (ii * 4), arg->contents ().data (), len);
ii += ((len + 3) & -4) / 4;
}
}