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

ruby-changes:30949

From: charliesome <ko1@a...>
Date: Tue, 24 Sep 2013 14:10:04 +0900 (JST)
Subject: [ruby-changes:30949] charliesome:r43028 (trunk): * gc.c (free_method_cache_entry_i): unused function

charliesome	2013-09-24 14:09:57 +0900 (Tue, 24 Sep 2013)

  New Revision: 43028

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=43028

  Log:
    * gc.c (free_method_cache_entry_i): unused function
    
    * gc.c (rb_free_mc_table): ditto
    
    * internal.h (method_cache_entry_t): unused struct
    
    * vm_method.c (verify_method_cache): remove unused variable
    
    * vm_method.c (rb_method_entry): ditto

  Modified files:
    trunk/ChangeLog
    trunk/gc.c
    trunk/internal.h
    trunk/vm_method.c
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 43027)
+++ ChangeLog	(revision 43028)
@@ -1,3 +1,15 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Sep 24 14:07:00 2013  Charlie Somerville  <charliesome@r...>
+
+	* gc.c (free_method_cache_entry_i): unused function
+
+	* gc.c (rb_free_mc_table): ditto
+
+	* internal.h (method_cache_entry_t): unused struct
+
+	* vm_method.c (verify_method_cache): remove unused variable
+
+	* vm_method.c (rb_method_entry): ditto
+
 Tue Sep 24 14:01:00 2013  Charlie Somerville  <charliesome@r...>
 
 	* class.c (class_alloc): remove mc_tbl
Index: vm_method.c
===================================================================
--- vm_method.c	(revision 43027)
+++ vm_method.c	(revision 43028)
@@ -565,7 +565,6 @@ static void https://github.com/ruby/ruby/blob/trunk/vm_method.c#L565
 verify_method_cache(VALUE klass, ID id, VALUE defined_class, rb_method_entry_t *me)
 {
     VALUE actual_defined_class;
-    method_cache_entry_t ent;
     rb_method_entry_t *actual_me =
 	rb_method_entry_get_without_cache(klass, id, &actual_defined_class);
 
@@ -591,9 +590,6 @@ rb_method_entry(VALUE klass, ID id, VALU https://github.com/ruby/ruby/blob/trunk/vm_method.c#L590
 #endif
 	return ent->me;
     }
-#else
-    method_cache_entry_t ent_;
-    method_cache_entry_t* ent = &ent_;
 #endif
 
     return rb_method_entry_get_without_cache(klass, id, defined_class_ptr);
Index: gc.c
===================================================================
--- gc.c	(revision 43027)
+++ gc.c	(revision 43028)
@@ -1122,20 +1122,6 @@ rb_free_m_table(st_table *tbl) https://github.com/ruby/ruby/blob/trunk/gc.c#L1122
 }
 
 static int
-free_method_cache_entry_i(ID key, method_cache_entry_t *entry, st_data_t data)
-{
-    free(entry);
-    return ST_CONTINUE;
-}
-
-void
-rb_free_mc_table(st_table *tbl)
-{
-    st_foreach(tbl, free_method_cache_entry_i, 0);
-    st_free_table(tbl);
-}
-
-static int
 free_const_entry_i(ID key, rb_const_entry_t *ce, st_data_t data)
 {
     xfree(ce);
Index: internal.h
===================================================================
--- internal.h	(revision 43027)
+++ internal.h	(revision 43028)
@@ -252,16 +252,6 @@ typedef uint64_t vm_state_version_t; https://github.com/ruby/ruby/blob/trunk/internal.h#L252
 typedef unsigned long vm_state_version_t;
 #endif
 
-struct rb_method_entry_struct;
-
-typedef struct method_cache_entry {
-    vm_state_version_t vm_state;
-    vm_state_version_t seq;
-    ID mid;
-    VALUE defined_class;
-    struct rb_method_entry_struct *me;
-} method_cache_entry_t;
-
 struct rb_classext_struct {
     VALUE super;
     struct st_table *iv_tbl;

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

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