aboutsummaryrefslogtreecommitdiffstats
path: root/vm_trace.c
diff options
context:
space:
mode:
authorPeter Zhu <peter@peterzhu.ca>2023-11-22 09:24:25 -0500
committerPeter Zhu <peter@peterzhu.ca>2023-11-22 16:01:00 -0500
commit5672fb63d21ca8311513c44a82ffe5a0c8f55240 (patch)
tree610879084e876e40bbb3ce527850580376ab70d3 /vm_trace.c
parent8d6175bf64748eb646a83c74ff7bd541fdec166d (diff)
downloadruby-5672fb63d21ca8311513c44a82ffe5a0c8f55240.tar.gz
Implement TracePoint on VWA
Diffstat (limited to 'vm_trace.c')
-rw-r--r--vm_trace.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/vm_trace.c b/vm_trace.c
index eb81bf8bf7..6114ef9d4e 100644
--- a/vm_trace.c
+++ b/vm_trace.c
@@ -779,16 +779,14 @@ tp_mark(void *ptr)
if (tp->target_th) rb_gc_mark(tp->target_th->self);
}
-static size_t
-tp_memsize(const void *ptr)
-{
- return sizeof(rb_tp_t);
-}
-
static const rb_data_type_t tp_data_type = {
"tracepoint",
- {tp_mark, RUBY_TYPED_DEFAULT_FREE, tp_memsize,},
- 0, 0, RUBY_TYPED_FREE_IMMEDIATELY | RUBY_TYPED_WB_PROTECTED
+ {
+ tp_mark,
+ RUBY_TYPED_DEFAULT_FREE,
+ NULL, // Nothing allocated externally, so don't need a memsize function
+ },
+ 0, 0, RUBY_TYPED_FREE_IMMEDIATELY | RUBY_TYPED_WB_PROTECTED | RUBY_TYPED_EMBEDDABLE
};
static VALUE