diff options
| author | Alan Wu <XrXr@users.noreply.github.com> | 2023-01-03 15:07:33 -0500 |
|---|---|---|
| committer | Alan Wu <XrXr@users.noreply.github.com> | 2023-01-03 16:17:50 -0500 |
| commit | 43ff0c2c488c80aaf83b486d45bcd4a92ebe3848 (patch) | |
| tree | f77dd76589487539f9d1c3857f017a124357e6ea /test | |
| parent | 1f9b6bfa9362cc13a57b67f7875bba303cd35a1f (diff) | |
YJIT: Fix `yield` into block with >=30 locals on ARM
It's a register spill issue. Fix by moving the Qnil fill snippet to
after registers are released.
[Bug #19299]
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/7059
Diffstat (limited to 'test')
| -rw-r--r-- | test/ruby/test_yjit.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/ruby/test_yjit.rb b/test/ruby/test_yjit.rb index 0ad443c885..1a552a1074 100644 --- a/test/ruby/test_yjit.rb +++ b/test/ruby/test_yjit.rb @@ -1028,6 +1028,20 @@ class TestYJIT < Test::Unit::TestCase RUBY end + def test_invokeblock_many_locals + # [Bug #19299] + assert_compiles(<<~'RUBY', result: :ok) + def foo + yield + end + + foo do + a1=a2=a3=a4=a5=a6=a7=a8=a9=a10=a11=a12=a13=a14=a15=a16=a17=a18=a19=a20=a21=a22=a23=a24=a25=a26=a27=a28=a29=a30 = :ok + a30 + end + RUBY + end + private def code_gc_helpers |
