> On Dec 30, 2014, at 1:32 PM, Matt Godbolt <m...@godbolt.org> wrote: > > On Tue, Dec 30, 2014 at 5:05 AM, Torvald Riegel <trie...@redhat.com> wrote: >> I agree with Andrew. My understanding of volatile is that the generated >> code must do exactly what the abstract machine would do. > > That makes sense. I suppose I don't understand what the difference is > in terms of an abstract machine of "load; add; store" versus the > "load-add-store". At least from on x86, from the perspective of the > memory bus, there's no difference I'm aware of.
That was my point. The model needs to treat those two as equivalent, otherwise the model is constructed by theories that I don’t understand. paul