diff options
author | Cheng Shao <astrohavoc@gmail.com> | 2022-10-22 17:51:47 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-11-11 00:26:55 -0500 |
commit | 50bf5e77891c6a28d1e610ba1da77f877195f1c0 (patch) | |
tree | 737271c78f7c1afcbc2a5456d53b2ae60a051ed0 | |
parent | 3f1e164f68aedee576e87f7548592a221896d229 (diff) | |
download | haskell-50bf5e77891c6a28d1e610ba1da77f877195f1c0.tar.gz |
rts: IPE.c: don't do mutex stuff when THREADED_RTS is not defined
This patch adds the missing THREADED_RTS CPP guard to mutex logic in
IPE.c.
-rw-r--r-- | rts/IPE.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -63,10 +63,20 @@ static HashTable *ipeMap = NULL; // Accessed atomically static IpeBufferListNode *ipeBufferList = NULL; +#if defined(THREADED_RTS) + void initIpe(void) { initMutex(&ipeMapLock); } void exitIpe(void) { closeMutex(&ipeMapLock); } +#else + +void initIpe(void) { } + +void exitIpe(void) { } + +#endif // THREADED_RTS + static InfoProvEnt ipeBufferEntryToIpe(const IpeBufferListNode *node, const IpeBufferEntry *ent) { const char *strings = node->string_table; |