heap_dump icon indicating copy to clipboard operation
heap_dump copied to clipboard

Too much to ask? Segfault in experimental Ruby Build

Open mrb opened this issue 11 years ago • 7 comments

We're actually running https://github.com/thecodeshop/ruby/tree/tcs-ruby_1_9_3 in production at my day job. Until now I haven't tried to run anything, but I'm getting a segfault around this code: https://github.com/Vasfed/heap_dump/blob/master/ext/heap_dump/heap_dump.c#L1250-L1255 in our Rails app. Any ideas?

mrb avatar Nov 27 '12 21:11 mrb

Sure strongly-patched rubies are not compatible, internal gc structures must match. Actually for already-supported ruby version adding compatibility should be quite simple - see https://github.com/Vasfed/heap_dump/tree/master/ext/heap_dump/specific/ruby-1.9.3 The only weak point is detecting patch set to select proper adapter in extconf

Vasfed avatar Nov 27 '12 21:11 Vasfed

Do not have time atm, but i'm pretty sure that is because of some field added to objspace_t or similar. Will look into this in a couple of days if you do not manage to solve this before that.

Vasfed avatar Nov 27 '12 22:11 Vasfed

@Vasfed Thank you!

mrb avatar Nov 27 '12 23:11 mrb

Yep, patch does alter objspace structures a bit. Now i'm considering an automated generator for such cases, this may take some time. In manual mode support probably can be added pretty easily

Vasfed avatar Dec 16 '12 13:12 Vasfed

@Vasfed Thanks! A generator would be awesome. FWIW this implementation is picking up a bit of steam, so if you have some time to patch it, that would be cool.

mrb avatar Dec 16 '12 18:12 mrb

This gem causes segfault for me with even simple programs. Ruby version:

ruby 1.9.3p362 (2012-12-25 revision 38607) [x86_64-linux]

ppawel avatar Jan 12 '13 17:01 ppawel

@ppawel p362 has no support yet - unfortunately segfault occurs each time something is changed in internal ruby structures (i'm a little busy atm, generator should solve most problems of this kind), try an older revision of ruby

Vasfed avatar Jan 12 '13 18:01 Vasfed