This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: sh-elf disassembly broken (Was: Re: RFC: Moving disassembler_command to cli land and using newer disassembler code)


Joern Rennecke writes:
 > Elena Zannoni wrote:
 > > 
 > > Joern, would something like this work, instead?
 > > Index: sh-tdep.c
 > > ===================================================================
 > > RCS file: /cvs/uberbaum/gdb/sh-tdep.c,v
 > > retrieving revision 1.96
 > > diff -u -p -r1.96 sh-tdep.c
 > > --- sh-tdep.c   3 Feb 2003 14:38:05 -0000       1.96
 > > +++ sh-tdep.c   24 Feb 2003 21:48:59 -0000
 > > @@ -937,6 +937,7 @@ sh_store_struct_return (CORE_ADDR addr,
 > >  static int
 > >  gdb_print_insn_sh (bfd_vma memaddr, disassemble_info *info)
 > >  {
 > > +  info->mach = gdbarch_bfd_arch_info (current_gdbarch)->mach;
 > >    info->endian = TARGET_BYTE_ORDER;
 > >    return print_insn_sh (memaddr, info);
 > >  }
 > > 
 > 
 > It looks like it should work for the way disassembling is used
 > right now, but it would mean that we don't honour the setting
 > of mach in the input parameter.  So if you want to add a command
 > that disassembles a region of memory assuming another machine
 > setting than the current one, you'd be out of luck.

Oh, I see, I guess you have such a command. In any case, I'll commit
this, so at least it works right now, vanilla flavor.

elena


 > 			
 > -- 
 > --------------------------
 > SuperH (UK) Ltd.
 > 2410 Aztec West / Almondsbury / BRISTOL / BS32 4QX
 > T:+44 1454 465658


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]