ruby-changes:35434
From: ko1 <ko1@a...>
Date: Wed, 10 Sep 2014 17:54:14 +0900 (JST)
Subject: [ruby-changes:35434] ko1:r47516 (trunk): * compile.c (rb_vm_addr2insn): rename to rb_vm_insn_addr2insn
ko1 2014-09-10 17:53:56 +0900 (Wed, 10 Sep 2014) New Revision: 47516 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=47516 Log: * compile.c (rb_vm_addr2insn): rename to rb_vm_insn_addr2insn to clear what address. Modified files: trunk/ChangeLog trunk/compile.c Index: ChangeLog =================================================================== --- ChangeLog (revision 47515) +++ ChangeLog (revision 47516) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Wed Sep 10 17:52:25 2014 Koichi Sasada <ko1@a...> + + * compile.c (rb_vm_addr2insn): rename to rb_vm_insn_addr2insn + to clear what address. + Wed Sep 10 16:22:26 2014 Koichi Sasada <ko1@a...> * test/ruby/test_gc.rb: fix condition. Index: compile.c =================================================================== --- compile.c (revision 47515) +++ compile.c (revision 47516) @@ -581,16 +581,17 @@ rb_iseq_translate_threaded_code(rb_iseq_ https://github.com/ruby/ruby/blob/trunk/compile.c#L581 #if OPT_DIRECT_THREADED_CODE || OPT_CALL_THREADED_CODE static int -rb_vm_addr2insn(const void *addr) /* cold path */ +rb_vm_insn_addr2insn(const void *addr) /* cold path */ { int insn; const void * const *table = rb_vm_get_insns_address_table(); for (insn = 0; insn < VM_INSTRUCTION_SIZE; insn++) { - if (table[insn] == addr) + if (table[insn] == addr) { return insn; + } } - rb_bug("rb_vm_addr2insn: invalid insn address: %p", addr); + rb_bug("rb_vm_insn_addr2insn: invalid insn address: %p", addr); } #endif @@ -609,7 +610,7 @@ rb_iseq_original_iseq(rb_iseq_t *iseq) / https://github.com/ruby/ruby/blob/trunk/compile.c#L610 for (i = 0; i < iseq->iseq_size; /* */ ) { const void *addr = (const void *)iseq->iseq[i]; - int insn = rb_vm_addr2insn(addr); + const int insn = rb_vm_insn_addr2insn(addr); iseq->iseq[i] = insn; i += insn_len(insn); -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/