[#76442] [Ruby trunk Feature#11741] Migrate Ruby to Git from Subversion — naruse@...
Issue #11741 has been updated by Yui NARUSE.
3 messages
2016/07/19
[#76515] [Ruby trunk Bug#12610] webrick: protect from httpoxy — nagachika00@...
Issue #12610 has been updated by Tomoyuki Chikanaga.
3 messages
2016/07/22
[ruby-core:76626] [Ruby trunk Feature#12639] Speed up require in RubyGems by 5x
From:
nobu@...
Date:
2016-07-31 06:30:23 UTC
List:
ruby-core #76626
Issue #12639 has been updated by Nobuyoshi Nakada.
I'm not sure if it is acceptable for rubygems to skip loaded features.
> ```diff
> +VALUE
> +rb_f_loaded_feature(VALUE obj, VALUE fname)
> +{
> + return rb_provided(RSTRING_PTR(rb_str_encode_ospath(fname))) ? Qtrue : Qfalse;
> +}
Why is this function global?
And the argument of `RSTRING_PTR` should not have side effects.
----------------------------------------
Feature #12639: Speed up require in RubyGems by 5x
https://bugs.ruby-lang.org/issues/12639#change-59845
* Author: Samuel Giddins
* Status: Open
* Priority: Normal
* Assignee:
----------------------------------------
This patch makes requiring an already-loaded file approximated 5x faster when the RubyGems mixin for require is present.
Benchmarked via the following script:
~~~ ruby
require "rubygems"
require "benchmark/ips"
Benchmark.ips do |x|
x.report("ruby") { gem_original_require "rubygems" }
x.report("rubygems") { require "rubygems" }
x.compare!
end
~~~
I understand that it's not ideal to add new global functions, and I'd appreciate guidance on where else I could expose this functionality to ruby code.
Thanks :)
---Files--------------------------------
feature_loaded.patch (1.85 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>