std.functional.memoize : thread local or __gshared memoization?
Kagamin via Digitalmars-d
digitalmars-d at puremagic.com
Sat May 27 09:19:06 PDT 2017
On Saturday, 27 May 2017 at 10:29:05 UTC, Ola Fosheim Grøstad
wrote:
> Hm, I would think that using __gshared would not be affected by
> compiler improvements, since it would turn off optimizations
> that assume that the variable doesn't change between reads?
Like volatile? Volatile doesn't work. Why would you want that?
__gshared has purpose to behave like old good global variable
simply to provide a low level feature for a system language, if
you need something else, then use the right tool.
More information about the Digitalmars-d
mailing list