-
Notifications
You must be signed in to change notification settings - Fork 14
Fixes to encoding/transcoding for ractors. #702
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
Open
luke-gruber
wants to merge
113
commits into
master
Choose a base branch
from
encoding_autoload_fixes
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
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
515bdfb
to
333c6e0
Compare
At under a minute, this check runs faster than a lot of the other CI checks, so we might as well show errors from `cargo check` to serve as a smoke check in addition to surfacing warnings.
333c6e0
to
1f58aa7
Compare
On systems where the Encoding.default_internal defaults to US-ASCII instead of UTF-8, some tests using assert_raise_with_message can fail since it no longer changes Encoding.default_internal in 79f5202. This tests explicitly uses EnvUtil.with_default_internal on systems where these tests fail.
The VPATH rule of NMake is different from others. Abandon using them in the rules for the generated source, locate them in the top source directory, as well as the generated library files of prism.
The current oldest support Ruby version is 3.2. And Ruby 3.2 bundled Bundler 2.5. It means RG 4.0 can drop to support Bundler 2.2. rubygems/rubygems@592ac09b5c
Since the lowest supported version is now 3.4.1. rubygems/rubygems@d00e03c52e
…ation warning Like others, it's a remembered option which we are deprecating in favor of configuration. rubygems/rubygems@9ea55e0df2
…sed in verbose mode This reverts commit rubygems/rubygems@bea87eab0b17 and adds a regression spec for it. rubygems/rubygems@ac98107864
The `bundle list` command is a convenient way for human to know what gems and versions are available. By introducing a `--format=json` option, we can provide the same information to machines in a stable format that is robust to UI additions or modifications. It indirectly supports `Gemfile.lock` modifications by discouraging external tools from attempting to parse that format. This addition allows for the scripting of installation tools, such as buildpacks, that wish to branch logic based on gem versions. For example: ```ruby require "json" command = "bundle list --format=json" output = `#{command}` raise "Command `#{command}` errored: #{output}" unless $?.success? railties = JSON.parse(output).find {|gem| gem["name"] == railties } if railties && Gem::Version.new(railties["version"]) >= Gem::Version.new("7") puts "Using Rails greater than 7!" end ``` The top level is an object with a single key, "gems", this structure allows us to add other information in the future (should we desire) without having to change the json schema. rubygems/rubygems@9e081b0689
Bumps [github.com/microsoft/vcpkg](https://github.com/microsoft/vcpkg) from master to dd3097e305afa53f7b4312371f62058d2e665320. - [Release notes](https://github.com/microsoft/vcpkg/releases) - [Commits](microsoft/vcpkg@65be701...dd3097e) --- updated-dependencies: - dependency-name: github.com/microsoft/vcpkg dependency-version: dd3097e305afa53f7b4312371f62058d2e665320 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <[email protected]>
This commit adds two new methods to the `Math` module: * `Math.log1p(x)`: Computes `Math.log(x + 1)` * `Math.expm1(x)`: Computes `Math.exp(x) - 1` These methods are often more accurate than the straightforward computation, especially when `x` is close to zero. The corresponding functions, `log1p` and `expm1`, are defined in the C99 standard math library. [Feature #21527]
`RUBY_CXX_DEPRECATED` is overridden using `RBIMPL_ATTR_DEPRECATED` in include/ruby/backward/2/attributes.h already.
[Bug #21547] Followup: ruby#14201 When adding an instance variable and the IMEMO/fields need to be larger, we allocate a new one and clear the old one. Since the old one may still be in other ec's cache, on a hit we must check the IMEMO/fields isn't a stale one.
We can use the `gen_push_opnds` and `gen_pop_opnds` helpers added in ruby#14200 to simplify the code.
Its usage was removed in 306d508.
Previously, ruby2_keywords could be used on a method or proc with post arguments, but I don't think the behavior is desired: ```ruby def a(*c, **kw) [c, kw] end def b(*a, b) a(*a, b) end ruby2_keywords(:b) b({foo: 1}, bar: 1) ``` This changes ruby2_keywords to emit a warning and not set the flag on a method/proc with post arguments. While here, fix the ruby2_keywords specs for warnings, since they weren't testing what they should be testing. They all warned because the method didn't accept a rest argument, not because it accepted a keyword or keyword rest argument.
[Bug #20146] Previously we dealt with the main Ractor not being enabled for M:N by incrementing snt_cnt++. This worked for comparing against ractor count, but meant that we always had one less SNT than was specified by RUBY_MAX_CPU. This was notably a problem for RUBY_MAX_CPU=1, which would cause Ractors to hang. This commit instead of adjusting snt, adjusts a "schedulable_ractor_cnt". This way snt_cnt will actually reach RUBY_MAX_CPU.
4f20ac5
to
50b8e7a
Compare
ruby#14270) If the LiveRange looks like (idx, idx), we will currently not allocate a register. This change allocates a register and then immediately deallocates it. Fix #614
Co-authored-by: Alan Wu <[email protected]> Co-authored-by: Max Bernstein <[email protected]> Co-authored-by: Aaron Patterson <[email protected]>
Thanks to nobu for pointing this out. This is a YJIT file so shouldn't have ZJIT stuff in it. ZJIT doesn't support building on BSDs yet. Fix: 92b218f
Make vm_search_method return a cme instead of a cc Both of its callers ended up calling `vm_cc_cme` on the result and only used the cme, so it's probably better to return a cme directly. This will also make it easier for ZJIT to later inline the `rb_vm_objtostring` call.
c5f554d
to
82cf3af
Compare
82cf3af
to
4f0f3a8
Compare
[Bug #21548] In lazy sweeping, if we need to allocate an object in a heap where we weren't able to free any slots, but we also either have empty pages or could allocate new pages, then we want to preemptively claim a page because it's possible that sweeping another heap will call gc_sweep_finish_heap, which may use up all of the empty/allocatable pages. If other heaps are not finished sweeping then we do not finish this GC and we will end up triggering a new GC cycle during this GC phase.
Not all ractor-related encoding issues were fixed by 1afc07e. I found more by running my test-all branch with 3 ractors for each test.
4f0f3a8
to
f378052
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Not all ractor-related encoding issues were fixed by 1afc07e. I found more by running my test-all branch with 3 ractors for each test.