This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: gas/config/tc-alpha.c
On Tue, May 16, 2000 at 01:08:23PM +1000, Andrew Cagney wrote:
> Michael Meissner wrote:
>
> > > I guess it doesn't matter a great deal as binutils is riddled with this
> > > sort of assumption about sizes of integral types. I did have some idea of
> > > attacking the problem, but it seems a whole lot of work for little
> > > immediate benefit.
> >
> > Or include limits.h (presumably also checking if limits.h exists via autoconf),
> > and base the #if on whether you have 8 bit bytes and 16 bit longs, which would
> > be the portable way of doing it.
>
> Why not go all the way and have bfd provide bfd_int8, bfd_int16, et.al.
> That way:
>
> ((bfd_signed_vma) (bfd_int16) val)
>
> would work optimally.
Well there have been C systems out there that didn't have 8/16/32 bit types of
any form. Most of them are dead or not a hosted platform (ie, the TI C54x
doesn't have bytes in at all, and sizeof (int) == sizeof (char)).
--
Michael Meissner, Cygnus Solutions, a Red Hat company.
PMB 198, 174 Littleton Road #3, Westford, Massachusetts 01886, USA
Work: meissner@redhat.com phone: +1 978-486-9304
Non-work: meissner@spectacle-pond.org fax: +1 978-692-4482