Duncan Coutts pushed to branch wip/io-manager-deadlock-detection at Glasgow Haskell Compiler / GHC Commits: 3930cb47 by Duncan Coutts at 2026-09-30T12:37:36+01:00 FIXUP: correct the type of timeout_idlegc_delay - - - - - 04c39112 by Duncan Coutts at 2026-09-30T12:37:55+01:00 Remove variable n_haskell_handlers which has become write-only - - - - - 4 changed files: - rts/posix/Poll.c - rts/posix/Select.c - rts/posix/SelectBis.c - rts/posix/Signals.c Changes: ===================================== rts/posix/Poll.c ===================================== @@ -478,7 +478,7 @@ bool awaitCompletedTimeoutsOrIOPoll(CapIOManager *iomgr) * (see handleIdleGcTimeout below). */ bool any_pending_io = nfds > 0; - int timeout_idlegc_delay; + bool timeout_idlegc_delay; adjustTimeoutForIdleGc(any_pending_io, &timeout, &timeout_idlegc_delay); #endif ===================================== rts/posix/Select.c ===================================== @@ -371,7 +371,7 @@ awaitCompletedTimeoutsOrIOSelect(CapIOManager *iomgr, bool wait) * (see handleIdleGcTimeout below). */ bool any_pending_io = maxfd > 0; - int timeout_idlegc_delay; + bool timeout_idlegc_delay; adjustTimeoutForIdleGc(any_pending_io, &timeout, &timeout_idlegc_delay); #endif ===================================== rts/posix/SelectBis.c ===================================== @@ -442,7 +442,7 @@ bool awaitCompletedTimeoutsOrIOSelectBis(CapIOManager *iomgr) * (see handleIdleGcTimeout below). */ bool any_pending_io = maxfd >= 0; - int timeout_idlegc_delay; + bool timeout_idlegc_delay; adjustTimeoutForIdleGc(any_pending_io, &timeout, &timeout_idlegc_delay); #endif ===================================== rts/posix/Signals.c ===================================== @@ -55,8 +55,6 @@ HsInt nocldstop = 0; StgInt *signal_handlers = NULL; /* Dynamically grown array of signal handlers */ static StgInt nHandlers = 0; /* Size of handlers array */ -static uint32_t n_haskell_handlers = 0; - static sigset_t userSignals; static sigset_t savedSignals; @@ -83,7 +81,6 @@ freeSignalHandlers(void) { stgFree(signal_handlers); signal_handlers = NULL; nHandlers = 0; - n_haskell_handlers = 0; } #if defined(THREADED_RTS) closeMutex(&sig_mutex); @@ -288,16 +285,10 @@ stg_sig_install(int sig, int spi, void *mask) case STG_SIG_RST: case STG_SIG_HAN: sigaddset(&userSignals, sig); - if (previous_spi != STG_SIG_HAN && previous_spi != STG_SIG_RST) { - n_haskell_handlers++; - } break; default: sigdelset(&userSignals, sig); - if (previous_spi == STG_SIG_HAN || previous_spi == STG_SIG_RST) { - n_haskell_handlers--; - } break; } View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/80e2ceee662bbaad131c70e5f747f64... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/80e2ceee662bbaad131c70e5f747f64... You're receiving this email because of your account on gitlab.haskell.org. Manage all notifications: https://gitlab.haskell.org/-/profile/notifications | Help: https://gitlab.haskell.org/help
participants (1)
-
Duncan Coutts (@dcoutts)