This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: structure members of packed structures


On Tuesday, July 15, 2003, at 03:59 PM, Richard Henderson wrote:
On Mon, Jul 14, 2003 at 02:50:00PM -0700, Dale Johannesen wrote:
Contingent on STRICT_ALIGNMENT, please.  Unaligned accesses are not
a problem on all architectures.

I strongly do not think we should make the legality of the & operator contingent on STRICT_ALIGNMENT. All the world's an x86,

Not yet, mister.:)


and everyone
else will suffer if you do this.

But you have a point.


Personally, I have no problem with the address being taken and giving
SIGBUS when used (or, gasp, fixed up by UAC fault software).

This, IMO, is one of those "well don't do that then" sorts of problems.

That's fine with me, but then it would be.


We do have actual users who have packed structs containing misaligned
fields, and want the misaligned memory refs.   Not sure about & but they
would certainly expect it to work.


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