From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6099 invoked by alias); 31 Jan 2002 21:21:49 -0000 Mailing-List: contact cgen-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cgen-owner@sources.redhat.com Received: (qmail 5967 invoked from network); 31 Jan 2002 21:21:45 -0000 Received: from unknown (HELO toenail.toronto.redhat.com) (216.138.202.10) by sources.redhat.com with SMTP; 31 Jan 2002 21:21:45 -0000 Received: (from fche@localhost) by toenail.toronto.redhat.com (8.11.6/8.11.6) id g0VLLWJ23777; Thu, 31 Jan 2002 16:21:32 -0500 Date: Thu, 31 Jan 2002 13:21:00 -0000 From: "Frank Ch. Eigler" To: Doug Evans Cc: binutils@sources.redhat.com, cgen@sources.redhat.com Subject: Re: include/dis-asm.h patch for cgen disassemblers Message-ID: <20020131162132.I19966@redhat.com> References: <20020131124350.C19966@redhat.com> <15449.42904.232177.265525@casey.transmeta.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="Hlh2aiwFLCZwGcpw" Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <15449.42904.232177.265525@casey.transmeta.com>; from dje@transmeta.com on Thu, Jan 31, 2002 at 12:22:48PM -0800 X-SW-Source: 2002-q1/txt/msg00028.txt.bz2 --Hlh2aiwFLCZwGcpw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 2510 Hi - dje wrote: > [...] > Blech. > [...] > I'd go with the first possibility, and not overload `mach'. > Instead of arch/mach in disassemble_info, have arch/mach/mumble > [...] OK. How about this? It is simpler, but it furthers disassemble_info field sprawl. - FChE Index: opcodes/ChangeLog =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D @@ -1,3 +1,7 @@ +2002-01-31 Frank Ch. Eigler + + * cgen-dis.in (print_insn_@arch@): Support disassemble_info.isas. + Index: opcodes/cgen-dis.in =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D @@ -386,7 +386,7 @@ print_insn_@arch@ (pc, info) #ifdef CGEN_COMPUTE_ISA isa =3D CGEN_COMPUTE_ISA (info); #else - isa =3D 0; + isa =3D info->isas; #endif =20 /* If we've switched cpu's, close the current table and open a new one. = */ Index: include/ChangeLog =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D @@ -1,3 +1,8 @@ +2002-01-31 Frank Ch. Eigler + + * dis-asm.h (isas): New field in disassemble_info. + (INIT_DISASSEMBLE_INFO): Clear it. + Index: include/dis-asm.h =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D @@ -73,6 +73,8 @@ typedef struct disassemble_info { unsigned long mach; /* Endianness (for bi-endian cpus). Mono-endian cpus can ignore this. = */ enum bfd_endian endian; + /* A target-specific indication of applicable instruction sets. */ + unsigned long isas; =20 /* Some targets need information about the current section to accurately display insns. If this is NULL, the target disassembler function @@ -271,6 +273,7 @@ extern int generic_symbol_at_address (INFO).flavour =3D bfd_target_unknown_flavour, \ (INFO).arch =3D bfd_arch_unknown, \ (INFO).mach =3D 0, \ + (INFO).isas =3D 0, \ (INFO).endian =3D BFD_ENDIAN_UNKNOWN, \ (INFO).octets_per_byte =3D 1, \ INIT_DISASSEMBLE_INFO_NO_ARCH(INFO, STREAM, FPRINTF_FUNC) --Hlh2aiwFLCZwGcpw Content-Type: application/pgp-signature Content-Disposition: inline Content-length: 232 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE8WbVcVZbdDOm/ZT0RAhTaAJ4v2yy6uQdVn8OBCrD4jpbt9GSWhgCfQX58 1C5DEw1ZlUI4tjtlDFm/iuY= =Gwl4 -----END PGP SIGNATURE----- --Hlh2aiwFLCZwGcpw--