From: Michael Snyder <msnyder@cygnus.com>
To: binutils@sourceware.cygnus.com, gdb-patches@sourceware.cygnus.com
Subject: [RFA]: opcodes / i386 disassembler
Date: Thu, 20 Jul 2000 18:41:00 -0000 [thread overview]
Message-ID: <200007210141.SAA21236@cleaver.cygnus.com> (raw)
Would the following be acceptable? Assuming I provided an
suitable ChangeLog entry?
Index: i386-dis.c
===================================================================
RCS file: /cvs/cvsfiles/devo/opcodes/i386-dis.c,v
retrieving revision 1.51
diff -p -r1.51 i386-dis.c
*** i386-dis.c 2000/04/05 20:16:40 1.51
--- i386-dis.c 2000/07/21 01:40:08
*************** You should have received a copy of the G
*** 18,38 ****
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
! /*
! * 80386 instruction printer by Pace Willisson (pace@prep.ai.mit.edu)
! * July 1988
! * modified by John Hassey (hassey@dg-rtp.dg.com)
! */
!
! /*
! * The main tables describing the instructions is essentially a copy
! * of the "Opcode Map" chapter (Appendix A) of the Intel 80386
! * Programmers Manual. Usually, there is a capital letter, followed
! * by a small letter. The capital letter tell the addressing mode,
! * and the small letter tells about the operand size. Refer to
! * the Intel manual for details.
! */
#include "dis-asm.h"
#include "sysdep.h"
#include "opintl.h"
--- 18,34 ----
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
! /* 80386 instruction printer by Pace Willisson (pace@prep.ai.mit.edu)
! July 1988, modified by John Hassey (hassey@dg-rtp.dg.com). */
+ /* The main tables describing the instructions is essentially a copy
+ of the "Opcode Map" chapter (Appendix A) of the Intel 80386
+ Programmers Manual and the Pentium(TM) Family User's Manual.
+ Usually, there is a capital letter, followed by a small letter.
+ The capital letter tell the addressing mode, and the small letter
+ tells about the operand size. Refer to the Intel manual for
+ details. */
+
#include "dis-asm.h"
#include "sysdep.h"
#include "opintl.h"
*************** static const struct dis386 dis386_att[]
*** 496,502 ****
/* 80 */
{ GRP1b },
{ GRP1S },
! { "(bad)", XX, XX, XX },
{ GRP1Ss },
{ "testB", Eb, Gb, XX },
{ "testS", Ev, Gv, XX },
--- 492,509 ----
/* 80 */
{ GRP1b },
{ GRP1S },
! /* this one is blank in appendix A of the 386 book, and given as
! "MOVB AL, imm8 in appendix A of the Pentium book with a footnote
! saying "Reserved"; it *should* be "Immediate Grp1, Ev, Ib"
! according to an Intel person who says it'll be fixed in the -004
! version of the Pentium book.
!
! The trick here is that 0x80 sets neither the "s" nor the "w" bit,
! while 0x82 sets the "s" bit but not the "w" bit. However, if the
! "w" bit isn't set, the setting of the "s" bit is irrelevant, as
! the operands are one byte long, so there's no sign-extension to be
! done. */
! { GRP1b },
{ GRP1Ss },
{ "testB", Eb, Gb, XX },
{ "testS", Ev, Gv, XX },
*************** static const struct dis386 dis386_twobyt
*** 968,974 ****
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
/* 20 */
! /* these are all backward in appendix A of the intel book */
{ "movL", Rd, Cd, XX },
{ "movL", Rd, Dd, XX },
{ "movL", Cd, Rd, XX },
--- 975,982 ----
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
/* 20 */
! /* these are all backward in appendix A of the intel book,
! but correct in appendix A of the Pentium book. */
{ "movL", Rd, Cd, XX },
{ "movL", Rd, Dd, XX },
{ "movL", Cd, Rd, XX },
next reply other threads:[~2000-07-20 18:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-07-20 18:41 Michael Snyder [this message]
2000-07-20 18:59 ` Alan Modra
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=200007210141.SAA21236@cleaver.cygnus.com \
--to=msnyder@cygnus.com \
--cc=binutils@sourceware.cygnus.com \
--cc=gdb-patches@sourceware.cygnus.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).