Bug #16110
closedDoesn't detect deadlock on Ruby 2.4 and 2.5 on Windows
Description
The following code is detected as a deadlock, except in Ruby 2.4 and 2.5 on Windows:
ruby -r thread -ve 'Thread.new { Queue.new.shift }.join'
You can see it run in this code: https://github.com/JoshCheek/childprocess_experiment/blob/368052de8e433933035395216e8c48b8302b6fdf/Rakefile#L3
And it gets stuck in AppVeyor's CI because it doesn't realize it's deadlocked: https://ci.appveyor.com/project/JoshCheek/childprocess-experiment/build/job/3j06xan4ygm63ppd
Updated by MSP-Greg (Greg L) over 5 years ago
Is this specific to 32 bit builds of 2.4 & 2.5? I think 64 bit builds all function as expected...
Updated by jeremyevans0 (Jeremy Evans) almost 5 years ago
- Status changed from Open to Closed
I tested 32-bit Windows builds of Ruby 2.6 and 1.9.3 and the deadlock is detected (those are the only 32-bit versions I have installed in my Windows environment). I tested on 64-bit builds of Ruby 2.0-2.7, and deadlock is detected in all cases. Maybe this problem is limited to 32-bit Windows builds of Ruby 2.4 and 2.5. However, as Ruby 2.4 is out of support and Ruby 2.5 has already moved into the security maintenance phase, this can be closed. Please update to Ruby 2.6 or 2.7.