1 // RUN: %clang -O2 %s -o %t && %run %t
3 // Must not be implemented, no other reason to install interceptors.
8 #include <sanitizer/allocator_interface.h>
14 assert(__sanitizer_get_allocated_size(NULL
) == 0);
15 assert(malloc_usable_size(NULL
) == 0);
19 assert(__sanitizer_get_allocated_size(p
) == size
);
20 assert(__sanitizer_get_allocated_size_fast(p
) == size
);
21 assert(malloc_usable_size(p
) == size
);
26 assert(__sanitizer_get_allocated_size(p
) == size
);
27 assert(__sanitizer_get_allocated_size_fast(p
) == size
);
28 assert(malloc_usable_size(p
) == size
);