From: Brent Roman Date: 2009-03-05T08:01:31+09:00 Subject: [ruby-core:22668] Re: MBARI8 patch fixes bugs caused by incorrect volatile variable declarations Michael, Could you send me the output of $ uname -a $ gcc -v and the configure cmd used to build with CFLAGS, etc. ? Ruby's conservative GC reads unintialized memory. That can't be helped. When I was heavy into valgrind, I created a suppression file to help it recognize and suppress reporting these errors. http://www.faqs.org/docs/Linux-HOWTO/Valgrind-HOWTO.html Use --gen-suppressions=yes to automatically create suppression records, then tweak them by hand to make them less specific. The only valgrind reports here that concern me a bit are the invalid reads. I'd have to look into these a bit deeper to be sure. By the way, is it the ruby test suite or your app's that segfaults in drb.rb? (or both?) If only in your app, is it using any non-standard 'C' extensions? I'm assuming you've already verified that the segfaults don't also occur with unpatched Ruby. One more thing to try is to set STACK_WIPES_SITES to 0x0000. - brent Michael King-2 wrote: > > I am having an issue with the MBARI patches. In our app the test suite has > a > segfault at line 1413 in drb.rb. I am compiling Ruby on Ubuntu 6.06, > 32bit, > GCC 4.0.3. The segfault shows up when compiling at O2 and O0(zero). At the > moment I am trying to whittle down the test to give you something > reproducible. > > I the meantime, I ran valgrind and the results showed an improvement over > MRI. I have attached the results of that valgrind run, the errors were of > 4 > basic types and were in linked libraries or gc.c: > Conditional jump or move depends on uninitialised value(s) > Use of uninitialised value of size 4 > Invalid read of size > Address 0x#{address} is #{X} bytes inside a block of size #{X+2} alloc'd > > - Michael > > -- View this message in context: http://www.nabble.com/MBARI8-patch-fixes-bugs-caused-by-incorrect-volatile-variable-declarations-tp22259357p22341606.html Sent from the ruby-core mailing list archive at Nabble.com.