Commit bc7cc256 authored by kgardas's avatar kgardas

disable large address space on OpenBSD

Summary:
This patch disables large address space on OpenBSD. The motivation
for this is that OpenBSD does not support MAP_NORESERVE. The flag is supported
only for source code compatibility reasons but is otherwise completely ignored
by the OS and its mmap syscall.

Reviewers: austin, bgamari

Subscribers: thomie, erikd

Differential Revision: https://phabricator.haskell.org/D1411
parent 8f02baac
......@@ -1046,6 +1046,11 @@ if test "$ac_cv_sizeof_void_p" -eq 8 ; then
if test "x$EnableLargeAddressSpace" = "xyes" ; then
if test "$ghc_host_os" = "darwin" ; then
use_large_address_space=yes
elif test "$ghc_host_os" = "openbsd" ; then
# as of OpenBSD 5.8 (2015), OpenBSD does not support mmap with MAP_NORESERVE.
# The flag MAP_NORESERVE is supported for source compatibility reasons,
# but is completely ignored by OS mmap
use_large_address_space=no
else
AC_CHECK_DECLS([MAP_NORESERVE, MADV_FREE, MADV_DONTNEED],[],[],
[
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment