[Lldb-commits] [PATCH] D135310: [lldb/crashlog] Add support for 32bit frame addresses

Med Ismail Bennani via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Oct 5 13:02:18 PDT 2022

mib created this revision.
mib added a reviewer: kastiglione.
mib added a project: LLDB.
Herald added subscribers: JDevlieghere, kristof.beyls.
Herald added a project: All.
mib requested review of this revision.
Herald added a subscriber: lldb-commits.

This patch adds support for 32bit stack frame addresses in the `crashlog`

For crash reports that a generated from a arm64_32 process, `PAGEZERO` is
loaded at 0x00004000 so no code address will be less than 0x4000.

This patch changes the crashlog frame address regex group to match
addresses as small as 4 hex characters.


Signed-off-by: Med Ismail Bennani <medismail.bennani at gmail.com>

  rG LLVM Github Monorepo



Index: lldb/examples/python/crashlog.py
--- lldb/examples/python/crashlog.py
+++ lldb/examples/python/crashlog.py
@@ -642,7 +642,7 @@
     frame_regex = re.compile(r'^(\d+)\s+'              # id
                              r'(.+?)\s+'               # img_name
                              r'(?:' +version+ r'\s+)?' # img_version
-                             r'(0x[0-9a-fA-F]{7,})'    # addr (7 chars or more)
+                             r'(0x[0-9a-fA-F]{4,})'    # addr (4 chars or more)
                              r' +(.*)'                 # offs
     null_frame_regex = re.compile(r'^\d+\s+\?\?\?\s+0{7,} +')

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D135310.465517.patch
Type: text/x-patch
Size: 719 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20221005/75b0883c/attachment.bin>

More information about the lldb-commits mailing list