Am 12.06.2012 19:38, schrieb Sönke Ludwig:

Am 12.06.2012 09:01, schrieb Nick Sabalausky:

Just a thought I had: Would it be reasonable for vibe.d to tell the GC
to run a collection cycle whenever vibe.d detects it's a good time to do
so? (For example, when there's no traffic for a certain amount of time.)
Or does vibe.d already do something like this?

It doesn't do this right now but that would be an idea and should be
relatively easy to do using a timer once there is support for an
onIdle() callback, which I have lying around somwhere already (I'll
check this in when I get some time). Would be interesting to test how
efficient this is for reducing delays in practice.

I've just added this as an optional feature. With
DFLAGS="-version=VibeIdleCollect", it should now run a GC collection
whenever there was no activity for 2 seconds.