On Fri, Apr 27, 2018 at 08:56:04PM -0700, Josh Elsasser wrote:
> Patching the i386 and ppc *-arch.c files isn't necessary. However i386
> didn't build for me (in a VM). I think we need to do this in
> patches/patch-src_runtime_bsd-os_c:

This is obviously wrong now that I look closer. I'll investigate further.

> $OpenBSD$
> 
> MAP_TRYFIXED is needed to allow SBCL to relocate its heap if the
> hardcoded virtual address is unavailable.
> 
> Index: src/runtime/bsd-os.c
> --- src/runtime/bsd-os.c.orig
> +++ src/runtime/bsd-os.c
> @@ -157,7 +157,11 @@ os_validate(int movable, os_vm_address_t addr, os_vm_s
>           * the hint address, and moreover that it "is the default behavior") 
> */
>          // FALLTHROUGH_INTENDED
>      case NOT_MOVABLE:
> +#ifdef MAP_TRYFIXED
> +        flags = MAP_TRYFIXED;
> +#else
>          flags = MAP_FIXED;
> +#endif
>      }
>  #ifdef MAP_EXCL // not defined in OpenBSD, NetBSD, DragonFlyBSD
>      if (flags & MAP_FIXED) flags |= MAP_EXCL;
> 

Reply via email to