Skip to content

Commit

Permalink
fixup! Drop BlockedScheduler
Browse files Browse the repository at this point in the history
  • Loading branch information
ysbaddaden committed Sep 27, 2024
1 parent 9203290 commit d0bad52
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/multi_threaded.cr
Original file line number Diff line number Diff line change
Expand Up @@ -187,9 +187,12 @@ module ExecutionContext

# try to interrupt a thread waiting on the event loop
#
# FIXME: don't interrupt ourselves (i.e. current thread is running the
# eventloop...)
#
# OPTIMIZE: with one eventloop per execution context, we might prefer to
# wakeup a parked thread *before* interrupting the event loop.
unless @event_loop_lock.get(:relaxed)
if @event_loop_lock.get(:relaxed)
@event_loop.interrupt
return
end
Expand Down

0 comments on commit d0bad52

Please sign in to comment.