fix: iOS page size
This commit is contained in:
parent
4455c7f073
commit
de7836a4e3
1 changed files with 2 additions and 2 deletions
|
@ -414,8 +414,8 @@ void * ggml_aligned_malloc(size_t size) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
#elif GGML_USE_METAL
|
#elif GGML_USE_METAL
|
||||||
const auto page_size = sysconf(_SC_PAGESIZE);
|
const long page_size = sysconf(_SC_PAGESIZE);
|
||||||
int result = posix_memalign(&aligned_memory, MAX(TENSOR_ALIGNMENT, page_size), sysconf(_SC_PAGESIZE), size);
|
int result = posix_memalign(&aligned_memory, MAX(TENSOR_ALIGNMENT, page_size), size);
|
||||||
#else
|
#else
|
||||||
int result = posix_memalign(&aligned_memory, TENSOR_ALIGNMENT, size);
|
int result = posix_memalign(&aligned_memory, TENSOR_ALIGNMENT, size);
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue