Subject: Re: emuns on ARM: What should we do?
To: None <Richard.Earnshaw@arm.com>
From: Ben Harris <bjh21@netbsd.org>
List: tech-toolchain
Date: 01/21/2002 16:00:39
On Sat, 19 Jan 2002, Richard Earnshaw wrote:
> > Reasons why we should not use -fshort-enums:
> > * Enum membership changes cause ABI changes, and hence library major
> > number changes at unexpected times.
>
> Can cause. Will only affect enums that cross a size boundary, and only if
> the designers haven't thought about the issue in advance. Even then, the
> most likely source of failure will be if the enum values are used in
> structures that are used in a visible public interface.
There are at least some of these in NetBSD at present. Some of them
currently end up being the wrong size if you turn on -fshort-enums.
> > * Enums will tend to be types that are slow to load and store on ARMv3,
> > which is our default compiler target.
>
> Most enums that I've seen are in the range 0-255; very few will need more
> than this.
I'm probably biased (having been looking at particularly awkward ones
lately), but I think I've seen all of the possible ranges at various
places in our source tree.
--
Ben Harris <bjh21@netbsd.org>
Portmaster, NetBSD/arm26 <URL:http://www.netbsd.org/Ports/arm26/>