Populating is_multiple in google_breakpad::StackFrame from symbol files.

This is needed in order to properly detect and highlight frames that
correspond to multiple functions, for example as the result of identical
code folding by the linker.

Bug: google-breakpad:751
Change-Id: I2ee7c147fcff6493c2454383ad5422b38269759a
Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/3471034
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
This commit is contained in:
Ivan Penkov 2022-02-17 03:18:03 +00:00
parent 34af6bcff1
commit fc1b9d3203
6 changed files with 35 additions and 12 deletions

View file

@ -319,6 +319,7 @@ void BasicSourceLineResolver::Module::LookupAddress(
address >= function_base && address - function_base < function_size) {
frame->function_name = func->name;
frame->function_base = frame->module->base_address() + function_base;
frame->is_multiple = func->is_multiple;
linked_ptr<Line> line;
MemAddr line_base;
@ -341,6 +342,7 @@ void BasicSourceLineResolver::Module::LookupAddress(
(!func.get() || public_address > function_base)) {
frame->function_name = public_symbol->name;
frame->function_base = frame->module->base_address() + public_address;
frame->is_multiple = public_symbol->is_multiple;
}
}