diff options
author | Med Ismail Bennani <medismail.bennani@gmail.com> | 2022-08-09 17:31:31 -0700 |
---|---|---|
committer | Med Ismail Bennani <medismail.bennani@gmail.com> | 2022-08-09 21:01:37 -0700 |
commit | 355be8cf801603756520cf5d9b4b5eaf9d1b2e77 (patch) | |
tree | 4c50d4da64a7d0bce378fbb559a1ab890293cc67 /lldb/examples | |
parent | 41c1a5f9bdc4cb6914e7971f50e4f45aeb11e087 (diff) | |
download | llvm-355be8cf801603756520cf5d9b4b5eaf9d1b2e77.tar.gz |
[lldb/crashlog] Skip null image dsym fetching on interactive mode
Sometimes, it can happen that a crash report has null images in its list
of used binaries. This manifests like such:
```
0x0 - 0xffffffffffffffff ??? (*) <00000000-0000-0000-0000-000000000000> ???
```
When fetching debug symbols to symbolicate the crashlog stackframe,
having null images causes `dsymForUUID` to hang for few seconds.
This patch addresses that by skipping null images from being load by the
scripted process.
rdar://97419487
Differential Revision: https://reviews.llvm.org/D131038
Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
Diffstat (limited to 'lldb/examples')
-rw-r--r-- | lldb/examples/python/scripted_process/crashlog_scripted_process.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lldb/examples/python/scripted_process/crashlog_scripted_process.py b/lldb/examples/python/scripted_process/crashlog_scripted_process.py index 6e7db946a018..3a5b175dce86 100644 --- a/lldb/examples/python/scripted_process/crashlog_scripted_process.py +++ b/lldb/examples/python/scripted_process/crashlog_scripted_process.py @@ -1,4 +1,4 @@ -import os,json,struct,signal +import os,json,struct,signal,uuid from typing import Any, Dict @@ -25,8 +25,11 @@ class CrashLogScriptedProcess(ScriptedProcess): if images: for image in images: if image not in self.loaded_images: + if image.uuid == uuid.UUID(int=0): + continue err = image.add_module(self.target) if err: + # Append to SBCommandReturnObject print(err) else: self.loaded_images.append(image) |