"CRV§ADER//KY" <crusaderky(a)gmail.com> writes:
I second that the caching should be done internally by opencl, as
would produce more readable code and avoid obscure bugs like the opener's.
Is there any reason against it?
As a general python rule, if you have a @property that takes a
non-negligible amount of time to compute after the first invocation, you're
doing it wrong and it should be either cached or replaced by a function.
Just my 2c.
I generally agree, although this is a bit subtler, since "prg.sum" is
cheap. It's just using "prg.sum(...)" incurs sigificant cost each time.
Nonetheless, yes, I agree that this should be fixed.
I'd be happy to take a patch if one of you gets to it before I do.