Skip to content

Commit de7836a

Browse files
committed
fix: iOS page size
1 parent 4455c7f commit de7836a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ggml/src/ggml.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -414,8 +414,8 @@ void * ggml_aligned_malloc(size_t size) {
414414
break;
415415
}
416416
#elif GGML_USE_METAL
417-
const auto page_size = sysconf(_SC_PAGESIZE);
418-
int result = posix_memalign(&aligned_memory, MAX(TENSOR_ALIGNMENT, page_size), sysconf(_SC_PAGESIZE), size);
417+
const long page_size = sysconf(_SC_PAGESIZE);
418+
int result = posix_memalign(&aligned_memory, MAX(TENSOR_ALIGNMENT, page_size), size);
419419
#else
420420
int result = posix_memalign(&aligned_memory, TENSOR_ALIGNMENT, size);
421421
#endif

0 commit comments

Comments
 (0)