path: root/ext
AgeCommit message (Collapse)Author
2022-12-18[ruby/date] Extract `head_match_p` and abbreviated name length constantsNobuyoshi Nakada
2022-12-18[ruby/date] Consider the length of string to parseNobuyoshi Nakada
2022-12-18[ruby/date] Remove `extz_pats` tableNobuyoshi Nakada
2022-12-18[ruby/date] Remove `merid_names` tableNobuyoshi Nakada
2022-12-18[ruby/date] Match abbreviated day and month names with head of full namesNobuyoshi Nakada
2022-12-16[ruby/date] Bump version to 3.3.2Hiroshi SHIBATA
2022-12-16[ruby/io-console] Bump version to 0.6.0Hiroshi SHIBATA
2022-12-16[ruby/io-wait] Bump version to 0.3.0Hiroshi SHIBATA
2022-12-15Indicate if a shape is too_complex in ObjectSpace#dumpJemma Issroff
Notes: Merged:
2022-12-15Transition complex objects to "too complex" shapeJemma Issroff
When an object becomes "too complex" (in other words it has too many variations in the shape tree), we transition it to use a "too complex" shape and use a hash for storing instance variables. Without this patch, there were rare cases where shape tree growth could "explode" and cause performance degradation on what would otherwise have been cached fast paths. This patch puts a limit on shape tree growth, and gracefully degrades in the rare case where there could be a factorial growth in the shape tree. For example: ```ruby class NG; end HUGE_NUMBER.times do"@unique_ivar_#{_1}", 1) end ``` We consider objects to be "too complex" when the object's class has more than SHAPE_MAX_VARIATIONS (currently 8) leaf nodes in the shape tree and the object introduces a new variation (a new leaf node) associated with that class. For example, new variations on instances of the following class would be considered "too complex" because those instances create more than 8 leaves in the shape tree: ```ruby class Foo; end 9.times {":@uniq_#{_1}", 1) } ``` However, the following class is *not* too complex because it only has one leaf in the shape tree: ```ruby class Foo def initialize @a = @b = @c = @d = @e = @f = @g = @h = @i = nil end end 9.times { } `` This case is rare, so we don't expect this change to impact performance of most applications, but it needs to be handled. Co-Authored-By: Aaron Patterson <> Notes: Merged:
2022-12-15Add variation_count on classesJemma Issroff
Count how many "variations" each class creates. A "variation" is a a unique ordering of instance variables on a particular class. This can also be thought of as a branch in the shape tree. For example, the following Foo class will have 2 variations: ```ruby class Foo ; end, 1) # case 1: creates one variation, 1) # case 2: creates another variation foo = foo.instance_variable_set(:@a, 1) # does not create a new variation foo.instance_variable_set(:@b, 1) # does not create a new variation (a continuation of the variation in case 1) ``` We will use this number to limit the amount of shapes that a class can create and fallback to using a hash iv lookup. Co-Authored-By: Aaron Patterson <> Notes: Merged:
2022-12-15Remove `require 'io/wait'` where it's no longer necessary. (#6932)Samuel Williams
* Remove `require 'io/wait'` as it's part of core now. * Update ruby specs using version gates. * Add note about why it's conditional. Notes: Merged-By: ioquatix <>
2022-12-15socket.rb - simplify check for the methodNobuyoshi Nakada
2022-12-14objspace_dump.c: don't dump class of T_IMEMOJean Boussier
They don't actually have a class. Notes: Merged:
2022-12-14[ruby/date] Fixed wrong minimum version of RubyHiroshi SHIBATA
2022-12-14[ruby/syslog] Bump version to 0.1.1Hiroshi SHIBATA
2022-12-14[ruby/readline-ext] Bump version to 0.1.5Hiroshi SHIBATA
2022-12-14socket.rb - don't load io/wait (#6922)MSP-Greg
See d2166c09b08fc1 and #6036 for more context. Notes: Merged-By: ioquatix <>
2022-12-13[ruby/date] Implement Date#deconstruct_keys and DateTime#deconstruct_keyszverok
2022-12-13[ruby/openssl] [DOC] Remove duplicate docNobuyoshi Nakada
RDoc does not consider preprocessor conditionals, but equally uses both documents of `#if` and `#else` sides.
2022-12-13We should apply instead of them:Hiroshi SHIBATA
2022-12-13[ruby/openssl] Fixes OPENSSL_LIBRARY_VERSION description onHenrique Bontempo
documentation ( Adds back missing constant description on the documentation.
2022-12-13[ruby/openssl] Enable HKDF support for LibreSSL 3.6 and laterTheo Buehler
LibreSSL 3.6 added support for HKDF in EVP. Enable this in ossl_kdf.c.
2022-12-13[ruby/openssl] Allow empty string to OpenSSL::Cipher#updateYusuke Nakamura
For some reasons, plaintext may be empty string. ref
2022-12-13[ruby/openssl] Use EVP_Digest{Sign,Verify} when availableTheo Buehler
LibreSSL 3.4 added EVP_DigestSign() and EVP_DigestVerify(). Use them when available to prepare for the addition of Ed25519 support in LibreSSL 3.7.
2022-12-12[DOC] Fix format in ObjectSpace.dump_allPeter Zhu
2022-12-12[DOC] Fix format for ObjectSpace.dump_shapesPeter Zhu
2022-12-12[DOC] Fix call-seq for ObjectSpace methodsPeter Zhu
2022-12-12[DOC] Fix typo in docs for ObjectSpace.dump_allPeter Zhu
2022-12-12[DOC] Fix indentation for ObjectSpace.dump_allPeter Zhu
2022-12-12[DOC] Don't document private methods in objspacePeter Zhu
2022-12-09objspace_dump.c: dump the capacity field for INITIAL_CAPACITY shapesJean Boussier
We forgot about that one, it's quite useful to see which capacity we started from. Notes: Merged:
2022-12-09[ruby/date] Bump version to 3.3.1Hiroshi SHIBATA
2022-12-09[ruby/date] No-op gem for JRuby for nowCharles Oliver Nutter
Remove all shipped files and require path on JRuby until we can add JRuby's extension to the gem. Temporary workaround for #48
2022-12-09Merge json-2.6.3Hiroshi SHIBATA
Notes: Merged:
2022-12-09Merge stringio-3.0.4Hiroshi SHIBATA
Notes: Merged:
2022-12-09Merge fiddle-1.1.1Hiroshi SHIBATA
Notes: Merged:
2022-12-09Merge strscan-3.0.5Hiroshi SHIBATA
Notes: Merged:
2022-12-09[ruby/etc] Bump version to 1.4.2Hiroshi SHIBATA
2022-12-08[ruby/stringio] bump up to 3.0.5Sutou Kouhei
2022-12-08ObjectSpace.dump_all: dump shapes as wellJean Boussier
I see several arguments in doing so. First they use a non trivial amount of memory, so for various memory profiling/mapping tools it is relevant to have visibility of the space occupied by shapes. Then, some pathological code can create a tons of shape, so it is valuable to have a way to have a way to observe shapes without having to compile Ruby with `SHAPE_DEBUG=1`. And additionally it's likely much faster to dump then this way than to use `RubyVM::Shape`. There are however a few open questions: - Shapes can't respect the `since:` argument. Not sure what to do when it is provided. Would probably make sense to not dump them. - Maybe it would make more sense to have a separate `ObjectSpace.dump_shapes`? - Maybe instead `dump_all` should take a `shapes: false` argument? Additionally, `ObjectSpace.dump_shapes` is added for the use case of debugging the evolution of the shape tree. Notes: Merged:
2022-12-08[ruby/stringio] bump up to 3.0.4Sutou Kouhei
2022-12-08[ruby/psych] Bump version to 5.0.1Hiroshi SHIBATA
2022-12-06Update dependenciesDaniel Colson
2022-12-05Add shape_id to heap dumpJemma Issroff
Notes: Merged:
2022-12-05[ruby/bigdecimal] Bump version to 3.1.3Hiroshi SHIBATA
2022-12-05[ruby/zlib] Bump version to 3.0.0Hiroshi SHIBATA
2022-12-05[ruby/win32ole] Bump version to 1.8.9Hiroshi SHIBATA
2022-12-05[ruby/stringio] Revert "Bump version to 3.0.4"Hiroshi SHIBATA
This reverts commit
2022-12-05[ruby/stringio] Bump version to 3.0.4Hiroshi SHIBATA