4 ms·
"volatile" will not help with this class of problem. Don't worry about it... if your primary use-case is in Application space, than it won't matter most of the
by Joel_Mckay 2y ago
"volatile" will not help with this class of problem.
Don't worry about it... if your primary use-case is in Application space, than it won't matter most of the time. =3
- wtallis 2y ago> "volatile" will not help with this class of problem. Well, it's a good thing my comment had more words past that one. "volatile" is only part of the solution, and when more than one MMIO location is in play (as in your example), "volatile" on its own is insufficient but proper use of "volatile" plus explicit memory barriers will enforce correct ordering of loads and stores.