From f945278959aed62d2758fd48fea348b3fca0c0eb Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Mon, 2 Mar 2020 17:10:47 +0100 Subject: [PATCH] Fix rpmalloc on android. --- client/tracy_rpmalloc.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/tracy_rpmalloc.cpp b/client/tracy_rpmalloc.cpp index 9fe6e2fe..e7596aba 100644 --- a/client/tracy_rpmalloc.cpp +++ b/client/tracy_rpmalloc.cpp @@ -2102,9 +2102,11 @@ _memory_unmap_os(void* address, size_t size, size_t offset, size_t release) { #if defined(POSIX_MADV_FREE) if (posix_madvise(address, size, POSIX_MADV_FREE)) #endif +#if defined(POSIX_MADV_DONTNEED) if (posix_madvise(address, size, POSIX_MADV_DONTNEED)) { assert("Failed to madvise virtual memory block as free" == 0); } +#endif } #endif #endif