Author: Jonas Devlieghere
Date: 2023-04-11T14:46:49-07:00
New Revision: b67b7bb2f73568efac077de189f86e86d9e010d6

URL: 
https://github.com/llvm/llvm-project/commit/b67b7bb2f73568efac077de189f86e86d9e010d6
DIFF: 
https://github.com/llvm/llvm-project/commit/b67b7bb2f73568efac077de189f86e86d9e010d6.diff

LOG: [lldb] Parse image high address from JSON crashlogs

Use the base + size to correctly populate the image high address when
parsing JSON crashlogs.

Differential revision: https://reviews.llvm.org/D148053

Added: 
    

Modified: 
    lldb/examples/python/crashlog.py

Removed: 
    


################################################################################
diff  --git a/lldb/examples/python/crashlog.py 
b/lldb/examples/python/crashlog.py
index 6a5c560238eeb..b09c03a50bb75 100755
--- a/lldb/examples/python/crashlog.py
+++ b/lldb/examples/python/crashlog.py
@@ -510,7 +510,8 @@ def parse_images(self, json_images):
         for json_image in json_images:
             img_uuid = uuid.UUID(json_image['uuid'])
             low = int(json_image['base'])
-            high = int(0)
+            high = low + int(
+                json_image['size']) if 'size' in json_image else low
             name = json_image['name'] if 'name' in json_image else ''
             path = json_image['path'] if 'path' in json_image else ''
             version = ''


        
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to