From 3aa6c3bf04e024e383766bc1068ed3eb850adeed Mon Sep 17 00:00:00 2001 From: sewer56 Date: Sat, 25 Nov 2023 01:25:07 +0000 Subject: [PATCH] I will assume I screwed this before committing, and will promptly (just in case) revert to 16K hardcoded --- src-rust/src/utilities/cached.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src-rust/src/utilities/cached.rs b/src-rust/src/utilities/cached.rs index 54b052f..0737ccd 100644 --- a/src-rust/src/utilities/cached.rs +++ b/src-rust/src/utilities/cached.rs @@ -83,9 +83,10 @@ impl Cached { #[cfg(all(target_os = "macos", target_arch = "aarch64"))] { // Apple lies about page size in libc on M1 says it's 4096 instead of 16384 - *page_size = MmapOptions::page_size() as i32; + *page_size = 16384; } + // Blame Apple *allocation_granularity = std::cmp::max(MmapOptions::allocation_granularity() as i32, *page_size); }