[#80974] [Ruby trunk Feature#13517] [PATCH] reduce rb_mutex_t size from 160 to 80 bytes on 64-bit — ko1@...
Issue #13517 has been updated by ko1 (Koichi Sasada).
4 messages
2017/05/02
[#81024] Re: [Ruby trunk Feature#13517] [PATCH] reduce rb_mutex_t size from 160 to 80 bytes on 64-bit
— SASADA Koichi <ko1@...>
2017/05/07
sorry for late response.
[#80996] [Ruby trunk Feature#13544] Allow loading an ISeqs sequence directly from a C extension without requiring buffer is in an RVALUE — sam.saffron@...
Issue #13544 has been reported by sam.saffron (Sam Saffron).
3 messages
2017/05/04
[#81016] [Ruby trunk Bug#13526] Segmentation fault at 0x0055c2e58e8920 ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-linux] — s.wanabe@...
Issue #13526 has been updated by wanabe (_ wanabe).
3 messages
2017/05/07
[#81048] Re: [ruby-cvs:65788] normal:r58614 (trunk): rb_execution_context_t: move stack, stack_size and cfp from rb_thread_t — SASADA Koichi <ko1@...>
It causes compile error on raspi 3.
3 messages
2017/05/09
[#81201] Re: [ruby-cvs:65935] normal:r58761 (trunk): test/test_extilibs.rb: do not check the existence of fiddle — "U.NAKAMURA" <usa@...>
Hi, Eric
4 messages
2017/05/16
[#81202] Re: [ruby-cvs:65935] normal:r58761 (trunk): test/test_extilibs.rb: do not check the existence of fiddle
— Eric Wong <normalperson@...>
2017/05/16
"U.NAKAMURA" <usa@garbagecollect.jp> wrote:
[#81427] Fwd: [ruby-changes:46809] normal:r58924 (trunk): test for IO.copy_stream CPU usage (r58534) — SASADA Koichi <ko1@...>
Hi,
6 messages
2017/05/28
[#81428] Re: Fwd: [ruby-changes:46809] normal:r58924 (trunk): test for IO.copy_stream CPU usage (r58534)
— Eric Wong <normalperson@...>
2017/05/28
SASADA Koichi <ko1@atdot.net> wrote:
[ruby-core:81400] [Ruby trunk Feature#13602] Optimize instance variable access if $VERBOSE is not true when compiling
From:
merch-redmine@...
Date:
2017-05-26 20:48:49 UTC
List:
ruby-core #81400
Issue #13602 has been reported by jeremyevans0 (Jeremy Evans).
----------------------------------------
Feature #13602: Optimize instance variable access if $VERBOSE is not true when compiling
https://bugs.ruby-lang.org/issues/13602
* Author: jeremyevans0 (Jeremy Evans)
* Status: Open
* Priority: Normal
* Assignee:
* Target version:
----------------------------------------
This patch optimizes instance variable lookup in the case the $VERBOSE
is not true when compiling. If $VERBOSE is not true when compiling
code, it makes the instance variable access use an optimized VM
instruction that does not check $VERBOSE at runtime.
This does not change the behavior if $VERBOSE is not changed at runtime,
only when $VERBOSE is not true when compiling the code, but is true when
running it. In the case where $VERBOSE is not true when compiling and
true at runtime, this patch makes ruby no longer emit the warning
message.
Using a similar benchmark as #10396:
~~~
require 'benchmark/ips'
class A
def initialize
@c = @d = @e = @f = nil
end
def b
@c || @d || @e || @f
end
end
Benchmark.ips do |x|
x.report("A.new.b"){A.new.b}
x.report("A.allocate.b"){A.allocate.b}
end
~~~
Before Patch:
~~~
A.new.b 347.380k (_ 1.7%) i/s - 1.741M
A.allocate.b 862.884k (_ 0.4%) i/s - 4.317M
A.new.b 338.830k (_ 1.7%) i/s - 1.706M
A.allocate.b 848.036k (_ 0.4%) i/s - 4.254M
A.new.b 344.167k (_ 1.7%) i/s - 1.731M
A.allocate.b 826.183k (_ 0.4%) i/s - 4.138M
~~~
After Patch:
~~~
A.new.b 350.251k (_ 1.7%) i/s - 1.753M
A.allocate.b 900.666k (_ 0.7%) i/s - 4.512M
A.new.b 349.868k (_ 1.7%) i/s - 1.760M
A.allocate.b 898.292k (_ 0.4%) i/s - 4.505M
A.new.b 349.690k (_ 1.7%) i/s - 1.751M
A.allocate.b 888.524k (_ 0.6%) i/s - 4.444M
~~~
So about a 1-2% increase in the case where instance variables are
already initialized, and about 5-7% increase in the case where
instance variables are not initialized.
---Files--------------------------------
0001-Optimize-instance-variable-access-if-VERBOSE-is-not-.patch (4.88 KB)
--
https://bugs.ruby-lang.org/
Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>