Path: blob/main/contrib/llvm-project/compiler-rt/lib/asan/asan_preinit.cpp
35233 views
//===-- asan_preinit.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// This file is a part of AddressSanitizer, an address sanity checker.9//10// Call __asan_init at the very early stage of process startup.11//===----------------------------------------------------------------------===//12#include "asan_internal.h"1314using namespace __asan;1516#if SANITIZER_CAN_USE_PREINIT_ARRAY17// This section is linked into the main executable when -fsanitize=address is18// specified to perform initialization at a very early stage.19__attribute__((section(".preinit_array"), used)) static auto preinit =20__asan_init;21#endif222324