public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* Sparc V9 disassembly?
@ 1999-12-13 10:37 Raymond Toy
  1999-12-13 21:55 ` Andrew Cagney
  0 siblings, 1 reply; 3+ messages in thread
From: Raymond Toy @ 1999-12-13 10:37 UTC (permalink / raw)
  To: gdb; +Cc: Raymond Toy

I've just joined this list so if this question has been asked, forgive
me.  I looked at the recent mailing list archives and didn't see
anything obvious.

I'm trying to debug some Sparc v9 code and gdb's disassembler doesn't
want to print out the new v9 instructions.  Before trying the
disassembly, I gave the following commands to gdb (version 4.18):

info archi
set archi sparc:v9a
disassemble <addr1> <addr2>

It seems the bug is in gdb_print_insn_sparc.  It sets info->mach to
TM_PRINT_INSN_MACH, which is the sparc/sparclite.  If I use gdb to
change this to 8 (sparc v9?), the disassembler recognizes the v9
instructions.  

Is this correct behavior?

Ray

P.S.  This is a Ultra 30 (Ultrasparc IIi), solaris 2.7 machine.  gdb
configured using default options (except --prefix), from a stock
gdb-4.18 tarball.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Sparc V9 disassembly?
  1999-12-13 10:37 Sparc V9 disassembly? Raymond Toy
@ 1999-12-13 21:55 ` Andrew Cagney
  1999-12-14 15:29   ` Raymond Toy
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Cagney @ 1999-12-13 21:55 UTC (permalink / raw)
  To: Raymond Toy; +Cc: gdb

Raymond Toy wrote:
> 
> I've just joined this list so if this question has been asked, forgive
> me.  I looked at the recent mailing list archives and didn't see
> anything obvious.
> 
> I'm trying to debug some Sparc v9 code and gdb's disassembler doesn't
> want to print out the new v9 instructions.  Before trying the
> disassembly, I gave the following commands to gdb (version 4.18):
> 
> info archi
> set archi sparc:v9a
> disassemble <addr1> <addr2>
> 
> It seems the bug is in gdb_print_insn_sparc.  It sets info->mach to
> TM_PRINT_INSN_MACH, which is the sparc/sparclite.  If I use gdb to
> change this to 8 (sparc v9?), the disassembler recognizes the v9
> instructions.
> 
> Is this correct behavior?

I'd try it with the current GDB however, I suspect that SPARC GDB
currently ignores requests to change the architecture via ``set
architecture''.

	Andrew

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Sparc V9 disassembly?
  1999-12-13 21:55 ` Andrew Cagney
@ 1999-12-14 15:29   ` Raymond Toy
  0 siblings, 0 replies; 3+ messages in thread
From: Raymond Toy @ 1999-12-14 15:29 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: gdb

>>>>> "Andrew" == Andrew Cagney <ac131313@cygnus.com> writes:

    >> 
    >> info archi
    >> set archi sparc:v9a
    >> disassemble <addr1> <addr2>
    >> 
    >> It seems the bug is in gdb_print_insn_sparc.  It sets info->mach to
    >> TM_PRINT_INSN_MACH, which is the sparc/sparclite.  If I use gdb to
    >> change this to 8 (sparc v9?), the disassembler recognizes the v9
    >> instructions.
    >> 
    >> Is this correct behavior?

    Andrew> I'd try it with the current GDB however, I suspect that SPARC GDB
    Andrew> currently ignores requests to change the architecture via ``set
    Andrew> architecture''.

I commented out the offending line in gdb_print_insn_sparc, and
recompiled.  Everything seems to work according to the way I want, so
set architecture does work.  A peek at the code seems to indicate that
as well.

I will, however, try the most recent snapshot.

Since the code has made a conscious effort to set info->mach, I wasn't
really sure if everything else would work.

Ray

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-12-14 15:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-12-13 10:37 Sparc V9 disassembly? Raymond Toy
1999-12-13 21:55 ` Andrew Cagney
1999-12-14 15:29   ` Raymond Toy

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).