Skip to content

Conversation

@pull
Copy link

@pull pull bot commented Sep 4, 2025

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.3)

Can you help keep this open source service alive? 💖 Please sponsor : )

junaruga and others added 4 commits September 4, 2025 15:55
This commit fixes the failures in bootstraptest/test_ractor.rb reported on
the issue ticket <https://bugs.ruby-lang.org/issues/21534>.

TLS (Thread-Local Storage) may not be accessed across .so on ppc64le too.
I am not sure about that.  The comment "// TLS can not be accessed across
.so on ..." in this commit comes from the following commit.

319afed#diff-408391c43b2372cfe1fefb3e1c2531df0184ed711f46d229b08964ec9e8fa8c7R118
> // on Darwin, TLS can not be accessed across .so`

This failures only happened when configuring with cppflags=-DRUBY_DEBUG and -O3
on ppc64le.

The reproducing steps were below.

```
$ ./autogen.sh

$ ./configure -C --disable-install-doc cppflags=-DRUBY_DEBUG

$ make -j4

$ make btest BTESTS=bootstraptest/test_ractor.rb
...
FAIL 2/147 tests failed
make: *** [uncommon.mk:913: yes-btest] Error 1
```

The steps with a reproducing script based on the `bootstraptest/test_ractor.rb`
were below.

```
$ cat test_ractor_1.rb
counts = []
counts << Ractor.count
p counts.inspect

ractors = (1..2).map { Ractor.new { Ractor.receive } }
counts << Ractor.count
p counts.inspect

ractors[0].send('End 0').join
sleep 0.1 until ractors[0].inspect =~ /terminated/
counts << Ractor.count
p counts.inspect

ractors[1].send('End 1').join
sleep 0.1 until ractors[1].inspect =~ /terminated/
counts << Ractor.count
p counts.inspect

$ make run TESTRUN_SCRIPT=test_ractor_1.rb
...
vm_core.h:2017: Assertion Failed: rb_current_execution_context:ec == rb_current_ec_noinline()
...
```

The assertion failure happened at the following line.

https://github.com/ruby/ruby/blob/f3206cc79bec2fd852e81ec56de59f0a67ab32b7/vm_core.h#L2017

This fix is similar with the following commit for the arm64.

f7059af

Fixes [Bug #21534]
* ZJIT: Support compiling ISEQs for opt_pc = 0

* Test send with optional arguments
ZJIT: Add patchpoint for TracePoint activation

Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com>
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
This fixes:

```
warning: unused import: `ParseError`
  --> zjit/src/codegen.rs:20:61
   |
20 | use crate::hir::{Const, FrameState, Function, Insn, InsnId, ParseError};
   |                                                             ^^^^^^^^^^
   |
   = note: `#[warn(unused_imports)]` on by default
```
@pull pull bot locked and limited conversation to collaborators Sep 4, 2025
@pull pull bot added the ⤵️ pull label Sep 4, 2025
@pull pull bot merged commit 7300b3d into turkdevops:master Sep 4, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants