1 #ifndef __SANITIZER_COMMON_SANITIZER_SPECIFIC_H__
2 #define __SANITIZER_COMMON_SANITIZER_SPECIFIC_H__
5 # define __has_feature(x) 0
8 #if __has_feature(memory_sanitizer)
9 # include <sanitizer/msan_interface.h>
10 static void check_mem_is_good(void *p
, size_t s
) {
11 __msan_check_mem_is_initialized(p
, s
);
13 #elif __has_feature(address_sanitizer)
14 # include <sanitizer/asan_interface.h>
16 static void check_mem_is_good(void *p
, size_t s
) {
17 if (__asan_region_is_poisoned(p
, s
))
21 static void check_mem_is_good(void *p
, size_t s
) {}
24 #endif // __SANITIZER_COMMON_SANITIZER_SPECIFIC_H__