[Lldb-commits] [lldb] 4ec9cda - [lldb/test] Fix failures following ec456ba9ca0a
Med Ismail Bennani via lldb-commits
lldb-commits at lists.llvm.org
Thu Oct 26 21:39:59 PDT 2023
Author: Med Ismail Bennani
Date: 2023-10-26T21:21:54-07:00
New Revision: 4ec9cda656cc2fde41d4a4415ae363d9a3290c80
URL: https://github.com/llvm/llvm-project/commit/4ec9cda656cc2fde41d4a4415ae363d9a3290c80
DIFF: https://github.com/llvm/llvm-project/commit/4ec9cda656cc2fde41d4a4415ae363d9a3290c80.diff
LOG: [lldb/test] Fix failures following ec456ba9ca0a
This patch fixes the various crashlog test failures following
ec456ba9ca0a, which renamed the process member variable in the Scripted
Thread python base class.
This patch updates the crashlog scripted process implementation to
reflect that change.
Signed-off-by: Med Ismail Bennani <ismail at bennani.ma>
Added:
Modified:
lldb/examples/python/crashlog_scripted_process.py
Removed:
################################################################################
diff --git a/lldb/examples/python/crashlog_scripted_process.py b/lldb/examples/python/crashlog_scripted_process.py
index 43f767de138cd50..c69985b1a072d09 100644
--- a/lldb/examples/python/crashlog_scripted_process.py
+++ b/lldb/examples/python/crashlog_scripted_process.py
@@ -159,14 +159,14 @@ def resolve_stackframes(thread, addr_mask, target):
return frames
def create_stackframes(self):
- if not (self.scripted_process.load_all_images or self.has_crashed):
+ if not (self.originating_process.load_all_images or self.has_crashed):
return None
if not self.backing_thread or not len(self.backing_thread.frames):
return None
self.frames = CrashLogScriptedThread.resolve_stackframes(
- self.backing_thread, self.scripted_process.addr_mask, self.target
+ self.backing_thread, self.originating_process.addr_mask, self.target
)
return self.frames
@@ -182,7 +182,7 @@ def __init__(self, process, args, crashlog_thread):
else:
self.name = self.backing_thread.name
self.queue = self.backing_thread.queue
- self.has_crashed = self.scripted_process.crashed_thread_idx == self.idx
+ self.has_crashed = self.originating_process.crashed_thread_idx == self.idx
self.create_stackframes()
def get_state(self):
@@ -195,8 +195,8 @@ def get_stop_reason(self) -> Dict[str, Any]:
return {"type": lldb.eStopReasonNone}
# TODO: Investigate what stop reason should be reported when crashed
stop_reason = {"type": lldb.eStopReasonException, "data": {}}
- if self.scripted_process.exception:
- stop_reason["data"]["mach_exception"] = self.scripted_process.exception
+ if self.originating_process.exception:
+ stop_reason["data"]["mach_exception"] = self.originating_process.exception
return stop_reason
def get_register_context(self) -> str:
@@ -209,5 +209,5 @@ def get_register_context(self) -> str:
def get_extended_info(self):
if self.has_crashed:
- self.extended_info = self.scripted_process.extended_thread_info
+ self.extended_info = self.originating_process.extended_thread_info
return self.extended_info
More information about the lldb-commits
mailing list