From b6ab076d6b7dd91ce0dda8741ba974b2402fa726 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Mon, 18 May 2015 15:58:02 -0700 Subject: [PATCH] vk/allocator: Don't use memfd when valgrind is detected --- src/vulkan/allocator.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/vulkan/allocator.c b/src/vulkan/allocator.c index 94b7d548bfc..5cabc466841 100644 --- a/src/vulkan/allocator.c +++ b/src/vulkan/allocator.c @@ -203,7 +203,11 @@ anv_block_pool_init(struct anv_block_pool *pool, * without copying. It breaks valgrind however, so we have a MAP_ANONYMOUS * path we can take for valgrind debugging. */ -#define USE_MEMFD 1 +#ifdef HAVE_VALGRIND +# define USE_MEMFD 0 +#else +# define USE_MEMFD 1 +#endif void anv_block_pool_finish(struct anv_block_pool *pool) -- 2.30.2