From 0558a9391d54e8c996b256c55acce1f92ee14a56 Mon Sep 17 00:00:00 2001 From: "Moe Charm (CI)" Date: Sun, 30 Nov 2025 15:08:45 +0900 Subject: [PATCH] Fix: Enable SuperSlab backend by default to resolve OOM. Previously, was not defined at compile-time, disabling the SuperSlab backend's fallback to the legacy path and causing OOMs. This commit sets to 1 in and ensures its inclusion in . --- core/hakmem_build_flags.h | 7 +++++++ core/hakmem_tiny_superslab_internal.h | 1 + 2 files changed, 8 insertions(+) diff --git a/core/hakmem_build_flags.h b/core/hakmem_build_flags.h index f019b86c..4b0b1f83 100644 --- a/core/hakmem_build_flags.h +++ b/core/hakmem_build_flags.h @@ -45,6 +45,13 @@ # define HAKMEM_TINY_PHASE6_BOX_REFACTOR 1 #endif +// SuperSlab backend toggle (compile-time) +// Default: 1 (ON) - SuperSlab is the core architecture. +// Set to 0 only for legacy/compat testing. +#ifndef HAKMEM_TINY_USE_SUPERSLAB +# define HAKMEM_TINY_USE_SUPERSLAB 1 +#endif + // ------------------------------------------------------------ // Phase 7: Region-ID Direct Lookup (Header-based optimization) // ------------------------------------------------------------ diff --git a/core/hakmem_tiny_superslab_internal.h b/core/hakmem_tiny_superslab_internal.h index 5923a726..5c4381a8 100644 --- a/core/hakmem_tiny_superslab_internal.h +++ b/core/hakmem_tiny_superslab_internal.h @@ -6,6 +6,7 @@ #ifndef HAKMEM_TINY_SUPERSLAB_INTERNAL_H #define HAKMEM_TINY_SUPERSLAB_INTERNAL_H +#include "hakmem_build_flags.h" // CRITICAL: Ensure HAKMEM_TINY_USE_SUPERSLAB is defined #include "hakmem_tiny_superslab.h" #include "box/ss_hot_cold_box.h" #include "box/ss_allocation_box.h" // CRITICAL: For superslab_allocate() declaration (fixes implicit int assumption)