Path: blob/main/contrib/llvm-project/compiler-rt/lib/ubsan/ubsan_init_standalone.cpp
35233 views
//===-- ubsan_init_standalone.cpp -----------------------------------------===//1//2// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.3// See https://llvm.org/LICENSE.txt for license information.4// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception5//6//===----------------------------------------------------------------------===//7//8// Initialization of standalone UBSan runtime.9//10//===----------------------------------------------------------------------===//1112#include "ubsan_platform.h"13#if !CAN_SANITIZE_UB14# error "UBSan is not supported on this platform!"15#endif1617#include "sanitizer_common/sanitizer_internal_defs.h"18#include "ubsan_init.h"19#include "ubsan_signals_standalone.h"2021namespace __ubsan {2223class UbsanStandaloneInitializer {24public:25UbsanStandaloneInitializer() {26InitAsStandalone();27InitializeDeadlySignals();28}29};30static UbsanStandaloneInitializer ubsan_standalone_initializer;3132} // namespace __ubsan333435