[clang] Handle __declspec() attributes in using
[llvm-project.git] / compiler-rt / lib / xray / xray_fdr_logging.h
blob6df0057c496539f3d82e350c17c48b047df9602f
1 //===-- xray_fdr_logging.h ------------------------------------------------===//
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 // This file is a part of XRay, a function call tracing system.
11 //===----------------------------------------------------------------------===//
12 #ifndef XRAY_XRAY_FDR_LOGGING_H
13 #define XRAY_XRAY_FDR_LOGGING_H
15 #include "xray/xray_log_interface.h"
16 #include "xray_fdr_log_records.h"
18 // FDR (Flight Data Recorder) Mode
19 // ===============================
21 // The XRay whitepaper describes a mode of operation for function call trace
22 // logging that involves writing small records into an in-memory circular
23 // buffer, that then gets logged to disk on demand. To do this efficiently and
24 // capture as much data as we can, we use smaller records compared to the
25 // default mode of always writing fixed-size records.
27 namespace __xray {
28 XRayLogInitStatus fdrLoggingInit(size_t BufferSize, size_t BufferMax,
29 void *Options, size_t OptionsSize);
30 XRayLogInitStatus fdrLoggingFinalize();
31 void fdrLoggingHandleArg0(int32_t FuncId, XRayEntryType Entry);
32 void fdrLoggingHandleArg1(int32_t FuncId, XRayEntryType Entry, uint64_t Arg1);
33 XRayLogFlushStatus fdrLoggingFlush();
34 XRayLogInitStatus fdrLoggingReset();
36 } // namespace __xray
38 #endif // XRAY_XRAY_FDR_LOGGING_H