|
Boost Users : |
Subject: [Boost-users] [boost][stacktrace] stacktrace keep eating memory
From: Hao Jiang (drakedog2008_at_[hidden])
Date: 2019-03-20 10:05:00
I am using stacktrace on Windows. I found stacktrace keep eating my memory. A simple test program:
void foo() {
auto st = boost::stacktrace::stacktrace{};
auto line = st.begin()->source_line();
std::cout << line << std::endl;
}
void main() {
for (int i = 0; i < 0xFFFF; i++) {
foo();
}
}
Based on MSVC memory profiling tool, memory usage keep growth:
[cid:image001.png_at_01D4DF46.BA4E1090]
And frame allocator is taking heap:
[cid:image004.png_at_01D4DF47.6F38C310]
Anyone knows why it happens?
Br,
Hao.
Platform: Windows 7.
Compiler: MSVC 2017
Boost version: 1.67
Compile and link: release, static-link, static runtime.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net