// File: /workspace/github_c_makefile_star2_O0/mirth-lang[P]mirth/bin/mirth1.c
// Function: mw_mirth_elab_elabzematchzecaseszecurlyzx
static void mw_mirth_elab_elabzematchzecaseszecurlyzx (struct mirth_mirth_zaMirth* in_zaMirth_1, struct mirth_match_zaMatch* in_zaMatch_2, struct mirth_mirth_zaMirth* *out_zaMirth_3, struct mirth_match_zaMatch* *out_zaMatch_4) {
	uint64_t v5 = in_zaMatch_2->mbody;
	struct mirth_mirth_zaMirth* v6;
	struct std_list_List_1 v7 = mw_mirth_token_Token_runzetokens(in_zaMirth_1, v5, &v6);
	bool v8 = true;
	struct mirth_mirth_zaMirth* r9 = v6;
	struct mirth_match_zaMatch* r10 = in_zaMatch_2;
	struct std_list_List_1 v11 = v7;
	bool v12 = v8;
	bool v13 = v8;
	while (v13) {
		struct mirth_mirth_zaMirth* r14 = r9;
		struct mirth_match_zaMatch* r15 = r10;
		struct std_list_List_1 v16 = v11;
		bool v17 = v12;
		struct mirth_mirth_zaMirth* branch_zaMirth_18;
		struct mirth_match_zaMatch* branch_zaMatch_19;
		struct std_list_List_1 branch_List_20;
		bool branch_Bool_21;
		switch ((v16).tag) {
			case std_list_List_1_Cons: {
				struct std_list_List_1 v22;
				VAL v23 = mtp_std_list_List_1_Cons(v16, &v22);
				incref(v23);
				struct mirth_mirth_zaMirth* v24;
				struct std_maybe_Maybe_1 v25 = mw_mirth_token_Token_lcurlyzy(r14, V_mirth_token_Token(v23), &v24);
				int64_t v26 = (v25).tag;
				decref(MK_std_maybe_Maybe_1(v25));
				INT v27 = WRAP_I63(0LL);
				INT v28 = v27;
				INT v29 = i64_to_int(v26);
				bool v30 = int_eq(v29, v28);
				bool v31 = !v30;
				struct mirth_mirth_zaMirth* branch_zaMirth_32;
				uint64_t branch_Token_33;
				VAL branch_zux1_34;
				if (v31) {
					branch_zux1_34 = MK_mirth_match_zaMatch(r15);
					branch_Token_33 = V_mirth_token_Token(v23);
					branch_zaMirth_32 = v24;
				} else {
					STR* v35;
					STRLIT(v35, "Expected a pattern match case of the form { ... -> ... }", 56);
					mw_mirth_mirth_zaMirth_emitzefatalzeerrorzx(v24, V_mirth_token_Token(v23), v35);
				}
				struct mirth_mirth_zaMirth* v38;
				uint64_t v39 = mw_mirth_token_Token_argsze1(branch_zaMirth_32, branch_Token_33, &v38);
				struct mirth_mirth_zaMirth* v40;
				struct mirth_match_zaMatch* v41;
				uint64_t v42 = mw_mirth_elab_elabzematchzecasezx(v39, v38, V_mirth_match_zaMatch(branch_zux1_34), &v40, &v41);
				bool v43 = true;
				branch_Bool_21 = v43;
				branch_List_20 = v22;
				branch_zaMatch_19 = v41;
				branch_zaMirth_18 = v40;
			} break;
			case std_list_List_1_Nil: {
				struct std_list_List_1 v44 = { .tag=std_list_List_1_Nil };
				bool v45 = false;
				branch_Bool_21 = v45;
				branch_List_20 = v44;
				branch_zaMatch_19 = r15;
				branch_zaMirth_18 = r14;
			} break;
			default: {
				do_panic(str_make("unexpected fallthrough in match\n", 32));
			}
		}
		v13 = branch_Bool_21;
		v12 = branch_Bool_21;
		v11 = branch_List_20;
		r10 = branch_zaMatch_19;
		r9 = branch_zaMirth_18;
	}
	decref(MK_std_list_List_1(v11));
	*out_zaMatch_4 = r10;
	*out_zaMirth_3 = r9;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x290, %rsp            # imm = 0x290
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movq -0x28(%rbp), %rsi
leaq -0x30(%rbp), %rdx
callq 0xaca10
movl %eax, -0x40(%rbp)
movq %rdx, -0x38(%rbp)
movb $0x1, -0x41(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x60(%rbp)
movb -0x41(%rbp), %al
andb $0x1, %al
movb %al, -0x69(%rbp)
movb -0x41(%rbp), %al
andb $0x1, %al
movb %al, -0x6a(%rbp)
testb $0x1, -0x6a(%rbp)
je 0xf57b3
movq -0x50(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x80(%rbp)
movups -0x68(%rbp), %xmm0
movaps %xmm0, -0x90(%rbp)
movb -0x69(%rbp), %al
andb $0x1, %al
movb %al, -0x91(%rbp)
movl -0x90(%rbp), %eax
movl %eax, -0x284(%rbp)
testl %eax, %eax
je 0xf56f7
jmp 0xf52a9
movl -0x284(%rbp), %eax
subl $0x1, %eax
jne 0xf5753
jmp 0xf52ba
movl -0x90(%rbp), %edi
movq -0x88(%rbp), %rsi
leaq -0xd0(%rbp), %rdx
callq 0x125e0
movq %rax, -0xe0(%rbp)
movq %rdx, -0xd8(%rbp)
movq -0xd8(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xf5332
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0xe0(%rbp), %rax
cmpq $0x0, %rax
je 0xf5332
movq -0xe0(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xf5332
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0xe0(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xf5334
movq -0x78(%rbp), %rdi
movq -0xe0(%rbp), %rsi
leaq -0xe8(%rbp), %rdx
callq 0x9e8d0
movl %eax, -0xf8(%rbp)
movq %rdx, -0xf0(%rbp)
movl -0xf8(%rbp), %eax
movq %rax, -0x100(%rbp)
movl -0xf8(%rbp), %edi
movq -0xf0(%rbp), %rsi
callq 0x133a0
movq %rax, -0x110(%rbp)
movq %rdx, -0x108(%rbp)
movq -0x108(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xf5478
movl -0xf8(%rbp), %edi
movq -0xf0(%rbp), %rsi
callq 0x133a0
movq %rax, -0x120(%rbp)
movq %rdx, -0x118(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x120(%rbp), %rax
cmpq $0x0, %rax
je 0xf5478
movl -0xf8(%rbp), %edi
movq -0xf0(%rbp), %rsi
callq 0x133a0
movq %rax, -0x130(%rbp)
movq %rdx, -0x128(%rbp)
movq -0x130(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xf5478
movl -0xf8(%rbp), %edi
movq -0xf0(%rbp), %rsi
callq 0x133a0
movq %rax, -0x140(%rbp)
movq %rdx, -0x138(%rbp)
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq -0x140(%rbp), %rcx
movl (%rcx), %eax
addl $-0x1, %eax
movl %eax, (%rcx)
cmpl $0x0, %eax
jne 0xf5476
movl -0xf8(%rbp), %edi
movq -0xf0(%rbp), %rsi
callq 0x133a0
movq %rax, -0x150(%rbp)
movq %rdx, -0x148(%rbp)
movq -0x150(%rbp), %rdi
movq -0x148(%rbp), %rsi
callq 0x127c0
jmp 0xf5478
jmp 0xf547a
movq 0x2795cf(%rip), %rax    # 0x36ea50
movq %rax, -0x158(%rbp)
movq -0x158(%rbp), %rax
movq %rax, -0x160(%rbp)
movq -0x100(%rbp), %rdi
callq 0x1a290
movq %rax, -0x168(%rbp)
movq -0x168(%rbp), %rdi
movq -0x160(%rbp), %rsi
callq 0x194b0
andb $0x1, %al
movb %al, -0x169(%rbp)
movb -0x169(%rbp), %al
xorb $-0x1, %al
andb $0x1, %al
movb %al, -0x16a(%rbp)
testb $0x1, -0x16a(%rbp)
je 0xf5533
movq -0x80(%rbp), %rax
movq %rax, -0x1a0(%rbp)
leaq 0x29d0f1(%rip), %rax    # 0x3925e0
movq %rax, -0x198(%rbp)
movq -0x1a0(%rbp), %rax
movq %rax, -0x190(%rbp)
movq -0x198(%rbp), %rax
movq %rax, -0x188(%rbp)
movq -0xe0(%rbp), %rax
movq %rax, -0x180(%rbp)
movq -0xe8(%rbp), %rax
movq %rax, -0x178(%rbp)
jmp 0xf5658
jmp 0xf5535
cmpq $0x0, 0x12a061b(%rip)   # 0x1395b58
jne 0xf5557
leaq 0x263d1e(%rip), %rdi    # 0x359264
movl $0x38, %esi
callq 0xb6c0
movq %rax, 0x12a0601(%rip)   # 0x1395b58
jmp 0xf5559
movq 0x12a05f8(%rip), %rax   # 0x1395b58
movq %rax, -0x1b8(%rbp)
leaq 0x29bbea(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x1b0(%rbp)
movq -0x1b0(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xf562e
movq 0x12a05c3(%rip), %rax   # 0x1395b58
movq %rax, -0x1c8(%rbp)
leaq 0x29bbb5(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x1c0(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x1c8(%rbp), %rax
cmpq $0x0, %rax
je 0xf562e
movq 0x12a058c(%rip), %rax   # 0x1395b58
movq %rax, -0x1d8(%rbp)
leaq 0x29bb7e(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x1d0(%rbp)
movq -0x1d8(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xf562e
movq 0x12a055b(%rip), %rax   # 0x1395b58
movq %rax, -0x1e8(%rbp)
leaq 0x29bb4d(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x1e0(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x1e8(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xf5630
movq 0x12a0521(%rip), %rax   # 0x1395b58
movq %rax, -0x1a8(%rbp)
movq -0xe8(%rbp), %rdi
movq -0xe0(%rbp), %rsi
movq -0x1a8(%rbp), %rdx
callq 0x76b70
movq -0x178(%rbp), %rdi
movq -0x180(%rbp), %rsi
leaq -0x1f0(%rbp), %rdx
callq 0xa8660
movq %rax, -0x1f8(%rbp)
movq -0x1f8(%rbp), %rdi
movq -0x1f0(%rbp), %rsi
movq -0x190(%rbp), %rdx
leaq -0x200(%rbp), %rcx
leaq -0x208(%rbp), %r8
callq 0xf5a00
movq %rax, -0x210(%rbp)
movb $0x1, -0x211(%rbp)
movb -0x211(%rbp), %al
andb $0x1, %al
movb %al, -0xb9(%rbp)
movq -0xd0(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0xc8(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x208(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0x200(%rbp), %rax
movq %rax, -0xa0(%rbp)
jmp 0xf576c
leaq -0x228(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x5080
movb $0x0, -0x229(%rbp)
movb -0x229(%rbp), %al
andb $0x1, %al
movb %al, -0xb9(%rbp)
movq -0x228(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x220(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x80(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0xa0(%rbp)
jmp 0xf576c
leaq 0x25e727(%rip), %rdi    # 0x353e81
movl $0x20, %esi
callq 0xb6c0
movq %rax, %rdi
callq 0xc620
movb -0xb9(%rbp), %al
andb $0x1, %al
movb %al, -0x6a(%rbp)
movb -0xb9(%rbp), %al
andb $0x1, %al
movb %al, -0x69(%rbp)
movq -0xb8(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0xb0(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, -0x50(%rbp)
jmp 0xf5263
jmp 0xf57b5
movl -0x68(%rbp), %edi
movq -0x60(%rbp), %rsi
callq 0x12780
movq %rax, -0x240(%rbp)
movq %rdx, -0x238(%rbp)
movq -0x238(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xf58aa
movl -0x68(%rbp), %edi
movq -0x60(%rbp), %rsi
callq 0x12780
movq %rax, -0x250(%rbp)
movq %rdx, -0x248(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x250(%rbp), %rax
cmpq $0x0, %rax
je 0xf58aa
movl -0x68(%rbp), %edi
movq -0x60(%rbp), %rsi
callq 0x12780
movq %rax, -0x260(%rbp)
movq %rdx, -0x258(%rbp)
movq -0x260(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xf58aa
movl -0x68(%rbp), %edi
movq -0x60(%rbp), %rsi
callq 0x12780
movq %rax, -0x270(%rbp)
movq %rdx, -0x268(%rbp)
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq -0x270(%rbp), %rcx
movl (%rcx), %eax
addl $-0x1, %eax
movl %eax, (%rcx)
cmpl $0x0, %eax
jne 0xf58a8
movl -0x68(%rbp), %edi
movq -0x60(%rbp), %rsi
callq 0x12780
movq %rax, -0x280(%rbp)
movq %rdx, -0x278(%rbp)
movq -0x280(%rbp), %rdi
movq -0x278(%rbp), %rsi
callq 0x127c0
jmp 0xf58aa
jmp 0xf58ac
movq -0x58(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x50(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
addq $0x290, %rsp            # imm = 0x290
popq %rbp
retq
nopl (%rax,%rax)