ruby-changes:61942
From: Takashi <ko1@a...>
Date: Fri, 26 Jun 2020 15:51:04 +0900 (JST)
Subject: [ruby-changes:61942] 40b40523dc (master): Show what's inlined first in "JIT inline" log
https://git.ruby-lang.org/ruby.git/commit/?id=40b40523dc From 40b40523dcf957fa9459c1c1037ad79d73867f83 Mon Sep 17 00:00:00 2001 From: Takashi Kokubun <takashikkbn@g...> Date: Thu, 25 Jun 2020 23:50:18 -0700 Subject: Show what's inlined first in "JIT inline" log and add a debug log diff --git a/mjit_compile.c b/mjit_compile.c index 8ceab55..40cea80 100644 --- a/mjit_compile.c +++ b/mjit_compile.c @@ -459,10 +459,10 @@ precompile_inlinable_iseqs(FILE *f, const rb_iseq_t *iseq, struct compile_status https://github.com/ruby/ruby/blob/trunk/mjit_compile.c#L459 if (mjit_opts.verbose >= 1) // print beforehand because ISeq may be GCed during copy job. fprintf(stderr, "JIT inline: %s@%s:%d => %s@%s:%d\n", - RSTRING_PTR(iseq->body->location.label), - RSTRING_PTR(rb_iseq_path(iseq)), FIX2INT(iseq->body->location.first_lineno), RSTRING_PTR(child_iseq->body->location.label), - RSTRING_PTR(rb_iseq_path(child_iseq)), FIX2INT(child_iseq->body->location.first_lineno)); + RSTRING_PTR(rb_iseq_path(child_iseq)), FIX2INT(child_iseq->body->location.first_lineno), + RSTRING_PTR(iseq->body->location.label), + RSTRING_PTR(rb_iseq_path(iseq)), FIX2INT(iseq->body->location.first_lineno)); struct compile_status child_status = { .compiled_iseq = status->compiled_iseq, .compiled_id = status->compiled_id }; INIT_COMPILE_STATUS(child_status, child_iseq->body, false); diff --git a/tool/ruby_vm/views/_mjit_compile_send.erb b/tool/ruby_vm/views/_mjit_compile_send.erb index 8c1c1c0..6b271d4 100644 --- a/tool/ruby_vm/views/_mjit_compile_send.erb +++ b/tool/ruby_vm/views/_mjit_compile_send.erb @@ -30,6 +30,9 @@ https://github.com/ruby/ruby/blob/trunk/tool/ruby_vm/views/_mjit_compile_send.erb#L30 && fastpath_applied_iseq_p(ci, captured_cc, iseq = def_iseq_ptr(vm_cc_cme(captured_cc)->def)) && !(vm_ci_flag(ci) & VM_CALL_TAILCALL)) )) { + if (false && vm_cc_cme(captured_cc)->def->type == VM_METHOD_TYPE_CFUNC) + fprintf(stderr, " * %s\n", rb_id2name(vm_ci_mid(ci))); + int sp_inc = (int)sp_inc_of_sendish(ci); fprintf(f, "{\n"); -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/