Lines Matching refs:GuardedAlloc
50 static gwp_asan::GuardedPoolAllocator GuardedAlloc; variable
72 GuardedAlloc.init(Opts); in gwp_asan_initialize()
77 __libc_shared_globals()->gwp_asan_state = GuardedAlloc.getAllocatorState(); in gwp_asan_initialize()
78 __libc_shared_globals()->gwp_asan_metadata = GuardedAlloc.getMetadataRegion(); in gwp_asan_initialize()
112 if (__predict_false(GuardedAlloc.shouldSample())) { in gwp_asan_calloc()
115 if (void* result = GuardedAlloc.allocate(bytes)) { in gwp_asan_calloc()
124 if (__predict_false(GuardedAlloc.pointerIsMine(mem))) { in gwp_asan_free()
125 GuardedAlloc.deallocate(mem); in gwp_asan_free()
132 if (__predict_false(GuardedAlloc.shouldSample())) { in gwp_asan_malloc()
133 if (void* result = GuardedAlloc.allocate(bytes)) { in gwp_asan_malloc()
141 if (__predict_false(GuardedAlloc.pointerIsMine(mem))) { in gwp_asan_malloc_usable_size()
142 return GuardedAlloc.getSize(mem); in gwp_asan_malloc_usable_size()
148 if (__predict_false(GuardedAlloc.pointerIsMine(old_mem))) { in gwp_asan_realloc()
149 size_t old_size = GuardedAlloc.getSize(old_mem); in gwp_asan_realloc()
152 GuardedAlloc.deallocate(old_mem); in gwp_asan_realloc()
160 if (__predict_false(GuardedAlloc.pointerIsMine(reinterpret_cast<void*>(base)))) { in gwp_asan_malloc_iterate()
163 GuardedAlloc.iterate(reinterpret_cast<void*>(base), size, callback, arg); in gwp_asan_malloc_iterate()
170 GuardedAlloc.disable(); in gwp_asan_malloc_disable()
175 GuardedAlloc.enable(); in gwp_asan_malloc_enable()