forked from ruby/ruby
-
Notifications
You must be signed in to change notification settings - Fork 0
[pull] master from ruby:master #567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
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
Windows has no SIGUSR1. There might be another usable signal, but this is breaking ruby master so I just want a quick fix for now. ruby/timeout@b19043e8d0
There are many indentation styles for AS_CASE in this file but no one uses `[*]` for the default case.
Reads better to me: > checking prerequisites for ZJIT... yes
```
Run options:
"--ruby=./miniruby -I../ruby/lib -I. -I.ext/common ../ruby/tool/runruby.rb --extout=.ext -- --disable-gems"
--excludes-dir=../ruby/test/.excludes
--name=!/memory_leak/
--seed=9843
[ 1/31] TestTimeout#test_timeout_in_trap_handler = 0.00 s
1) Error:
TestTimeout#test_timeout_in_trap_handler:
NoMethodError: undefined method 'kill' for nil
/Users/luke/workspace/ruby-dev/ruby/test/test_timeout.rb:9:in 'TestTimeout#kill_timeout_thread'
/Users/luke/workspace/ruby-dev/ruby/test/test_timeout.rb:424:in 'TestTimeout#test_timeout_in_trap_handler'
Finished tests in 2.715032s, 11.4179 tests/s, 52.3014 assertions/s.
31 tests, 142 assertions, 0 failures, 1 errors, 0 skips
ruby -v: ruby 4.0.0dev (2025-12-11T21:56:23Z fix_timeout_test ruby/timeout@1c5eacbf9a) +PRISM [arm64-darwin24]
make: *** [yes-test-all] Error 1
```
ruby/timeout@e5bc1de901
That call is surprisingly expensive, so trying doing it once in `#synchronize` and then passing the EC to lock and unlock saves quite a few cycles. Before: ``` ruby 4.0.0dev (2025-12-10T09:30:18Z master c5608ab) +YJIT +PRISM [arm64-darwin25] Warming up -------------------------------------- Mutex 1.888M i/100ms Monitor 1.633M i/100ms Calculating ------------------------------------- Mutex 22.610M (± 0.2%) i/s (44.23 ns/i) - 113.258M in 5.009097s Monitor 19.148M (± 0.3%) i/s (52.22 ns/i) - 96.366M in 5.032755s ``` After: ``` ruby 4.0.0dev (2025-12-10T10:40:07Z speedup-mutex 1c901cd4f8) +YJIT +PRISM [arm64-darwin25] Warming up -------------------------------------- Mutex 2.095M i/100ms Monitor 1.578M i/100ms Calculating ------------------------------------- Mutex 24.456M (± 0.4%) i/s (40.89 ns/i) - 123.584M in 5.053418s Monitor 19.176M (± 0.1%) i/s (52.15 ns/i) - 96.243M in 5.018977s ``` Bench: ``` require 'bundler/inline' gemfile do gem "benchmark-ips" end mutex = Mutex.new require "monitor" monitor = Monitor.new Benchmark.ips do |x| x.report("Mutex") { mutex.synchronize { } } x.report("Monitor") { monitor.synchronize { } } end ```
Just copied format-release fixes in a973526 to this file.
We no longer make patchlevel releases.
to make it a bit more consistent with the other branch
It just seems like a completely different input, so it makes more sense to me to have it as a separate case. Also, we don't need to support Ruby 2.0 or older.
This is a refactoring change, which should have no impact on behaviors. Now, if patchlevel is true, tag is empty. So `if patchlevel` always does nothing. Given that prerelease is false and tag is not nil, removing `if patchlevel` should have no impact.
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 : )