]>
git.proxmox.com Git - rustc.git/blob - src/compiler-rt/lib/tsan/rtl/tsan_stack_trace.h
1 //===-- tsan_stack_trace.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 a part of ThreadSanitizer (TSan), a race detector.
12 //===----------------------------------------------------------------------===//
13 #ifndef TSAN_STACK_TRACE_H
14 #define TSAN_STACK_TRACE_H
16 #include "sanitizer_common/sanitizer_stacktrace.h"
17 #include "tsan_defs.h"
21 // StackTrace which calls malloc/free to allocate the buffer for
22 // addresses in stack traces.
23 struct VarSizeStackTrace
: public StackTrace
{
24 uptr
*trace_buffer
; // Owned.
28 void Init(const uptr
*pcs
, uptr cnt
, uptr extra_top_pc
= 0);
31 void ResizeBuffer(uptr new_size
);
33 VarSizeStackTrace(const VarSizeStackTrace
&);
34 void operator=(const VarSizeStackTrace
&);
39 #endif // TSAN_STACK_TRACE_H