* [rfc] [09/15] Add gdbarch to register_name callback in score-tdep.c
@ 2007-10-31 10:48 Markus Deuling
0 siblings, 0 replies; only message in thread
From: Markus Deuling @ 2007-10-31 10:48 UTC (permalink / raw)
To: GDB Patches; +Cc: Ulrich Weigand, qinwei
[-- Attachment #1: Type: text/plain, Size: 333 bytes --]
Hi,
this patch adds gdbarch to register_name callback in score-tdep.c
Is this ok to commit?
ChangeLog:
* score-tdep.c (score_register_name): Add gdbarch parameter.
(score_return_value, score_push_dummy_call): Replace current_gdbarch
by gdbarch.
--
Markus Deuling
GNU Toolchain for Linux on Cell BE
deuling@de.ibm.com
[-- Attachment #2: diff-score-tdep --]
[-- Type: text/plain, Size: 1695 bytes --]
diff -urpN src/gdb/score-tdep.c dev/gdb/score-tdep.c
--- src/gdb/score-tdep.c 2007-08-23 20:08:37.000000000 +0200
+++ dev/gdb/score-tdep.c 2007-10-30 13:45:43.000000000 +0100
@@ -284,7 +284,7 @@ score_unwind_sp (struct gdbarch *gdbarch
}
static const char *
-score_register_name (int regnum)
+score_register_name (struct gdbarch *gdbarch, int regnum)
{
const char *score_register_names[] = {
"r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7",
@@ -433,7 +433,7 @@ score_return_value (struct gdbarch *gdba
if (offset + xfer > TYPE_LENGTH (type))
xfer = TYPE_LENGTH (type) - offset;
score_xfer_register (regcache, regnum, xfer,
- gdbarch_byte_order (current_gdbarch),
+ gdbarch_byte_order (gdbarch),
readbuf, writebuf, offset);
}
return RETURN_VALUE_REGISTER_CONVENTION;
@@ -543,7 +543,7 @@ score_push_dummy_call (struct gdbarch *g
Where X is a hole. */
- if (gdbarch_byte_order (current_gdbarch) == BFD_ENDIAN_BIG
+ if (gdbarch_byte_order (gdbarch) == BFD_ENDIAN_BIG
&& (typecode == TYPE_CODE_STRUCT
|| typecode == TYPE_CODE_UNION)
&& argreg > SCORE_LAST_ARG_REGNUM
@@ -557,7 +557,7 @@ score_push_dummy_call (struct gdbarch *g
/* The last part of a arg should shift left when
gdbarch_byte_order is BFD_ENDIAN_BIG. */
- if (gdbarch_byte_order (current_gdbarch) == BFD_ENDIAN_BIG
+ if (gdbarch_byte_order (gdbarch) == BFD_ENDIAN_BIG
&& arg_last_part_p == 1
&& (typecode == TYPE_CODE_STRUCT
|| typecode == TYPE_CODE_UNION))
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-10-31 10:47 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-31 10:48 [rfc] [09/15] Add gdbarch to register_name callback in score-tdep.c Markus Deuling
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox