summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
authorNiklas Hambüchen <mail@nh2.me>2019-10-29 12:54:10 +0100
committerMarge Bot <ben+marge-bot@smart-cactus.org>2019-11-01 23:12:17 -0400
commit9980fb58f613ee3363c7e4cb86453e542c6c69aa (patch)
tree67f0e195dd71510d1d797ce5e07f422401269b90 /includes
parent01006bc79582616c9bbc842b397e85437a57ac18 (diff)
downloadhaskell-9980fb58f613ee3363c7e4cb86453e542c6c69aa.tar.gz
Add +RTS --disable-delayed-os-memory-return. Fixes #17411.
Sets `MiscFlags.disableDelayedOsMemoryReturn`. See the added `Note [MADV_FREE and MADV_DONTNEED]` for details.
Diffstat (limited to 'includes')
-rw-r--r--includes/rts/Flags.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/includes/rts/Flags.h b/includes/rts/Flags.h
index f27ce23b0b..4af19aa953 100644
--- a/includes/rts/Flags.h
+++ b/includes/rts/Flags.h
@@ -213,6 +213,12 @@ typedef struct _MISC_FLAGS {
bool generate_dump_file;
bool generate_stack_trace;
bool machineReadable;
+ bool disableDelayedOsMemoryReturn; /* See Note [MADV_FREE and MADV_DONTNEED].
+ It's in `MiscFlags` instead of
+ `GcFlags` because if GHC used madvise()
+ memory management for non-GC related
+ tasks in the future, we'd respect it
+ there as well. */
bool internalCounters; /* See Note [Internal Counter Stats] */
bool linkerAlwaysPic; /* Assume the object code is always PIC */
StgWord linkerMemBase; /* address to ask the OS for memory