1 //===-- sanitizer_stackdepot.h ----------------------------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This file is shared between AddressSanitizer and ThreadSanitizer
11 // run-time libraries.
12 //===----------------------------------------------------------------------===//
13 #ifndef SANITIZER_STACKDEPOT_H
14 #define SANITIZER_STACKDEPOT_H
16 #include "sanitizer_internal_defs.h"
18 namespace __sanitizer
{
20 // StackDepot efficiently stores huge amounts of stack traces.
22 // Maps stack trace to an unique id.
23 u32
StackDepotPut(const uptr
*stack
, uptr size
);
24 // Retrieves a stored stack trace by the id.
25 const uptr
*StackDepotGet(u32 id
, uptr
*size
);
27 struct StackDepotStats
{
32 StackDepotStats
*StackDepotGetStats();
34 } // namespace __sanitizer
36 #endif // SANITIZER_STACKDEPOT_H