// File: /workspace/github_c_makefile_star2_O2/mirth-lang[P]mirth/bin/mirth1.c
// Function: mw_std_list_List_1_reversezefor_1_sp13
static struct std_list_List_1 mw_std_list_List_1_reversezefor_1_sp13 (struct mirth_mirth_zaMirth* in_zaMirth_1, struct mirth_arrow_Arrow* in_zaAB_2, struct std_list_List_1 in_Ctx_3, struct mirth_type_StackType in_StackType_4, struct std_list_List_1 in_List_5, struct mirth_mirth_zaMirth* *out_zaMirth_6, struct mirth_arrow_Arrow* *out_zaAB_7, struct mirth_type_StackType *out_StackType_9) {
	struct std_list_List_1 v10 = mw_std_list_List_1_reverse(in_List_5);
	bool v11 = true;
	struct mirth_mirth_zaMirth* r12 = in_zaMirth_1;
	struct mirth_arrow_Arrow* r13 = in_zaAB_2;
	struct std_list_List_1 v14 = in_Ctx_3;
	struct mirth_type_StackType v15 = in_StackType_4;
	struct std_list_List_1 v16 = v10;
	bool v17 = v11;
	bool v18 = v11;
	while (v18) {
		struct mirth_mirth_zaMirth* r19 = r12;
		struct mirth_arrow_Arrow* r20 = r13;
		struct std_list_List_1 v21 = v14;
		struct mirth_type_StackType v22 = v15;
		struct std_list_List_1 v23 = v16;
		bool v24 = v17;
		struct std_list_List_1 branch_Ctx_25;
		struct mirth_type_StackType branch_StackType_26;
		struct mirth_mirth_zaMirth* branch_zaMirth_27;
		struct mirth_arrow_Arrow* branch_zaAB_28;
		struct std_list_List_1 branch_List_29;
		bool branch_Bool_30;
		switch ((v23).tag) {
			case std_list_List_1_Cons: {
				struct std_list_List_1 v31;
				VAL v32 = mtp_std_list_List_1_Cons(v23, &v31);
				incref(v32);
				struct std_list_List_1 v33 = mw_mirth_var_Ctx_new(v21, V_mirth_var_Var(v32));
				struct mirth_arrow_Arrow* v34;
				uint64_t v35 = mw_mirth_elab_zaAB_abzetokenzo(r20, &v34);
				struct mirth_mirth_zaMirth* v36;
				struct mirth_type_Type v37;
				uint64_t v38;
				struct mirth_type_StackType v39 = mw_mirth_elab_elabzeexpandzetensorzx(r19, v22, v35, &v36, &v37, &v38);
				struct mirth_mirth_zaMirth* v40;
				struct mirth_type_Type v41 = mw_mirth_var_Var_type(v36, V_mirth_var_Var(v32), &v40);
				struct mirth_mirth_zaMirth* v42;
				uint64_t v43;
				struct mirth_type_Type v44 = mw_mirth_elab_elabzetypezeunifyzx(v40, v37, v41, v38, &v42, &v43);
				decref(MK_mirth_type_Type(v44));
				bool v45 = true;
				branch_Bool_30 = v45;
				branch_List_29 = v31;
				branch_zaAB_28 = v34;
				branch_zaMirth_27 = v42;
				branch_StackType_26 = v39;
				branch_Ctx_25 = v33;
			} break;
			case std_list_List_1_Nil: {
				struct std_list_List_1 v46 = { .tag=std_list_List_1_Nil };
				bool v47 = false;
				branch_Bool_30 = v47;
				branch_List_29 = v46;
				branch_zaAB_28 = r20;
				branch_zaMirth_27 = r19;
				branch_StackType_26 = v22;
				branch_Ctx_25 = v21;
			} break;
			default: {
				do_panic(str_make("unexpected fallthrough in match\n", 32));
			}
		}
		v18 = branch_Bool_30;
		v17 = branch_Bool_30;
		v16 = branch_List_29;
		v15 = branch_StackType_26;
		v14 = branch_Ctx_25;
		r13 = branch_zaAB_28;
		r12 = branch_zaMirth_27;
	}
	decref(MK_std_list_List_1(v16));
	*out_StackType_9 = v15;
	*out_zaAB_7 = r13;
	*out_zaMirth_6 = r12;
	return v14;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %r9, -0x38(%rbp)
movl %r8d, -0x2c(%rbp)
movq %rcx, %r15
movl %edx, %r12d
movq %rsi, %rbx
movq %rdi, %r13
movq 0x20(%rbp), %r14
movl 0x10(%rbp), %edi
movq 0x18(%rbp), %rsi
callq 0xcd32
leaq -0x88(%rbp), %r8
movb $0x1, %cl
movabsq $0xfffffffffffc, %rsi   # imm = 0xFFFFFFFFFFFC
movq %rdx, %rdi
testb $0x1, %cl
je 0x3f9bb
xorl %ecx, %ecx
movl $0x0, %edx
testl %eax, %eax
je 0x3f74f
cmpl $0x1, %eax
jne 0x3fa19
movq %r8, %rsi
callq 0xce01
movq %rax, %r14
testb $0x1, %dl
je 0x3f79f
movq %r14, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %r14b
setne %dl
orb %cl, %dl
jne 0x3f79f
incl (%rax)
movl %r12d, %edi
movq %r15, %rsi
movq %r14, %rdx
callq 0x33f57
movl %eax, -0x48(%rbp)
movq %rdx, -0x58(%rbp)
movq %rbx, %rdi
leaq -0x78(%rbp), %rsi
callq 0x3f5b0
leaq -0x68(%rbp), %rcx
movq %rcx, (%rsp)
movq %r13, %rdi
movl -0x2c(%rbp), %esi
movq -0x38(%rbp), %rdx
movq %rax, %rcx
leaq -0x70(%rbp), %r8
leaq -0xa0(%rbp), %r9
callq 0x3e7d3
movl %eax, -0x2c(%rbp)
movq %rdx, -0x38(%rbp)
movq -0x70(%rbp), %rdi
movq %r14, %rsi
leaq -0x60(%rbp), %rdx
callq 0x32ea4
movl %eax, -0x40(%rbp)
movq %rdx, -0x50(%rbp)
movq -0x60(%rbp), %r12
movq -0x68(%rbp), %rbx
movl -0xa0(%rbp), %eax
movl %eax, -0x3c(%rbp)
movq -0x98(%rbp), %r15
movq 0x48(%r12), %r13
movq %r13, %rax
movabsq $0xfffffffffffc, %rsi   # imm = 0xFFFFFFFFFFFC
andq %rsi, %rax
setne %dl
testb $0x3, %r13b
sete %cl
andb %dl, %cl
cmpb $0x1, %cl
jne 0x3f844
addl $0x2, (%rax)
movl 0x8(%r13), %edx
movl %edx, -0x44(%rbp)
movq 0x10(%r13), %r14
movq %r14, %rdx
andq %rsi, %rdx
sete %sil
testb $0x3, %r14b
setne %dil
orb %sil, %dil
jne 0x3f868
incl (%rdx)
testb %cl, %cl
je 0x3f87f
decl (%rax)
jne 0x3f87f
movq %r13, %rdi
leaq 0xc8fe7(%rip), %rsi     # 0x108861
callq 0xce94
movq %rbx, %rdi
leaq 0xc952f(%rip), %rsi     # 0x108db8
callq 0x8d0c
movq %r13, %rdi
pushq $0x1
popq %rsi
callq 0x2e0a9
movq %rax, %rbx
movq 0x48(%r12), %rdi
movq %rdi, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %dil
setne %dl
orb %cl, %dl
jne 0x3f8cf
decl (%rax)
jne 0x3f8cf
leaq 0xc8f97(%rip), %rsi     # 0x108861
callq 0xce94
movq %rbx, 0x48(%r12)
movq %r12, %rdi
movl -0x3c(%rbp), %esi
movq %r15, %rdx
movl -0x40(%rbp), %ecx
movq -0x50(%rbp), %r8
leaq -0x90(%rbp), %r9
callq 0x32ede
movl %eax, %ebx
movq %rdx, %r15
movq -0x90(%rbp), %r13
movq 0x48(%r13), %rdi
movq %rdi, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %dil
setne %dl
orb %cl, %dl
jne 0x3f920
incl (%rax)
movl -0x44(%rbp), %esi
movq %r14, %rdx
callq 0x2e0a9
movq %rax, %r14
movq 0x48(%r13), %rdi
movq %rdi, %rax
movabsq $0xfffffffffffc, %rsi   # imm = 0xFFFFFFFFFFFC
andq %rsi, %rax
sete %cl
testb $0x3, %dil
setne %dl
orb %cl, %dl
movl -0x48(%rbp), %r12d
jne 0x3f96e
decl (%rax)
jne 0x3f96e
leaq 0xc8f02(%rip), %rsi     # 0x108861
callq 0xce94
movabsq $0xfffffffffffc, %rsi   # imm = 0xFFFFFFFFFFFC
movq %r14, 0x48(%r13)
movq %r15, %rax
andq %rsi, %rax
sete %cl
testb $0x3, %r15b
setne %dl
orb %cl, %dl
jne 0x3f9a0
decl (%rax)
jne 0x3f9a0
shlq $0x30, %rbx
orq %r15, %rbx
movq %rbx, %rdi
leaq 0xc914e(%rip), %rsi     # 0x108ae9
callq 0xce94
movl -0x88(%rbp), %eax
movq -0x80(%rbp), %rdx
movq -0x78(%rbp), %rbx
movq -0x58(%rbp), %r15
movq 0x20(%rbp), %r14
jmp 0x3f73c
andq %rdi, %rsi
sete %cl
testb $0x3, %dil
setne %dl
orb %cl, %dl
jne 0x3f9e6
decl (%rsi)
jne 0x3f9e6
shlq $0x30, %rax
orq %rdi, %rax
leaq 0xc889b(%rip), %rsi     # 0x108279
movq %rax, %rdi
callq 0xce94
movq 0x30(%rbp), %rax
movl -0x2c(%rbp), %ecx
movl %ecx, (%rax)
movq -0x38(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq 0x28(%rbp), %rax
movq %rbx, (%rax)
movq %r13, (%r14)
movl %r12d, %eax
movq %r15, %rdx
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x94ded(%rip), %rdi     # 0xd480d
pushq $0x20
popq %rsi
callq 0x8a21
movq %rax, %rdi
callq 0x8cc6