... >> It's never correct to exchange volatile accesses. > >That's not true. volatile accesses to different memory locations >have no special dependence. If it happens that GCC doesn't >do this kind of things then this is only because most passes >don't thouch volatile stmts at all (thus the reports for sub-optimal >code with volatile - we don't even try to do legal transformations).
I'm confused. Do you mean that in Volatile int *a, *b; Int j, k; J = *a; k = *b; it is ok to fetch *b before *a? I can't think of any device driver writer who would expect that. paul