3 ms·
ditto for "coroutine + scheduler as replacement of threads". Another example using this framework is Simpy (http://simpy.sourceforge.net/ http://simpy.sourcefo
by fredliu 15y ago
ditto for "coroutine + scheduler as replacement of threads".
Another example using this framework is Simpy (http://simpy.sourceforge.net/ http://simpy.sourceforge.net/), a process based discrete event simulation platform. You program in a way similar to the traditional multi-process/thread manner, but don't have to worry about mutex and locks at all, very sweet and productive!
The only caveat for this framework is that it's hard to fully utilize the power of multi-core systems, since it's single threaded. But if your application is more I/O bound than CPU bound, this framework could potentially give you huge benefit of multi-threading w/o the complexity.