https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78105
--- Comment #4 from PeteVine <tulipawn at gmail dot com> --- That helped, running gdb --args manually wasn't working obviously: Program received signal SIGSEGV, Segmentation fault. _Unwind_GetGR (index=29, context=0x7fffffae00) at ../../../libgcc/unwind-dw2.c:240 240 return * (_Unwind_Ptr *) (_Unwind_Internal_Ptr) val; (gdb) bt #0 _Unwind_GetGR (index=29, context=0x7fffffae00) at ../../../libgcc/unwind-dw2.c:240 #1 _Unwind_GetPtr (index=29, context=0x7fffffae00) at ../../../libgcc/unwind-dw2.c:251 #2 uw_update_context_1 (context=context@entry=0x7fffffb260, fs=fs@entry=0x7fffffb620) at ../../../libgcc/unwind-dw2.c:1410 #3 0x000000000125f8ac in uw_update_context (fs=0x7fffffb620, context=0x7fffffb260) at ../../../libgcc/unwind-dw2.c:1502 #4 _Unwind_Backtrace (trace=0x11a2c70 <unwind(_Unwind_Context*, void*)>, trace_argument=0x7fffffbcc0) at ../../../libgcc/unwind.inc:303 #5 0x00000000011a2e88 in backtrace_full (state=0x7fb7fae000, skip=<optimized out>, callback=<optimized out>, error_callback=<optimized out>, data=<optimized out>) at ../../libbacktrace/backtrace.c:127 #6 0x00000000009a84a4 in diagnostic_action_after_output (context=context@entry=0x1658a18 <global_diagnostic_context>, diag_kind=<optimized out>) at ../../gcc/diagnostic.c:496 #7 0x00000000009a864c in diagnostic_report_diagnostic (context=0x1658a18 <global_diagnostic_context>, diagnostic=diagnostic@entry=0x7fffffbdb0) at ../../gcc/diagnostic.c:956 #8 0x00000000009a8a78 in diagnostic_impl (richloc=richloc@entry=0x7fffffbe38, opt=opt@entry=-1, gmsgid=gmsgid@entry=0x12d33c8 "tree check: expected class %qs, have %qs (%s) in %s, at %s:%d", ap=ap@entry=0x7fffffbe28, kind=kind@entry=DK_ICE) at ../../gcc/diagnostic.c:1070 #9 0x00000000009a8b28 in internal_error (gmsgid=0x12d33c8 "tree check: expected class %qs, have %qs (%s) in %s, at %s:%d") at ../../gcc/diagnostic.c:1381 #10 0x0000000000b5b8d0 in tree_class_check_failed (node=<optimized out>, cl=<optimized out>, file=<optimized out>, line=3539, function=0x14184e8 <_ZZ18tree_operand_checkP9tree_nodeiPKciS2_E12__FUNCTION__.lto_priv.3174> "tree_operand_check") at ../../gcc/tree.c:9792 #11 0x00000000007aa1bc in expr_check(tree_node*, char const*, int, char const*) () at ../../gcc/tree.h:3210 #12 tree_operand_check(tree_node*, int, char const*, int, char const*) (__g=<optimized out>, __l=<optimized out>, __f=<optimized out>, __i=<optimized out>, __t=<optimized out>) at ../../gcc/tree.h:3539 #13 extract_ops_from_tree(tree_node*, tree_code*, tree_node**, tree_node**, tree_node**) (expr=<optimized out>, subcode_p=subcode_p@entry=0x7fffffc044, op1_p=op1_p@entry=0x7fffffc058, op2_p=op2_p@entry=0x7fffffc050, op3_p=op3_p@entry=0x7fffffc048) at ../../gcc/gimple-expr.c:532 #14 0x00000000007b92ec in gimple_build_assign(tree_node*, tree_node*) (lhs=0x7fb70feab0, rhs=<optimized out>) at ../../gcc/gimple.c:395 #15 0x000000000086f6c8 in gimplify_modify_expr (expr_p=expr_p@entry=0x7fb70f3ce8, pre_p=pre_p@entry=0x7fffffc548, post_p=post_p@entry=0x7fffffc210, want_value=want_value@entry=true) at ../../gcc/gimplify.c:5423 #16 0x000000000085a10c in gimplify_expr (expr_p=0x7fb70f3ce8, pre_p=pre_p@entry=0x7fffffc548, post_p=0x7fffffc210, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:10998 #17 0x000000000085ff40 in gimplify_stmt (stmt_p=<optimized out>, seq_p=seq_p@entry=0x7fffffc548) at ../../gcc/gimplify.c:6260 #18 0x000000000085a5b8 in gimplify_statement_list (pre_p=0x7fffffc548, expr_p=0x7fb7118020) at ../../gcc/gimplify.c:1553 #19 gimplify_expr (expr_p=0x7fb7118020, pre_p=pre_p@entry=0x7fffffc548, post_p=0x7fffffc3e0, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11411 #20 0x000000000085ff40 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fb7118020, seq_p=0x7fffffc548, seq_p@entry=0x7fffffc5d8) at ../../gcc/gimplify.c:6260 #21 0x000000000086c32c in gimplify_bind_expr (expr_p=expr_p@entry=0x7fb70f3e80, pre_p=pre_p@entry=0x7fffffc9b8) at ../../gcc/gimplify.c:1155 #22 0x0000000000859cb8 in gimplify_expr (expr_p=0x7fb70f3e80, pre_p=pre_p@entry=0x7fffffc9b8, post_p=0x7fffffc680, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11197 #23 0x000000000085ff40 in gimplify_stmt (stmt_p=<optimized out>, seq_p=seq_p@entry=0x7fffffc9b8) at ../../gcc/gimplify.c:6260 #24 0x000000000085a5b8 in gimplify_statement_list (pre_p=0x7fffffc9b8, expr_p=0x7fb7118080) at ../../gcc/gimplify.c:1553 #25 gimplify_expr (expr_p=0x7fb7118080, pre_p=pre_p@entry=0x7fffffc9b8, post_p=0x7fffffc850, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11411 #26 0x000000000085ff40 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fb7118080, seq_p=0x7fffffc9b8, seq_p@entry=0x7fffffca48) at ../../gcc/gimplify.c:6260 #27 0x000000000086c32c in gimplify_bind_expr (expr_p=expr_p@entry=0x7fffffcd28, pre_p=pre_p@entry=0x7fffffd8f8) at ../../gcc/gimplify.c:1155 #28 0x0000000000859cb8 in gimplify_expr (expr_p=0x7fffffcd28, expr_p@entry=0x7fffffcdf8, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffcf20, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11197 #29 0x000000000085c1f4 in gimplify_target_expr (post_p=0x7fffffcf20, pre_p=0x7fffffd8f8, expr_p=0x7fb788f2f0) at ../../gcc/gimplify.c:6186 #30 gimplify_expr (expr_p=expr_p@entry=0x7fb788f2f0, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffcf20, gimple_test_f=gimple_test_f@entry=0x7a45b8 <is_gimple_reg_rhs_or_call(tree_node*) [clone .lto_priv.9789]>, fallback=<optimized out>) at ../../gcc/gimplify.c:11363 #31 0x000000000086f570 in gimplify_modify_expr (expr_p=expr_p@entry=0x7fffffd090, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffcf20, want_value=want_value@entry=true) at ../../gcc/gimplify.c:5263 #32 0x000000000085a10c in gimplify_expr (expr_p=0x7fffffd090, expr_p@entry=0x7fffffd120, pre_p=pre_p@entry=0x7fffffd8f8, post_p=0x7fffffcf20, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:10998 #33 0x000000000085ff04 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fffffd120, seq_p=seq_p@entry=0x7fffffd8f8) at ../../gcc/gimplify.c:6260 #34 0x000000000086b6d0 in gimplify_and_add () at ../../gcc/gimplify.c:428 #35 gimplify_init_ctor_eval (object=object@entry=0x7fb70fe750, elts=elts@entry=0x7fb768fc60, pre_p=pre_p@entry=0x7fffffd8f8, cleared=cleared@entry=false) at ../../gcc/gimplify.c:4255 #36 0x000000000086e258 in gimplify_init_constructor (expr_p=expr_p@entry=0x7fffffd5e0, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffd3f0, want_value=127, want_value@entry=168, notify_temp_creation=notify_temp_creation@entry=false) at ../../gcc/gimplify.c:4627 #37 0x000000000086f070 in gimplify_modify_expr_rhs (expr_p=expr_p@entry=0x7fffffd5e0, from_p=from_p@entry=0x7fb788f2c8, to_p=to_p@entry=0x7fb788f2c0, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffd3f0, want_value=want_value@entry=false) at ../../gcc/gimplify.c:4888 #38 0x000000000086f39c in gimplify_modify_expr (expr_p=expr_p@entry=0x7fffffd5e0, pre_p=pre_p@entry=0x7fffffd8f8, post_p=post_p@entry=0x7fffffd3f0, want_value=false, want_value@entry=true) at ../../gcc/gimplify.c:5224 #39 0x000000000085a10c in gimplify_expr (expr_p=0x7fffffd5e0, expr_p@entry=0x7fffffd6b0, pre_p=pre_p@entry=0x7fffffd8f8, post_p=0x7fffffd3f0, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:10998 #40 0x000000000085ff04 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fffffd6b0, seq_p=seq_p@entry=0x7fffffd8f8) at ../../gcc/gimplify.c:6260 #41 0x0000000000858ac4 in gimplify_and_add () at ../../gcc/gimplify.c:428 #42 gimplify_decl_expr (seq_p=0x7fffffd8f8, stmt_p=0x7fb70f3ec8) at ../../gcc/gimplify.c:1500 #43 gimplify_expr (expr_p=0x7fb70f3ec8, pre_p=pre_p@entry=0x7fffffd8f8, post_p=0x7fffffd5c0, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11193 #44 0x000000000085ff04 in gimplify_stmt (stmt_p=<optimized out>, seq_p=seq_p@entry=0x7fffffd8f8) at ../../gcc/gimplify.c:6260 #45 0x000000000085a5b8 in gimplify_statement_list (pre_p=0x7fffffd8f8, expr_p=0x7fb7118320) at ../../gcc/gimplify.c:1553 #46 gimplify_expr (expr_p=0x7fb7118320, pre_p=pre_p@entry=0x7fffffd8f8, post_p=0x7fffffd790, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11411 #47 0x000000000085ff40 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fb7118320, seq_p=0x7fffffd8f8, seq_p@entry=0x7fffffd988) at ../../gcc/gimplify.c:6260 #48 0x000000000086c32c in gimplify_bind_expr (expr_p=expr_p@entry=0x7fb70e4dc0, pre_p=pre_p@entry=0x7fffffdb50) at ../../gcc/gimplify.c:1155 #49 0x0000000000859cb8 in gimplify_expr (expr_p=0x7fb70e4dc0, pre_p=pre_p@entry=0x7fffffdb50, post_p=0x7fffffda30, post_p@entry=0x0, gimple_test_f=gimple_test_f@entry=0x81eeb8 <is_gimple_stmt(tree)>, fallback=fallback@entry=0) at ../../gcc/gimplify.c:11197 #50 0x000000000085ff40 in gimplify_stmt (stmt_p=stmt_p@entry=0x7fb70e4dc0, seq_p=seq_p@entry=0x7fffffdb50) at ../../gcc/gimplify.c:6260 #51 0x0000000000862030 in gimplify_body (fndecl=fndecl@entry=0x7fb70e4d00, do_parms=do_parms@entry=true) at ../../gcc/gimplify.c:12177 #52 0x0000000000862718 in gimplify_function_tree (fndecl=0x7fb70e4d00) at ../../gcc/gimplify.c:12333 #53 0x0000000000eb6970 in cgraph_node::analyze() (this=this@entry=0x7fb7119000) at ../../gcc/cgraphunit.c:626 #54 0x0000000000eb9dd8 in analyze_functions (first_time=false, first_time@entry=true) at ../../gcc/cgraphunit.c:1087 #55 0x0000000000ebb148 in symbol_table::finalize_compilation_unit() (this=0x7fb7798000) at ../../gcc/cgraphunit.c:2562 #56 0x0000000000c74bb0 in compile_file () at ../../gcc/toplev.c:493 #57 0x000000000058b378 in do_compile () at ../../gcc/toplev.c:2012 #58 toplev::main (this=this@entry=0x7fffffdf38, argc=<optimized out>, argc@entry=92, argv=<optimized out>, argv@entry=0x7fffffe088) at ../../gcc/toplev.c:2146 #59 0x000000000058a85c in main (argc=92, argv=0x7fffffe088) at ../../gcc/main.c:39