Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@cygnus.com>
To: Andreas Jaeger <aj@suse.de>
Cc: Jiri Smid <smid@suse.cz>, gdb-patches@sources.redhat.com
Subject: Re: Misc; Was: [RFA]: x86_64 target files
Date: Fri, 31 Aug 2001 10:39:00 -0000	[thread overview]
Message-ID: <3B8FCBC0.2050007@cygnus.com> (raw)
In-Reply-To: <u866b4so44.fsf@gromit.moeb>

> Andrew Cagney <ac131313@cygnus.com> writes:
> 
> 
>>>
>>> I can try to take care of this in binutils.  You suggest something
>>> like get_arm_regnames in opcodes/arm-dis.c I guess?
> 
>>
>> Yes, but having looked at the interface, it isn't the most elegant.
> 
> 
> Do you have a better idea for an interface?

No.

(Just to be clear.  The ``fix'', what ever it is, requires an interface 
change to OPCODES.  I don't think it is reasonable for me to make the 
x86-64 tdep file approval dependant on such an external interface 
change.  Hence me suggestion to Jiri that a PR recording the problem be 
filed and hence the code remain as is.)

I've only got a gut feeling.   The x86-64 makes for a second target (and 
if we add in the x86m at least a third) that wants a mechanism for 
controlling the opcodes assembler.  GDB can certainly keep adding hooks 
to OPCODES, however, I think it might be time to consider a more generic 
interface - that way GDB developers only need to do this once.

Looking at include/dis-asm.h, `struct disassemble_info' already contains 
dissassembler_options.  A simplistic(1) aproach might be to add the command:

	(gdb) set disassembler <blah>

where <blah> was mindlessly assigned to dissassembler_options.  There 
are plenty of variations on this and probably other better ideas.

Enjoy,
	Andrew

(1) And my simplistic suggestion is certainly not as simple as it looks 
:-/ : getting GDB to detect / report a invalid option at the time it is 
set instead of used;  getting GDB to handle this in a multi-arch 
environment (an open problem - avoided so far by people using ``set 
<arch> <option> ...'');  getting GDB to report a list of valid options 
in response to:

	(gdb) set disassembler
or even	(gdb) set disassembler <tab>

hmm ... :-)


  parent reply	other threads:[~2001-08-31 10:39 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-08-02  7:20 Jiri Smid
2001-08-02  8:39 ` Eli Zaretskii
2001-08-02  9:37   ` Andreas Jaeger
2001-08-02  9:43 ` Kevin Buettner
2001-08-09 22:53   ` Andrew Cagney
2001-08-09 23:12 ` config/i386/xm-x86_64.h; Was " Andrew Cagney
2001-08-09 23:25 ` configure.host; Was: " Andrew Cagney
2001-08-09 23:41 ` configure.tgt; " Andrew Cagney
2001-08-09 23:57 ` Misc; " Andrew Cagney
2001-08-30  1:35   ` Jiri Smid
2001-08-30  7:39     ` Andrew Cagney
2001-08-30 11:03       ` Andreas Jaeger
2001-08-30 16:53         ` Andrew Cagney
2001-08-31  0:13           ` Andreas Jaeger
2001-08-31  2:00             ` i386 flavors [Was: Re: Misc; Was: [RFA]: x86_64 target files] Andreas Jaeger
2001-08-31 10:39             ` Andrew Cagney [this message]
2001-08-31 13:12               ` Misc; Was: [RFA]: x86_64 target files Andreas Jaeger

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=3B8FCBC0.2050007@cygnus.com \
    --to=ac131313@cygnus.com \
    --cc=aj@suse.de \
    --cc=gdb-patches@sources.redhat.com \
    --cc=smid@suse.cz \
    /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