diff options
Diffstat (limited to 'libunwindstack/include/unwindstack')
-rw-r--r-- | libunwindstack/include/unwindstack/Error.h | 7 | ||||
-rw-r--r-- | libunwindstack/include/unwindstack/Unwinder.h | 4 |
2 files changed, 11 insertions, 0 deletions
diff --git a/libunwindstack/include/unwindstack/Error.h b/libunwindstack/include/unwindstack/Error.h index 72ec4547f..66fefe76d 100644 --- a/libunwindstack/include/unwindstack/Error.h +++ b/libunwindstack/include/unwindstack/Error.h @@ -21,6 +21,13 @@ namespace unwindstack { +// A bit map of warnings, multiple warnings can be set at the same time. +enum WarningCode : uint64_t { + WARNING_NONE = 0, + WARNING_DEX_PC_NOT_IN_MAP = 0x1, // A dex pc was found, but it doesn't exist + // in any valid map. +}; + enum ErrorCode : uint8_t { ERROR_NONE, // No error. ERROR_MEMORY_INVALID, // Memory read failed. diff --git a/libunwindstack/include/unwindstack/Unwinder.h b/libunwindstack/include/unwindstack/Unwinder.h index 4d49f236a..3df8aadfd 100644 --- a/libunwindstack/include/unwindstack/Unwinder.h +++ b/libunwindstack/include/unwindstack/Unwinder.h @@ -113,12 +113,15 @@ class Unwinder { ErrorCode LastErrorCode() { return last_error_.code; } uint64_t LastErrorAddress() { return last_error_.address; } + uint64_t warnings() { return warnings_; } // Builds a frame for symbolization using the maps from this unwinder. The // constructed frame contains just enough information to be used to symbolize // frames collected by frame-pointer unwinding that's done outside of // libunwindstack. This is used by tombstoned to symbolize frame pointer-based // stack traces that are collected by tools such as GWP-ASan and MTE. + static FrameData BuildFrameFromPcOnly(uint64_t pc, ArchEnum arch, Maps* maps, JitDebug* jit_debug, + std::shared_ptr<Memory> process_memory, bool resolve_names); FrameData BuildFrameFromPcOnly(uint64_t pc); protected: @@ -141,6 +144,7 @@ class Unwinder { // file. This is only true if there is an actual file backing up the elf. bool elf_from_memory_not_file_ = false; ErrorData last_error_; + uint64_t warnings_; }; class UnwinderFromPid : public Unwinder { |