I’m hoping someone who knows MRI internals very well can answer this
I was trying to debug a problem with MRI today using Valgrind, and
noticed when Ruby is run on top of Valgrind, virtually any Ruby program
(even those which work correctly) will display a slew of memory errors.
The errors are mostly “Use of uninitialised value of size 8” and
“Conditional jump or move depends on uninitialised value(s)” (though I
have seen others). The errors come from the code for Ruby’s GC.
Is this normal? Does Ruby’s GC do some fancy things with pointers which
trick Valgrind into thinking it is “using uninitialized values”? Or are
these real bugs?