summaryrefslogtreecommitdiff
path: root/simpleperf/OfflineUnwinder.cpp
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2021-11-10 14:27:45 -0800
committerChristopher Ferris <cferris@google.com>2022-01-04 16:39:23 -0800
commitaccebdab9f7ac0532a18aa09c9843190d6ee4a45 (patch)
tree25530d594500308c645dee7e7bfa93789c542a2e /simpleperf/OfflineUnwinder.cpp
parentbae691d7e6e86d989704ee9cf7c5c4da095b3884 (diff)
downloadextras-accebdab9f7ac0532a18aa09c9843190d6ee4a45.tar.gz
Update for MapInfo objects in frame data.
The frame data no longer contains map_XXX fields which represent the map data. Now there is only a shared pointer to the MapInfo object with which this frame is associated. Bug: 120606663 Test: Unit tests pass. Change-Id: I5ac8956ffab5b12f35bdd923265ec4e3a79b475f
Diffstat (limited to 'simpleperf/OfflineUnwinder.cpp')
-rw-r--r--simpleperf/OfflineUnwinder.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/simpleperf/OfflineUnwinder.cpp b/simpleperf/OfflineUnwinder.cpp
index b5bd8c0d..f611ef4d 100644
--- a/simpleperf/OfflineUnwinder.cpp
+++ b/simpleperf/OfflineUnwinder.cpp
@@ -274,17 +274,17 @@ bool OfflineUnwinderImpl::UnwindCallChain(const ThreadEntry& thread, const RegSe
for (auto& frame : unwinder.frames()) {
// Unwinding in arm architecture can return 0 pc address.
- // If frame.map.start == 0, this frame doesn't hit any map, it could be:
+ // If frame.map_info == nullptr, this frame doesn't hit any map, it could be:
// 1. In an executable map not backed by a file. Note that RecordCommand::ShouldOmitRecord()
// may omit maps only exist memory.
- // 2. An incorrectly unwound frame. Like caused by invalid stack data, as in
+ // 2. An incorrectly unwound frame. Likely caused by invalid stack data, as in
// SampleRecord::GetValidStackSize(). Or caused by incomplete JIT debug info.
// We want to remove this frame and callchains following it in either case.
- if (frame.pc == 0 || frame.map_start == 0) {
+ if (frame.map_info == nullptr) {
is_callchain_broken_for_incomplete_jit_debug_info_ = true;
break;
}
- if (frame.map_flags & unwindstack::MAPS_FLAGS_JIT_SYMFILE_MAP) {
+ if (frame.map_info->flags() & unwindstack::MAPS_FLAGS_JIT_SYMFILE_MAP) {
last_jit_method_frame = ips->size();
}
ips->push_back(frame.pc);