1 //===-- definitions.h -------------------------------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 #ifndef GWP_ASAN_DEFINITIONS_H_
10 #define GWP_ASAN_DEFINITIONS_H_
12 #define GWP_ASAN_TLS_INITIAL_EXEC \
13 __thread __attribute__((tls_model("initial-exec")))
15 #define GWP_ASAN_LIKELY(EXPR) __builtin_expect((bool)(EXPR), true)
16 #define GWP_ASAN_UNLIKELY(EXPR) __builtin_expect((bool)(EXPR), false)
17 #define GWP_ASAN_ALWAYS_INLINE inline __attribute__((always_inline))
19 #define GWP_ASAN_WEAK __attribute__((weak))
21 #endif // GWP_ASAN_DEFINITIONS_H_