Cooperative Multitasking Scheduling
Discussions focus on cooperative versus preemptive thread scheduling, green threads, protothreads, and concurrency models in systems like Go goroutines, Erlang processes, and embedded environments.
Activity Over Time
Top Contributors
Keywords
Sample Comments
This paper uses cooperatively scheduled threads (i.e. no preemption or concurrent execution of threads), which means you don't have to deal with synchronization.
Yeah man, you're running on a multitasking OS. Just let the scheduler do the thing.
Sound like it's a hardware implementation of cooperative multitasking.
Donβt you still have to worry about this since OS threads can be arbitrarily preempted?
not exactly; see https://en.wikipedia.org/wiki/Cooperative_multitasking
preemptive green thread solve that.
Giving a chance to threads/processes with the same priority to be scheduled without doing any I/O or syscall? Used this once.
Still trying to understand: what's the difference between "forc[ing] preemption" and cooperative threading?
My understanding is that isn't really preemption, rather it's cooperative scheduling. As soon as the scheduler hand execution to the actor, everything else in the system has to hope there isn't a bug in the actor that permanently ties up that thread.
How is this different from protothreads?