why does -mcfv4e work for gas but not objdump?
Ian Lance Taylor
ian@wasabisystems.com
Wed Apr 21 17:16:00 GMT 2004
Peter Barada <peter@the-baradas.com> writes:
> I'm having trouble tryng to figure out why -mcfv4e works for gas, but
> I have to specify -mm68k:mcfv4e for objdump to select the ColdFire v4e
> version of the m68k tools.
The gas -mcfv4e option works out of the archs array in
gas/config/tc-m68k.c. The objdump -mm68k:mcfv4e option works off the
list found in bfd/cpu-m68k.c. So there is no special reason to expect
the options to be the same, except whatever effort we make to retain
consistency.
> In bfd/cpu-m68k.c I've added:
>
> N(bfd_mach_mcfv4e, "m68k:cfv4e", FALSE, 0),
>
> and am wondering if I add the following to get objdump to parse -m5407
> is the correct way to solve this:
>
> N(bfd_mach_mcfv4e, "cfv4e", FALSE, 0),
That would let objdump accept -mcfv4e, yes, though not -m5407.
See bfd_default_scan in bfd/archures.c for how the objdump -m option
is handled.
The other thing you can do is write an m68k specific scan routine, and
use it in cpu-m68k.c. That would let you strip some of the special
cases out of bfd_default_scan.
Ian
More information about the Binutils
mailing list