Skip to content

Instantly share code, notes, and snippets.

@dogbert17
Created July 31, 2021 11:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dogbert17/2c7e49d61833cc1f566ea3487195f41b to your computer and use it in GitHub Desktop.
Save dogbert17/2c7e49d61833cc1f566ea3487195f41b to your computer and use it in GitHub Desktop.
SEGV during spectest run
dogbert@dogbert-VirtualBox:~/repos/rakudo$ gdb install/bin/moar core.moar.1000.f4e1afea0509471c9f4e9e8a321dd81a.1641486.1627731959000000000000
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
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:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from install/bin/moar...
[New LWP 1641486]
[New LWP 1641487]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/home/dogbert/repos/rakudo/nqp/MoarVM/../../install/bin/moar --execname=/home/d'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 MVM_gc_root_add_frame_registers_to_worklist (tc=0x5596ab1cae40, worklist=0x5596ae452820, frame=0x7fa42ad34880) at src/gc/roots.c:497
497 frame->params.legacy.arg_flags && frame->params.legacy.callsite->has_flattening) {
[Current thread is 1 (Thread 0x7fa42ad51440 (LWP 1641486))]
(gdb) bt
#0 MVM_gc_root_add_frame_registers_to_worklist (tc=0x5596ab1cae40, worklist=0x5596ae452820, frame=0x7fa42ad34880) at src/gc/roots.c:497
#1 0x00007fa42b36597c in MVM_gc_root_add_frame_roots_to_worklist (tc=0x5596ab1cae40, worklist=0x5596ae452820, cur_frame=0x7fa42ad34880) at src/gc/roots.c:447
#2 0x00007fa42b3273c9 in mark (tc=0x5596ab1cae40, from_record=0x7fa42ad34870, worklist=0x5596ae452820, snapshot=0x0) at src/core/callstack.c:524
#3 0x00007fa42b328690 in MVM_callstack_mark_current_thread (tc=0x5596ab1cae40, worklist=0x5596ae452820, snapshot=0x0) at src/core/callstack.c:609
#4 0x00007fa42b361d8b in MVM_gc_root_add_tc_roots_to_worklist (tc=0x5596ab1cae40, worklist=0x5596ae452820, snapshot=0x0) at src/gc/roots.c:173
#5 0x00007fa42b367080 in MVM_gc_collect (tc=0x5596ab1cae40, what_to_do=0 '\000', gen=0 '\000') at src/gc/collect.c:121
#6 0x00007fa42b35ba92 in run_gc (tc=0x5596ab1cae40, what_to_do=0 '\000') at src/gc/orchestrate.c:443
#7 0x00007fa42b35c16c in MVM_gc_enter_from_allocator (tc=0x5596ab1cae40) at src/gc/orchestrate.c:598
#8 0x00007fa42b35cbef in MVM_gc_allocate_nursery (tc=0x5596ab1cae40, size=80) at src/gc/allocation.c:37
#9 0x00007fa42b35c9e2 in MVM_gc_allocate (tc=0x5596ab1cae40, size=80) at src/gc/allocation.h:18
#10 0x00007fa42b35cc7c in MVM_gc_allocate_zeroed (tc=0x5596ab1cae40, size=80) at src/gc/allocation.c:56
#11 0x00007fa42b35d00a in MVM_gc_allocate_object (tc=0x5596ab1cae40, st=0x5596ab235c98) at src/gc/allocation.c:93
#12 0x00007fa42b38962d in MVM_repr_alloc_init (tc=0x5596ab1cae40, type=0x5596ab2414d8) at src/6model/reprconv.c:17
#13 0x00007fa42b43b219 in MVM_spesh_log_create (tc=0x5596ab1cae40, target_thread=0x5596ab272c50) at src/spesh/log.c:17
#14 0x00007fa42b43b4c8 in send_log (tc=0x5596ab1cae40, sl=0x5596acaba450) at src/spesh/log.c:48
#15 0x00007fa42b43b549 in commit_entry (tc=0x5596ab1cae40, sl=0x5596acaba450) at src/spesh/log.c:58
#16 0x00007fa42b43b815 in log_param_type (tc=0x5596ab1cae40, cid=15821, arg_idx=0, value=0x5596ae4f05d0, kind=MVM_SPESH_LOG_PARAMETER, rw_cont=0) at src/spesh/log.c:92
#17 0x00007fa42b43b8d3 in log_parameter (tc=0x5596ab1cae40, cid=15821, arg_idx=0, param=0x5596ae4f05d0) at src/spesh/log.c:96
#18 0x00007fa42b43bbb9 in MVM_spesh_log_entry (tc=0x5596ab1cae40, cid=15821, sf=0x5596accb1980, args=...) at src/spesh/log.c:130
#19 0x00007fa42b320333 in MVM_frame_dispatch (tc=0x5596ab1cae40, code=0x5596accd59b8, args=..., spesh_cand=-1) at src/core/frame.c:670
#20 0x00007fa42b411803 in MVM_disp_program_run (tc=0x5596ab1cae40, dp=0x5596adc820d0, record=0x7fa42ad34708, spesh_cid=0, bytecode_offset=154, dp_index=0) at src/disp/program.c:2820
#21 0x00007fa42b4051fa in dispatch_polymorphic (tc=0x5596ab1cae40, entry_ptr=0x5596adc84398, seen=0x5596ae194920, id=0x5596accc3580, callsite=0x5596ab29d890, arg_indices=0x7fa4281f3cd2, source=0x5596ab29de20,
sf=0x5596accb6880, bytecode_offset=154) at src/disp/inline_cache.c:176
#22 0x00007fa42b3067e3 in MVM_interp_run (tc=0x5596ab1cae40, initial_invoke=0x7fa42b4ad0b2 <toplevel_initial_invoke>, invoke_data=0x5596ab2839d0, outer_runloop=0x0) at src/core/interp.c:5501
#23 0x00007fa42b4ad213 in MVM_vm_run_file (instance=0x5596ab1ca2a0, filename=0x7ffd89c9d170 "/home/dogbert/repos/rakudo/rakudo.moarvm") at src/moar.c:506
#24 0x00005596a929cc87 in main (argc=7, argv=0x7ffd89c9cc08) at src/main.c:305
(gdb) p frame
$1 = (MVMFrame *) 0x7fa42ad34880
(gdb) p frame.params
$2 = {version = 1 '\001', legacy = {callsite = 0x0, arg_flags = 0x7fa42ad34704 "", args = 0x0, arg_count = 51712, num_pos = 11155, flag_count = 32676}, arg_info = {callsite = 0x5596ad596340,
source = 0x5596ae4bfd60, map = 0x5596ab247cf0}, named_used = {byte_array = 0x5596ab2e1cf0 "", bit_field = 94105605381360}, named_used_size = 1}
(gdb) p frame.params.legacy
$3 = {callsite = 0x0, arg_flags = 0x7fa42ad34704 "", args = 0x0, arg_count = 51712, num_pos = 11155, flag_count = 32676}
(gdb) p frame.params.legacy.arg_flags
$4 = (MVMCallsiteEntry *) 0x7fa42ad34704 ""
(gdb) p frame
$5 = (MVMFrame *) 0x7fa42ad34880
(gdb) p frame->params
$6 = {version = 1 '\001', legacy = {callsite = 0x0, arg_flags = 0x7fa42ad34704 "", args = 0x0, arg_count = 51712, num_pos = 11155, flag_count = 32676}, arg_info = {callsite = 0x5596ad596340,
source = 0x5596ae4bfd60, map = 0x5596ab247cf0}, named_used = {byte_array = 0x5596ab2e1cf0 "", bit_field = 94105605381360}, named_used_size = 1}
(gdb) p frame->params.legacy
$7 = {callsite = 0x0, arg_flags = 0x7fa42ad34704 "", args = 0x0, arg_count = 51712, num_pos = 11155, flag_count = 32676}
(gdb) p frame->params.legacy.callsite
$8 = (MVMCallsite *) 0x0
(gdb) inf threads
Id Target Id Frame
* 1 Thread 0x7fa42ad51440 (LWP 1641486) MVM_gc_root_add_frame_registers_to_worklist (tc=0x5596ab1cae40, worklist=0x5596ae452820, frame=0x7fa42ad34880) at src/gc/roots.c:497
2 Thread 0x7fa42ad0d700 (LWP 1641487) futex_wait_cancelable (private=<optimized out>, expected=0, futex_word=0x5596ab1ca424) at ../sysdeps/nptl/futex-internal.h:183
(gdb)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment