1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
|
// Copyright (c) Meta Platforms, Inc. and affiliates.
// SPDX-License-Identifier: LGPL-2.1-or-later
/**
* @file
*
* Stack trace internals
*
* See @ref StackTraceInternals.
*/
#ifndef DRGN_STACK_TRACE_H
#define DRGN_STACK_TRACE_H
#include <elfutils/libdw.h>
#include <stddef.h>
/**
* @ingroup Internals
*
* @defgroup StackTraceInternals Stack traces
*
* Stack trace internals.
*
* This provides the internal data structures used for stack traces.
*
* @{
*/
struct drgn_stack_frame {
struct drgn_register_state *regs;
Dwarf_Die *scopes;
size_t num_scopes;
size_t function_scope;
};
struct drgn_stack_trace {
struct drgn_program *prog;
size_t num_frames;
struct drgn_stack_frame frames[];
};
/** @} */
#endif /* DRGN_STACK_TRACE_H */
|