On Tuesday, 15 July 2014 at 21:28:24 UTC, Walter Bright wrote:
Peek/poke has a 40 year history of being used for MMIO, and I've never heard of it being used for concurrency. I don't think there's endemic confusion, quite unlike volatile.

There is a huge confusion about volatile in the native space. No one really knows what it does and when it should be used, because it's kind of rare.

I've seen pervasive volatile use make some GPU kernels 100x slower. Programming by coincidence, sure, but _explicit_ barriers, being read/write/optimizer barriers, I find them much better. volatile is more like denial, and importing the history behind the keyword would negative PR. Pascal had no volatile, and using &= from a memory-mapped location doesn't exactly scream "performance".


Reply via email to