summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDuncan Coutts <duncan@well-typed.com>2021-01-03 17:00:11 +0000
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-01-25 05:11:14 -0500
commite93384e82fb4de5a5ee96949b7c1108bce16a875 (patch)
tree10ce155425fd89d67324f0482bfe91bd41ebc306
parent455ad48bdfb5d47d666d23db81ad10c855dab078 (diff)
downloadhaskell-e93384e82fb4de5a5ee96949b7c1108bce16a875.tar.gz
Move ioManager{Start,Wakeup,Die} to internal IOManager.h
Move them from the external IOInterface.h to the internal IOManager.h. The functions are all in fact internal. They are not used from the base library at all. Remove ioManagerWakeup as an exported symbol. It is not used elsewhere.
-rw-r--r--includes/rts/IOInterface.h12
-rw-r--r--rts/Capability.c1
-rw-r--r--rts/IOManager.h12
-rw-r--r--rts/RtsStartup.c1
-rw-r--r--rts/RtsSymbols.c2
-rw-r--r--rts/Schedule.c1
-rw-r--r--rts/posix/Signals.c1
7 files changed, 16 insertions, 14 deletions
diff --git a/includes/rts/IOInterface.h b/includes/rts/IOInterface.h
index 4c392e2058..9a646cc5cf 100644
--- a/includes/rts/IOInterface.h
+++ b/includes/rts/IOInterface.h
@@ -36,15 +36,3 @@ void setIOManagerWakeupFd (int fd);
#endif
-/*
- * Communicating with the IO manager thread (see GHC.Conc).
- * Posix implementation in posix/Signals.c
- * Win32 implementation in win32/ThrIOManager.c, Windows's WINIO has the same
- * interfaces for Threaded and Non-threaded I/O, so these methods are always
- * available for WINIO.
-*/
-void ioManagerWakeup (void);
-#if defined(THREADED_RTS) || defined(mingw32_HOST_OS)
-void ioManagerDie (void);
-void ioManagerStart (void);
-#endif
diff --git a/rts/Capability.c b/rts/Capability.c
index a77112650a..3ef604693b 100644
--- a/rts/Capability.c
+++ b/rts/Capability.c
@@ -29,6 +29,7 @@
#include "RtsUtils.h"
#include "sm/OSMem.h"
#include "sm/BlockAlloc.h" // for countBlocks()
+#include "IOManager.h"
#include <string.h>
diff --git a/rts/IOManager.h b/rts/IOManager.h
index da322c6e40..713049305f 100644
--- a/rts/IOManager.h
+++ b/rts/IOManager.h
@@ -21,5 +21,17 @@
#include "BeginPrivate.h"
+/*
+ * Communicating with the IO manager thread (see GHC.Conc).
+ * Posix implementation in posix/Signals.c
+ * Win32 implementation in win32/ThrIOManager.c, Windows's WINIO has the same
+ * interfaces for Threaded and Non-threaded I/O, so these methods are always
+ * available for WINIO.
+*/
+void ioManagerWakeup (void);
+#if defined(THREADED_RTS) || defined(mingw32_HOST_OS)
+void ioManagerDie (void);
+void ioManagerStart (void);
+#endif
#include "EndPrivate.h"
diff --git a/rts/RtsStartup.c b/rts/RtsStartup.c
index 79c830f96d..7916ad61c8 100644
--- a/rts/RtsStartup.c
+++ b/rts/RtsStartup.c
@@ -46,6 +46,7 @@
# include "RetainerProfile.h"
#endif
+#include "IOManager.h"
#if defined(mingw32_HOST_OS) && !defined(THREADED_RTS)
#include "win32/AsyncMIO.h"
#include "win32/AsyncWinIO.h"
diff --git a/rts/RtsSymbols.c b/rts/RtsSymbols.c
index 7cd62faabe..a3ee8505ae 100644
--- a/rts/RtsSymbols.c
+++ b/rts/RtsSymbols.c
@@ -341,7 +341,6 @@
SymI_HasProto(setIOManagerControlFd) \
SymI_HasProto(setTimerManagerControlFd) \
SymI_HasProto(setIOManagerWakeupFd) \
- SymI_HasProto(ioManagerWakeup) \
SymI_HasProto(blockUserSignals) \
SymI_HasProto(unblockUserSignals)
#else
@@ -350,7 +349,6 @@
SymI_HasProto(getOverlappedEntries) \
SymI_HasProto(completeSynchronousRequest) \
SymI_HasProto(registerAlertableWait) \
- SymI_HasProto(ioManagerWakeup) \
SymI_HasProto(sendIOManagerEvent) \
SymI_HasProto(readIOManagerEvent) \
SymI_HasProto(getIOManagerEvent) \
diff --git a/rts/Schedule.c b/rts/Schedule.c
index 514832ea6e..810a70973b 100644
--- a/rts/Schedule.c
+++ b/rts/Schedule.c
@@ -32,6 +32,7 @@
#include "Capability.h"
#include "Task.h"
#include "AwaitEvent.h"
+#include "IOManager.h"
#if defined(mingw32_HOST_OS)
#include "win32/MIOManager.h"
#include "win32/AsyncWinIO.h"
diff --git a/rts/posix/Signals.c b/rts/posix/Signals.c
index 57b1873c77..185c69eee3 100644
--- a/rts/posix/Signals.c
+++ b/rts/posix/Signals.c
@@ -12,6 +12,7 @@
#include "Schedule.h"
#include "RtsSignals.h"
#include "Signals.h"
+#include "IOManager.h"
#include "RtsUtils.h"
#include "Prelude.h"
#include "Ticker.h"