This is the mail archive of the 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: objdump -M for x86

On Wed, Nov 14, 2001 at 03:49:52AM -0500, Andrew Cagney wrote:
> >  mode_64bit = (info->mach == bfd_mach_x86_64_intel_syntax
> >  		|| info->mach == bfd_mach_x86_64);
> >  
> > +  if (intel_syntax == -1)
> > +    intel_syntax = (info->mach == bfd_mach_i386_i386_intel_syntax
> > +		    || info->mach == bfd_mach_x86_64_intel_syntax);
> > +
> See my other e-mail.  I can't find anything that sets ->mach to 
> .._intel_syntax so, apart from backward compatibility, I can't think of 
> a reason to hang on to those ``machine'' variants.  I don't expect GDB 
> to start using them again.

"objdump -d -m i386:intel" sets it via bfd_default_scan from the entry
in bfd/cpu-i386.c

> We'll need to do things like pin down the semantics.  Which really means 
> agree on what something like ``x86-64 i386 i8086 intel att addr16 addr32 
> data32 data16 suffix'' actually means, and ensure that GDB doesn't find 
> it has accepted a set of options only to find them later rejected by the 
> disasssembler.

Perhaps the thing to do is add a function to bfd_arch_info_type that
validates a -M string for the given arch.  If a null string is passed in,
it could return an array of possible string components.


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