1 //===-- backtrace_fuchsia.cpp -----------------------------------*- 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 #include "gwp_asan/optional/backtrace.h"
11 #include <zircon/sanitizer.h>
16 // Fuchsia's C library provides safe, fast, best-effort backtraces itself.
17 options::Backtrace_t
getBacktraceFunction() {
18 return __sanitizer_fast_backtrace
;
21 // These are only used in fatal signal handling, which is not used on Fuchsia.
23 PrintBacktrace_t
getPrintBacktraceFunction() { return nullptr; }
24 SegvBacktrace_t
getSegvBacktraceFunction() { return nullptr; }
26 } // namespace backtrace
27 } // namespace gwp_asan