"stopping" misbehaving fibers

Mark Raynsford org.openjdk at io7m.com
Sun May 10 09:38:04 UTC 2020


Hello!

In the current (pre-Loom) thread model, if a thread goes into an
infinite loop without making any blocking calls and without consuming
any stack space (such that a StackOverflowError would eventually be
raised), then there's nothing we can do about this. The thread will
burn CPU time, subject to OS scheduling, until the VM process is killed
and restarted.

Is the same also true of Fibers? I understand that any time a fiber
makes a blocking call, the fiber is parked. Is it possible to otherwise
preempt or pause a fiber that isn't making it to a point where it will
yield (either due to bugs or malicious intent)?

-- 
Mark Raynsford | https://www.io7m.com



More information about the loom-dev mailing list