Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

Latest revisions

# Date Author Comment
a440f23c 05/04/2026 03:41 PM byroot (Jean Boussier)

Always inline revalidate_setivar_cache

880901af 05/04/2026 03:41 PM byroot (Jean Boussier)

vm_insnhelper.c: Unify populate_cache and fill_ivar_cache

They're the same code.

a2ba1ed4 05/04/2026 03:41 PM byroot (Jean Boussier)

vm_insnhelper.c: refactor and optimize setivar cache revalidation

By only storing shape offsets in the cache, we're able to still
match two equal objects that happen to be in different heaps, as
well as to validate the object is neither frozen nor complex.

8d40d481 05/04/2026 03:41 PM byroot (Jean Boussier)

vm_insnhelper.c: share the cache revalidation logic

It's the same code duplicated in 3 places.

1aa62e89 05/04/2026 03:22 PM Earlopain (Earlopain _)

[ruby/prism] Optimize ripper visit_token

It was showing up in profiles.

So:

  • Don't splat KEYWORDS (also did the same for BINARY_OPERATORS)
  • Use start_with? if possible

Overall gives a ~5% speed boost

https://github.com/ruby/prism/commit/d611aa9d11

1367f885 05/04/2026 03:22 PM Earlopain (Earlopain _)

[ruby/prism] Freeze the parse result for the ripper translator

It's a small, somewhat hacky performance boost. Locations are lazy, by freezing the
result they don't have to be pack/unpacked redundantly.
This gives about a 4% speed boost.

Other changes are to not modify the frozen AST...

0cbd210c 05/04/2026 03:22 PM Earlopain (Earlopain _)

[ruby/prism] Optimize ripper bounds

Basically a port of https://github.com/ruby/ruby/commit/c45f781771314a71856c9b348c640ba532f54349 into ruby

It's quite effective at ~97% hit rate for me.
Speeds it up from ~6.77x slower to only 4.07x slower.

For the lexer on_sp it also gives a bit of an improvement:...

b583dd68 05/04/2026 03:15 PM Eregon (Benoit Daloze)

Fix typo and improve docs of Exception#exception

f6d1bc6b 05/04/2026 03:03 PM byroot (Jean Boussier)

[DOC] Add feature 21796 in NEWS.md

8bf6d7bf 05/04/2026 12:01 PM byroot (Jean Boussier)

Fix coverage support for RubyVM::ISeq.compile

[Bug #22018]

ISeq returned by RubyVM::InstructionSequene.load_iseq weren't
handled by the coverage module.

View all revisions | View revisions

Also available in: Atom