Skip to content

Conversation

@vchigrin
Copy link
Contributor

Clang version of libunwind uses long linear scan of the .eh_frame section if it fails to find frame information in .eh_frame_hdr.
That causes long times of stack unwinding in case when current stack has frames with missed FDE records, so it is better to have information about all frames in the stack up until frame which marks return address ad "undefined/unrecoverable".

@vchigrin
Copy link
Contributor Author

I am working on PR to clang to make stack walking times better in case of missed frames (See llvm/llvm-project#167849 ). But while generic solution is not ready, small local fix here seems resasonable.

@vchigrin
Copy link
Contributor Author

On our test binary these changes speed up stack unwinding rather strong. Time of construction of boost::stacktrace::stacktrace object in coroutine was:

Before changes: 5071µs
After changes: 82µs

@olk olk merged commit 639fa73 into boostorg:develop Dec 27, 2025
21 of 26 checks passed
@olk
Copy link
Member

olk commented Dec 27, 2025

ty

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants