From: Jim Blandy <jimb@redhat.com>
To: gdb-patches@sources.redhat.com
Subject: PATCH: provide comments for PowerPC sim regno functions
Date: Mon, 09 Aug 2004 18:44:00 -0000 [thread overview]
Message-ID: <vt2oelk6tnz.fsf@zenia.home> (raw)
Kevin requested these in:
http://sources.redhat.com/ml/gdb-patches/2004-07/msg00338.html
but I lost track of that in the shuffle. Here they are.
2004-08-09 Jim Blandy <jimb@redhat.com>
* rs6000-tdep.c (set_sim_regno, init_sim_regno_table,
rs6000_register_sim_regno): Doc fixes.
Index: rs6000-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/rs6000-tdep.c,v
retrieving revision 1.228
diff -c -p -c -p -F'^(' -r1.228 rs6000-tdep.c
*** rs6000-tdep.c 4 Aug 2004 17:45:30 -0000 1.228
--- rs6000-tdep.c 9 Aug 2004 18:42:11 -0000
*************** ppc_floating_point_unit_p (struct gdbarc
*** 192,197 ****
--- 192,205 ----
&& tdep->ppc_fpscr_regnum >= 0);
}
+
+ /* Check that TABLE[GDB_REGNO] is not already initialized, and then
+ set it to SIM_REGNO.
+
+ This is a helper function for init_sim_regno_table, constructing
+ the table mapping GDB register numbers to sim register numbers; we
+ initialize every element in that table to -1 before we start
+ filling it in. */
static void
set_sim_regno (int *table, int gdb_regno, int sim_regno)
{
*************** set_sim_regno (int *table, int gdb_regno
*** 201,206 ****
--- 209,218 ----
table[gdb_regno] = sim_regno;
}
+
+ /* Initialize ARCH->tdep->sim_regno, the table mapping GDB register
+ numbers to simulator register numbers, based on the values placed
+ in the ARCH->tdep->ppc_foo_regnum members. */
static void
init_sim_regno_table (struct gdbarch *arch)
{
*************** init_sim_regno_table (struct gdbarch *ar
*** 281,286 ****
--- 293,301 ----
tdep->sim_regno = sim_regno;
}
+
+ /* Given a GDB register number REG, return the corresponding SIM
+ register number. */
static int
rs6000_register_sim_regno (int reg)
{
reply other threads:[~2004-08-09 18:44 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=vt2oelk6tnz.fsf@zenia.home \
--to=jimb@redhat.com \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox