Caltoopia/caltoopia-calvin

Idle mode is broken

Closed this issue · 3 comments

The runtime is currently a bit too optimistic about when to enter idle mode, at least in distributed cases. In some cases, the runtime halts the application and enters idle mode prematurely.

Idle mode has currently been disabled, and placed under a (disabled) preprocessor variable CALVIN_BLOCK_ON_IDLE in actors-network.c.

A more robust implementation should be devised, one that somehow also addresses the distributed case, if possible.

I think the temporary fix sometimes makes calvin enter an infinite loop after quiting due to the scheduler keeps spinning after nothing more to do in an actor application.

Yes, it does spin: therein lies the fix. This is bad for a number of reasons, including non-termination.

This should be fixed in commit d69e470 please test more.