From: Eli Zaretskii <eliz@gnu.org>
To: gdb-patches@sourceware.org
Subject: [RFA] Fix DJGPP register numbering with COFF and stabs debug info
Date: Sat, 23 May 2009 11:26:00 -0000 [thread overview]
Message-ID: <83hbzct5zg.fsf@gnu.org> (raw)
The default register numbering for COFF and stabs is wrong for DJGPP
native debugging, since the native compiler is GCC. This patch fixes
that.
OK to commit?
2009-05-23 Eli Zaretskii <eliz@gnu.org>
* i386-tdep.c (i386_go32_init_abi): Use SVR4 register numbering
for stabs and COFF debug info.
--- i386-tdep.c~1 2009-04-29 13:40:00.314875000 +0300
+++ i386-tdep.c 2009-05-23 14:16:56.437500000 +0300
@@ -2598,6 +2598,13 @@ i386_go32_init_abi (struct gdbarch_info
/* DJGPP does not support the SSE registers. */
tdep->num_xmm_regs = 0;
set_gdbarch_num_regs (gdbarch, I386_NUM_GREGS + I386_NUM_FREGS);
+
+ /* Native compiler is GCC, which uses the SVR4 register numbering
+ even in COFF and STABS. See the comment in i386_gdbarch_init,
+ before the calls to set_gdbarch_stab_reg_to_regnum and
+ set_gdbarch_sdb_reg_to_regnum. */
+ set_gdbarch_stab_reg_to_regnum (gdbarch, i386_svr4_reg_to_regnum);
+ set_gdbarch_sdb_reg_to_regnum (gdbarch, i386_svr4_reg_to_regnum);
}
\f
next reply other threads:[~2009-05-23 11:26 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-23 11:26 Eli Zaretskii [this message]
2009-05-25 13:16 ` Ulrich Weigand
2009-05-29 11:39 ` Eli Zaretskii
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=83hbzct5zg.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
/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