[pull] master from ruby:master#1198
Merged
Merged
Conversation
Speeds up object allocation by 70% ``` master: ruby 4.1.0dev (2026-07-09T11:46:27Z master 835ad5c) +ZJIT +PRISM [x86_64-linux] experiment: ruby 4.1.0dev (2026-07-09T17:43:21Z mvh-zjit-inline-fa.. 60534f3) +ZJIT +PRISM [x86_64-linux] --------------------- ----------- --------------- ------------------ ----------------- bench master (ms) experiment (ms) experiment 1st itr master/experiment object-new 17.9 ± 1.6% 10.3 ± 2.7% 1.002 1.729 object-new-initialize 51.4 ± 1.4% 44.9 ± 1.7% 1.095 1.144 object-new-no-escape 91.0 ± 0.4% 77.0 ± 0.5% 1.150 1.182 --------------------- ----------- --------------- ------------------ ----------------- Legend: - experiment 1st itr: ratio of master/experiment time for the first benchmarking iteration. - master/experiment: ratio of master/experiment time. Higher is better for experiment. Above 1 represents a speedup. ```
Do the load from the EP in HIR instead. This allows it to be optimized in the future when we de-duplicate GetEP.
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
This empty function is no longer needed now that _id2ref is gone.
When ZJIT can prove that we'll always receive symbols as keys for NewHash, we can spill less because `rb_hash_bulk_insert` is now leaf (cmp and hash are leaf). ``` HashNew with symbol keys (unit: millions of IPS) ┌───────────────────┬────────┬───────┬───────┬──────────────────────┐ │ op │ before │ after │ raw Δ │ control-normalized Δ │ ├───────────────────┼────────┼───────┼───────┼──────────────────────┤ │ hash 2 (ar_table) │ 27.95 │ 29.96 │ +7.2% │ +10.3% │ ├───────────────────┼────────┼───────┼───────┼──────────────────────┤ │ hash 6 (ar_table) │ 15.64 │ 16.84 │ +7.7% │ +10.9% │ ├───────────────────┼────────┼───────┼───────┼──────────────────────┤ │ hash 9 (st_table) │ 7.15 │ 7.25 │ +1.5% │ +4.5% │ ├───────────────────┼────────┼───────┼───────┼──────────────────────┤ │ array 4 (control) │ 33.90 │ 32.93 │ −2.9% │ — (reference) │ └───────────────────┴────────┴───────┴───────┴──────────────────────┘ ```
`del` exits successfully even when it removes nothing, so a directory containing no plain files was never passed to `rd /s`, and a directory containing files kept its subdirectories. Remove directories before falling back to `del`.
The check used the path relative to the expanded wildcard parent instead of the full path, so removal through a wildcard in the middle of a path was silently skipped.
Dir.glob documentation had noted since [Bug #2625] that a backslash cannot be used as a path separator in patterns on Windows, but the note was dropped when the documentation was consolidated into doc/file/filename_globbing.md (GH-17265). Restore it, and also note that File::FNM_NOESCAPE does not turn the backslash into a separator.
Dir.glob's block form, Dir[]'s multiple pattern arguments, matching only directories by a trailing slash, and the note that '**' without a following slash is equivalent to '*' were dropped when the glob documentation was consolidated into doc/file/filename_globbing.md (GH-17265). Restore them, with examples verified against the current source tree.
bugs.ruby-lang.org now rejects anonymous JSON API requests with 403 Forbidden. The backporter already requires a Redmine API key and uses it for write requests, but the read-only issue and journal lookups were still sent without credentials. Send the existing X-Redmine-API-Key header for those GET requests too, so ls/show/done/last can keep using the JSON API.
Previously:
```
warning: value assigned to `value_array` is never read
--> yjit/src/codegen.rs:11446:9
|
11446 | value_array[1] = 4;
| ^^^^^^^^^^^^^^^^^^
|
= help: maybe it is overwritten before being read?
= note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default
```
It can't see the alias through `jit.pc`!
Like nmake, BSD make can't parse the GNU `--jobserver-auth` flag in
MAKEFLAGS and aborts native extension builds with:
make: argument 'observer-auth=6,7' to option '-j' must be a positive number
Skip the jobserver on BSD platforms, unless an gmake is explicitly
being used.
ruby/rubygems@d682fd3370
Two issues caused groff/lintian warnings on the mdoc pages: 1. man/ruby.1: the MISC ENVIRONMENT list for RUBY_TCP_NO_FAST_FALLBACK opened a .Bl that was never closed before .Sh SEE ALSO, producing "A .Bl directive has no matching .El". 2. man/erb.1 and man/ruby.1: .Bl -tag -width "1234567890123" uses a long all-digit width string. Under groff 1.24 that is mishandled and floods "cannot adjust line; overset by ~5e7n" warnings, and mangled OPTIONS rendering. Replace it with -width "--encoding" (a representative tag). Verified with man --warnings: 0 warnings on erb.1/ruby.1/goruby.1 after this change (was 249 / 1399 / 0 on master).
Bumps the github-actions group with 5 updates in the / directory: | Package | From | To | | --- | --- | --- | | [github/codeql-action/init](https://github.com/github/codeql-action) | `4.36.3` | `4.37.0` | | [github/codeql-action/analyze](https://github.com/github/codeql-action) | `4.36.3` | `4.37.0` | | [github/codeql-action/upload-sarif](https://github.com/github/codeql-action) | `4.36.3` | `4.37.0` | | [actions/labeler](https://github.com/actions/labeler) | `6.1.0` | `6.2.0` | | [taiki-e/install-action](https://github.com/taiki-e/install-action) | `2.82.10` | `2.83.0` | Updates `github/codeql-action/init` from 4.36.3 to 4.37.0 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@54f647b...99df26d) Updates `github/codeql-action/analyze` from 4.36.3 to 4.37.0 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@54f647b...99df26d) Updates `github/codeql-action/upload-sarif` from 4.36.3 to 4.37.0 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@54f647b...99df26d) Updates `actions/labeler` from 6.1.0 to 6.2.0 - [Release notes](https://github.com/actions/labeler/releases) - [Commits](actions/labeler@f27b608...b8dd2d9) Updates `taiki-e/install-action` from 2.82.10 to 2.83.0 - [Release notes](https://github.com/taiki-e/install-action/releases) - [Changelog](https://github.com/taiki-e/install-action/blob/main/CHANGELOG.md) - [Commits](taiki-e/install-action@5041467...c7eb173) --- updated-dependencies: - dependency-name: github/codeql-action/init dependency-version: 4.37.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: github/codeql-action/analyze dependency-version: 4.37.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: github/codeql-action/upload-sarif dependency-version: 4.37.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: actions/labeler dependency-version: 6.2.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: taiki-e/install-action dependency-version: 2.83.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions ... Signed-off-by: dependabot[bot] <support@github.com>
Closes ruby/net-http#202 As of June 2026, [RFC 10008][] is a proposed standard. From the RFC Abstract: > This specification defines the QUERY method for HTTP. A QUERY requests > that the request target process the enclosed content in a safe and > idempotent manner and then respond with the result of that processing. > This is similar to POST requests, but QUERY requests can be > automatically repeated or restarted without concern for partial state > changes. This commit proposes support for the HTTP Query method by way of the `Net::HTTP::Query` class along with the corresponding `#query` and `#request_query` methods. [RFC 10008]: https://www.rfc-editor.org/rfc/rfc10008.html ruby/net-http@76b11b3a26
[Feature #22136] This is as far as I can tell the only method that changes its behavior in debug mode, and that's all but helpful because it might cause the program to abort. Usually when you run a program with $DEBUG set, it is to find some error that may have been swallowed, so aside from the extra output you would expect Ruby to behave the same than in normal mode.
rb_objspace_reachable_objects_from and rb_objspace_reachable_objects_from_root install a redirect so that marking a child hands it to a callback instead of the real mark routine. It lived in vm->gc.mark_func_data, a single slot shared by the whole VM. Move it to rb_ractor_t: an installed redirect belongs to the Ractor doing the traversal, and no other Ractor should observe it. A modular GC (e.g. MMTk) may mark on worker threads that have no current EC, where the Ractor is not reachable, so on a modular build it keeps living in the VM. A non-modular build pays nothing extra over the previous GET_VM() lookup. Behaviour is unchanged with a single Ractor. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Objects registered with rb_gc_register_mark_object were pinned in a single vm->mark_object_ary. Give each Ractor its own (rb_ractor_t.mark_object_ary, created lazily) and mark it from ractor_mark; the main Ractor's list is also marked from rb_vm_mark so early-boot registrations are safe before the main Ractor joins vm->ractor.set (e.g. under RUBY_DEBUG=gc_stress). When a Ractor terminates, hand its objects to the main Ractor so these process-lifetime pins stay alive. global_object_list (rb_gc_register_address) stays VM-global: a registered address is a slot whose value changes over time, so it has no single owner and every root scan must keep seeing it. Behaviour is unchanged with a single Ractor. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
[[Bug #22133]]
[Feature #22085] This warning is only actionable for float literals in source code. When parsing user input into a float, most of the time this warning isn't actionable and is pure noise.
Embedded arrays only use 7 bits for the length, so it will overflow if the GC can allocate large slots. We need to add the cap to ary_embeddable_p.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )