
#8684: hWaitForInput cannot be interrupted by async exceptions on unix -------------------------------------+------------------------------------- Reporter: nh2 | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Core Libraries | Version: 7.6.3 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: 13497, 13525 | Blocking: Related Tickets: #12912, #13525 | Differential Rev(s): Phab:D42 Wiki Page: | -------------------------------------+------------------------------------- Comment (by nh2): In other words, I believe we have a scheduling unfairness problem in the non-threaded RTS: A thread that loops tightly around a foreign call will never give other threads the chance to run. I ''suspect'' this is because of the run-queue logic mentioned in [https://ghc.haskell.org/trac/ghc/wiki/Commentary/Rts/Scheduler#Therunqueue the Scheduler commentary]: ----
In more detail, threads are put **in front** (`pushOnRunQueue`) if: [...] * In the non-threaded runtime, when a thread waiting on IO unblocks.
-- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8684#comment:22 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler