http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45472
--- Comment #10 from Michael Matz <matz at gcc dot gnu.org> 2010-10-18 15:58:26 UTC --- One idea we had was that this is all frontends business anyway, and hence it should (if it so desires) simply create volatile MEM_REFs for references to half-volatile objects. That alone would result in the copy statement being marked volatile, and would also (I guess, haven't checked) do the right thing in expand. So, if we (the frontend) decide that accesses to objects containing volatile subobjects should itself be regarded as volatile, then generating the right kind of MEM_REF would already provide that.