Bug #15784

RUBY_DEBUG=gc_stress dumps core

Added by shyouhei (Shyouhei Urabe) 4 months ago. Updated 8 days ago.

Target version:
ruby -v:
ruby 2.7.0dev (2019-04-23 trunk 87cf45a512) [x86_64-linux]


% RUBY_DEBUG=gc_stress gdb --args ./miniruby -vep
GNU gdb (Ubuntu 8.1-0ubuntu3)
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
Find the GDB manual and other documentation resources online at:
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./miniruby...done.
(gdb) run
Starting program: /home/shyouhei/data/build/ruby@clang-9/trunk@git/miniruby -vep
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/".

Program received signal SIGSEGV, Segmentation fault.
rb_vm_mark (ptr=0x555555ad8b20) at /home/shyouhei/data/src/trunk/vm.c:2231
2231            len = RARRAY_LEN(vm->mark_object_ary);
(gdb) bt
#0  rb_vm_mark (ptr=0x555555ad8b20) at /home/shyouhei/data/src/trunk/vm.c:2231
#1  0x000055555562d545 in gc_mark_roots (objspace=0x555555ad9280, categoryp=0x0) at /home/shyouhei/data/src/trunk/gc.c:5258
#2  0x0000555555633c92 in gc_marks_start (objspace=<optimized out>, full_mark=<optimized out>) at /home/shyouhei/data/src/trunk/gc.c:5880
#3  gc_marks (objspace=<optimized out>, full_mark=<optimized out>) at /home/shyouhei/data/src/trunk/gc.c:6158
#4  gc_start (objspace=<optimized out>, reason=<optimized out>) at /home/shyouhei/data/src/trunk/gc.c:6965
#5  0x000055555562da70 in garbage_collect (objspace=0x555555ad9280, reason=45568) at /home/shyouhei/data/src/trunk/gc.c:6860
#6  garbage_collect_with_gvl (objspace=0x555555ad9280, reason=45568) at /home/shyouhei/data/src/trunk/gc.c:7118
#7  objspace_malloc_gc_stress (objspace=0x555555ad9280) at /home/shyouhei/data/src/trunk/gc.c:9261
#8  objspace_xmalloc0 (objspace=0x555555ad9280, size=56) at /home/shyouhei/data/src/trunk/gc.c:9407
#9  0x0000555555734ebb in st_init_table_with_size (type=<optimized out>, size=0) at /home/shyouhei/data/src/trunk/st.c:596
#10 st_init_table (type=<optimized out>) at /home/shyouhei/data/src/trunk/st.c:626
#11 st_init_numtable () at /home/shyouhei/data/src/trunk/st.c:634
#12 0x00005555556267fd in Init_heap () at /home/shyouhei/data/src/trunk/gc.c:2584
#13 0x0000555555616e22 in ruby_setup () at /home/shyouhei/data/src/trunk/eval.c:68
#14 0x0000555555616f36 in ruby_init () at /home/shyouhei/data/src/trunk/eval.c:91
#15 0x000055555557a62b in main (argc=2, argv=0x7fffffffc998) at /home/shyouhei/data/src/trunk/main.c:41
(gdb) rp vm->mark_object_ary

Associated revisions

Revision f1a52d96
Added by nobu (Nobuyoshi Nakada) 4 months ago

Defer setting gc_stress until inits done

[Bug #15784]

Revision 1613917a
Added by nobu (Nobuyoshi Nakada) 4 months ago

Defer setting gc_stress instead of setting dont_gc

[Bug #15784]



Updated by jeremyevans0 (Jeremy Evans) 8 days ago

  • Status changed from Open to Closed

Also available in: Atom PDF