[前][次][番号順一覧][スレッド一覧]

ruby-changes:61083

From: Aaron <ko1@a...>
Date: Fri, 8 May 2020 07:54:28 +0900 (JST)
Subject: [ruby-changes:61083] 7574b836a9 (master): Add T_IMEMO support to lldb

https://git.ruby-lang.org/ruby.git/commit/?id=7574b836a9

From 7574b836a96fe4716ee40c920aa21ceb9530e733 Mon Sep 17 00:00:00 2001
From: Aaron Patterson <tenderlove@r...>
Date: Thu, 7 May 2020 15:52:29 -0700
Subject: Add T_IMEMO support to lldb

I'm trying to find why a reference to an IMEMO object isn't being
updated

diff --git a/misc/lldb_cruby.py b/misc/lldb_cruby.py
index 4ed0250..fff8cc7 100755
--- a/misc/lldb_cruby.py
+++ b/misc/lldb_cruby.py
@@ -236,6 +236,12 @@ def lldb_inspect(debugger, target, result, val): https://github.com/ruby/ruby/blob/trunk/misc/lldb_cruby.py#L236
             tRTypedData = target.FindFirstType("struct RMoved").GetPointerType()
             val = val.Cast(tRTypedData)
             append_command_output(debugger, "p *(struct RMoved *) %0#x" % val.GetValueAsUnsigned(), result)
+        elif flType == RUBY_T_IMEMO:
+            # I'm not sure how to get IMEMO_MASK out of lldb. It's not in globals()
+            imemo_type = (flags >> RUBY_FL_USHIFT) & 0x0F # IMEMO_MASK
+            print("T_IMEMO: ", file=result)
+            append_command_output(debugger, "p (enum imemo_type) %d" % imemo_type, result)
+            append_command_output(debugger, "p *(struct MEMO *) %0#x" % val.GetValueAsUnsigned(), result)
         else:
             print("Not-handled type %0#x" % flType, file=result)
             print(val, file=result)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]