On Fri, Nov 15, 2013 at 11:14 AM, Jakub Jelinek <ja...@redhat.com> wrote:
> On Fri, Nov 15, 2013 at 11:12:39AM +0100, Richard Biener wrote:
>> Btw, what does the C++ memory model say for
>>
>> struct { char x; short a; short b; } a __attribute__((packed));
>
> Nothing, because packed is outside of the standard?

Ok, then make it not packed.  Then I bring in Josephs earlier comment

"I think the memory model naturally applies to packed structures (i.e.,
writes to fields in them should not write to any other fields except as
part of a sequence of consecutive non-zero-width bit-fields, unless
allow-store-data-races is set)."

Richard.

>         Jakub

Reply via email to