aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/utils/backtrace/backtrace_lib.h
blob: 3404716da68aaac78a7b9fc141247e3db93a0a7f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#pragma once

#include <util/generic/string.h>
#include <util/generic/vector.h>

namespace NYql {
    namespace NBacktrace {
        size_t CollectBacktrace(void** addresses, size_t limit, void* data);
        struct TCollectedFrame {
            TCollectedFrame(uintptr_t addr);
            TCollectedFrame() = default;
            const char* File;
            size_t Address;
        };
        size_t CollectFrames(TCollectedFrame* frames, void* data);
        size_t CollectFrames(TCollectedFrame* frames, void** stack, size_t cnt);
    }
}