--- a/src/util/malloc.c +++ b/src/util/malloc.c 2025-03-21 22:48:17.000000000 +0800 @@ -32,13 +32,17 @@ void *alpha_memalign(size_t bytes, size_t alignment) { #ifdef NUMA void *ret = numa_alloc_onnode(bytes, 0); -#else - void *ret = memalign(alignment, bytes); -#endif if (ret == NULL) { printf("no enough memory space to alloc!!!"); exit(-1); } +#else + void* ret; + if (posix_memalign(&ret, alignment, bytes) != 0) { + printf("no enough memory space to alloc!!!"); + exit(-1); + } +#endif return ret; }