[#122258] [Ruby Misc#21367] Remove link to ruby-doc.org from www.ruby-lang.org/en/documentation/ — "p8 (Petrik de Heus) via ruby-core" <ruby-core@...>
Issue #21367 has been reported by p8 (Petrik de Heus).
11 messages
2025/05/23
[ruby-core:122058] [Ruby Bug#19338] Ruby hangs when ouputting warnings inside ractor with VM lock held
From:
"byroot (Jean Boussier) via ruby-core" <ruby-core@...>
Date:
2025-05-13 14:34:38 UTC
List:
ruby-core #122058
Issue #19338 has been updated by byroot (Jean Boussier).
Status changed from Assigned to Closed
I was able to reproduce this on 3.3, but not on 3.4 not master. So I'll assume it was fixed and close.
----------------------------------------
Bug #19338: Ruby hangs when ouputting warnings inside ractor with VM lock held
https://bugs.ruby-lang.org/issues/19338#change-113206
* Author: luke-gru (Luke Gruber)
* Status: Closed
* Assignee: ractor
* Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: UNKNOWN
----------------------------------------
This code causes Ruby to hang:
``` ruby
rs = []
2.times do
rs << Ractor.new do
MYCONSTANT = 2
end
end
rs.each(&:take)
```
There is a problem when the warning is being outputted with multiple ractors. A thread is calling RB_VM_LOCK() while holding the VM lock in ractor.c (ractor_check_blocking())
If the code is changed to RB_VM_LOCK_ENTER() and RB_VM_LOCK_LEAVE() then it fixes it, but I don't know if there's a better way.
Thanks!
--
https://bugs.ruby-lang.org/
______________________________________________
ruby-core mailing list -- ruby-core@ml.ruby-lang.org
To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/