> On 08 Mar 2015, at 20:59, stepharo <[email protected]> wrote:
>
> marcus
>
> I would love to see how we can use slots to have first class caches as
> described in guillermo paper.
> Why do we need to have a reflective call when it is not needed?
> Could not we late bound such behavior?
>
This example just shows how to do a Global without caring about byte code
generation.
You can override emit* and do something faster.
Now for caches, you want the *first* call to be an indirection (to trigger the
computation),
and all the ones after to use the fast code.
I think the best is to use MetaLinks for that: install a MetaLink on the Global
for read that
removes itself after the first call.
This way, the first call can do a computation while all the following will be
full speed.
For cache invalidation, the Cache can install links to get notified (and reset
it self) when
those value change that it depends on.
Marcus