[AArch64] Fix SDNode type mismatches between *.td files and ISel (#116523)
[llvm-project.git] / compiler-rt / lib / ubsan / ubsan_platform.h
blobd2cc2e10bd2f023b8d9aa1685a79a192a6d1e1e8
1 //===-- ubsan_platform.h ----------------------------------------*- C++ -*-===//
2 //
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
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // Defines the platforms which UBSan is supported at.
11 //===----------------------------------------------------------------------===//
12 #ifndef UBSAN_PLATFORM_H
13 #define UBSAN_PLATFORM_H
15 // Other platforms should be easy to add, and probably work as-is.
16 #if defined(__linux__) || defined(__FreeBSD__) || defined(__APPLE__) || \
17 defined(__NetBSD__) || defined(__DragonFly__) || \
18 (defined(__sun__) && defined(__svr4__)) || defined(_WIN32) || \
19 defined(__Fuchsia__)
20 #define CAN_SANITIZE_UB 1
21 #else
22 # define CAN_SANITIZE_UB 0
23 #endif
25 #endif