[Bug 1928] mpc5674fevb: powerpc/mpc55xx/misc/flash_support.c:183:9: warning: case label value exceeds maximum value for type

bugzilla-daemon at rtems.org bugzilla-daemon at rtems.org
Thu Oct 6 06:01:58 UTC 2011


https://www.rtems.org/bugzilla/show_bug.cgi?id=1928

--- Comment #2 from Ralf Corsepius <ralf.corsepius at rtems.org> 2011-10-06 01:01:57 CDT ---
(In reply to comment #1)
> Hardware accessed via bit fields is always trouble even if you think things
> look ok.
Partially agreed, bitfields are a double wedged sword - They have pros and
cons.

(E.g. if this case was implemented via bit-masks, gcc would not have raised a
warning, but code would have been silently broken)

Portability-wise, they are a nightmare, e.g. wrt. byte-order.

> There is no standards based means to control the size of the access to
> the specific field.
As long as these bitfields are sufficiently tied to a specific setup, they
normally should be OK with gcc. 

At least, I've never seen a case with gcc where it did not work.

> Does the bsp use -fstrict-volatile-bitfields ?
I've never heard about this option before. /me thinks it's one of those "bit
pimpers" options, people should not even start thinking about.

-- 
Configure bugmail: https://www.rtems.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the bugs mailing list