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

ruby-changes:43680

From: ko1 <ko1@a...>
Date: Tue, 26 Jul 2016 18:57:55 +0900 (JST)
Subject: [ruby-changes:43680] ko1:r55753 (trunk): * gc.c (gc_mark): add `inline' explicitly.

ko1	2016-07-26 18:57:50 +0900 (Tue, 26 Jul 2016)

  New Revision: 55753

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=55753

  Log:
    * gc.c (gc_mark): add `inline' explicitly.
      I expected to inline this function implicitly at the loop
      (ex: marking T_ARRAY objects) but sometimes it remains as
      normal call.

  Modified files:
    trunk/ChangeLog
    trunk/gc.c
Index: gc.c
===================================================================
--- gc.c	(revision 55752)
+++ gc.c	(revision 55753)
@@ -853,7 +853,7 @@ static void gc_sweep_rest(rb_objspace_t https://github.com/ruby/ruby/blob/trunk/gc.c#L853
 static void gc_sweep_continue(rb_objspace_t *objspace, rb_heap_t *heap);
 #endif
 
-static void gc_mark(rb_objspace_t *objspace, VALUE ptr);
+static inline void gc_mark(rb_objspace_t *objspace, VALUE ptr);
 static void gc_mark_ptr(rb_objspace_t *objspace, VALUE ptr);
 static void gc_mark_maybe(rb_objspace_t *objspace, VALUE ptr);
 static void gc_mark_children(rb_objspace_t *objspace, VALUE ptr);
@@ -4347,7 +4347,7 @@ gc_mark_ptr(rb_objspace_t *objspace, VAL https://github.com/ruby/ruby/blob/trunk/gc.c#L4347
     }
 }
 
-static void
+static inline void
 gc_mark(rb_objspace_t *objspace, VALUE obj)
 {
     if (!is_markable_object(objspace, obj)) return;
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 55752)
+++ ChangeLog	(revision 55753)
@@ -1,3 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Jul 26 18:55:55 2016  Koichi Sasada  <ko1@a...>
+
+	* gc.c (gc_mark): add `inline' explicitly.
+	  I expected to inline this function implicitly at the loop
+	  (ex: marking T_ARRAY objects) but sometimes it remains as
+	  normal call.
+
 Tue Jul 26 16:33:16 2016  Martin Duerst  <duerst@i...>
 
 	* enc/windows_1257.c, test/ruby/enc/test_case_comprehensive.rb:

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

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