// File: /workspace/github_c_makefile_star2_O3/mirth-lang[P]mirth/bin/mirth1.c
// Function: mw_std_list_List_1_zd_sp1
static bool mw_std_list_List_1_zd_sp1 (struct mirth_mirth_zaMirth* in_zaMirth_1, struct std_list_List_1 in_List_2, struct std_list_List_1 in_List_3, struct mirth_mirth_zaMirth* *out_zaMirth_4) {
	bool v6 = true;
	struct std_list_List_1 v7;
	struct std_maybe_Maybe_1 v8 = mw_std_list_List_1_uncons(in_List_2, &v7);
	struct std_list_List_1 v9;
	struct std_maybe_Maybe_1 v10 = mw_std_list_List_1_uncons(in_List_3, &v9);
	struct mirth_mirth_zaMirth* branch_zaMirth_11;
	bool branch_Bool_12;
	switch ((v10).tag) {
		case std_maybe_Maybe_1_None: {
			int64_t v13 = (v8).tag;
			decref(MK_std_maybe_Maybe_1(v8));
			INT v14 = WRAP_I63(0LL);
			INT v15 = v14;
			INT v16 = i64_to_int(v13);
			bool v17 = int_eq(v16, v15);
			branch_Bool_12 = v17;
			branch_zaMirth_11 = in_zaMirth_1;
		} break;
		case std_maybe_Maybe_1_Some: {
			VAL v18 = mtp_std_maybe_Maybe_1_Some(v10);
			struct mirth_mirth_zaMirth* branch_zaMirth_19;
			bool branch_Bool_20;
			switch ((v8).tag) {
				case std_maybe_Maybe_1_Some: {
					VAL v21 = mtp_std_maybe_Maybe_1_Some(v8);
					struct mirth_mirth_zaMirth* v22;
					bool v23 = mw_mirth_arrow_Arg_similar(in_zaMirth_1, V_mirth_arrow_Block(v21), V_mirth_arrow_Block(v18), &v22);
					branch_Bool_20 = v23;
					branch_zaMirth_19 = v22;
				} break;
				case std_maybe_Maybe_1_None: {
					decref(v18);
					bool v24 = false;
					branch_Bool_20 = v24;
					branch_zaMirth_19 = in_zaMirth_1;
				} break;
				default: {
					do_panic(str_make("unexpected fallthrough in match\n", 32));
				}
			}
			branch_Bool_12 = branch_Bool_20;
			branch_zaMirth_11 = branch_zaMirth_19;
		} break;
		default: {
			do_panic(str_make("unexpected fallthrough in match\n", 32));
		}
	}
	bool v25 = (branch_Bool_12 && v6);
	incref(MK_std_list_List_1(v7));
	bool v26 = mw_std_list_List_1_emptyzy(v7);
	incref(MK_std_list_List_1(v9));
	bool v27 = mw_std_list_List_1_emptyzy(v9);
	bool v28 = (v26 && v27);
	bool v29 = !v28;
	bool v30 = (v29 && v25);
	struct mirth_mirth_zaMirth* r31 = branch_zaMirth_11;
	struct std_list_List_1 v32 = v7;
	struct std_list_List_1 v33 = v9;
	bool v34 = v25;
	bool v35 = v30;
	while (v35) {
		struct mirth_mirth_zaMirth* r36 = r31;
		struct std_list_List_1 v37 = v32;
		struct std_list_List_1 v38 = v33;
		bool v39 = v34;
		struct std_list_List_1 v40;
		struct std_maybe_Maybe_1 v41 = mw_std_list_List_1_uncons(v37, &v40);
		struct std_list_List_1 v42;
		struct std_maybe_Maybe_1 v43 = mw_std_list_List_1_uncons(v38, &v42);
		struct mirth_mirth_zaMirth* branch_zaMirth_44;
		bool branch_Bool_45;
		switch ((v43).tag) {
			case std_maybe_Maybe_1_None: {
				int64_t v46 = (v41).tag;
				decref(MK_std_maybe_Maybe_1(v41));
				INT v47 = WRAP_I63(0LL);
				INT v48 = v47;
				INT v49 = i64_to_int(v46);
				bool v50 = int_eq(v49, v48);
				branch_Bool_45 = v50;
				branch_zaMirth_44 = r36;
			} break;
			case std_maybe_Maybe_1_Some: {
				VAL v51 = mtp_std_maybe_Maybe_1_Some(v43);
				struct mirth_mirth_zaMirth* branch_zaMirth_52;
				bool branch_Bool_53;
				switch ((v41).tag) {
					case std_maybe_Maybe_1_Some: {
						VAL v54 = mtp_std_maybe_Maybe_1_Some(v41);
						struct mirth_mirth_zaMirth* v55;
						bool v56 = mw_mirth_arrow_Arg_similar(r36, V_mirth_arrow_Block(v54), V_mirth_arrow_Block(v51), &v55);
						branch_Bool_53 = v56;
						branch_zaMirth_52 = v55;
					} break;
					case std_maybe_Maybe_1_None: {
						decref(v51);
						bool v57 = false;
						branch_Bool_53 = v57;
						branch_zaMirth_52 = r36;
					} break;
					default: {
						do_panic(str_make("unexpected fallthrough in match\n", 32));
					}
				}
				branch_Bool_45 = branch_Bool_53;
				branch_zaMirth_44 = branch_zaMirth_52;
			} break;
			default: {
				do_panic(str_make("unexpected fallthrough in match\n", 32));
			}
		}
		bool v58 = (branch_Bool_45 && v39);
		incref(MK_std_list_List_1(v40));
		bool v59 = mw_std_list_List_1_emptyzy(v40);
		incref(MK_std_list_List_1(v42));
		bool v60 = mw_std_list_List_1_emptyzy(v42);
		bool v61 = (v59 && v60);
		bool v62 = !v61;
		bool v63 = (v62 && v58);
		v35 = v63;
		v34 = v58;
		v33 = v42;
		v32 = v40;
		r31 = branch_zaMirth_44;
	}
	decref(MK_std_list_List_1(v33));
	decref(MK_std_list_List_1(v32));
	*out_zaMirth_4 = r31;
	return v34;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %r9, %r13
movq %r8, %r14
movl %ecx, %r12d
movq %rdi, -0x38(%rbp)
leaq -0x90(%rbp), %rax
movl %esi, %edi
movq %rdx, %rsi
movq %rax, %rdx
callq 0x111eb
movl %eax, %r15d
movq %rdx, %rbx
leaq -0x80(%rbp), %rdx
movl %r12d, %edi
movq %r14, %rsi
callq 0x111eb
cmpl $0x1, %eax
je 0x8da2f
testl %eax, %eax
jne 0x8dd52
movl %r15d, %r14d
movq %rbx, %rax
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
andq %r15, %rax
sete %cl
testb $0x3, %bl
setne %dl
orb %cl, %dl
jne 0x8da10
decl (%rax)
jne 0x8da10
movq %r14, %rdi
shlq $0x30, %rdi
orq %rbx, %rdi
leaq 0x838b6(%rip), %rsi     # 0x1112c1
callq 0xd13d
leaq 0x1(,%r14,2), %rdi
movl $0x1, %esi
callq 0xe83a
testl %eax, %eax
sete %al
movl %eax, -0x2c(%rbp)
jmp 0x8dac1
movq %rdx, %rdi
callq 0xd745
movq %rax, %r14
testl %r15d, %r15d
je 0x8da73
cmpl $0x1, %r15d
jne 0x8dd52
movq %rbx, %rdi
callq 0xd745
leaq -0x58(%rbp), %rbx
movq -0x38(%rbp), %rdi
movq %rax, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x8dd82
movl %eax, -0x2c(%rbp)
movq (%rbx), %rax
movq %rax, -0x38(%rbp)
jmp 0x8da7f
testb $0x1, %dl
jne 0x8da8b
movl $0x0, -0x2c(%rbp)
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
jmp 0x8dac1
movq %r14, %rax
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
andq %r15, %rax
sete %cl
testb $0x3, %r14b
setne %sil
orb %cl, %sil
jne 0x8daba
decl (%rax)
jne 0x8daba
movq %r14, %rdi
movq %rdx, %rsi
callq 0xd13d
movl $0x0, -0x2c(%rbp)
movq %r13, -0x48(%rbp)
movl -0x90(%rbp), %edi
movq -0x88(%rbp), %r14
movq %r14, %rax
andq %r15, %rax
sete %cl
testb $0x3, %r14b
setne %dl
orb %cl, %dl
jne 0x8dae8
incl (%rax)
movq %rdi, -0x40(%rbp)
movq %r14, %rsi
callq 0xf421
movl %eax, %r15d
movl -0x80(%rbp), %r13d
movq -0x78(%rbp), %rbx
movq %rbx, %r12
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq %rax, %r12
sete %al
testb $0x3, %bl
setne %cl
orb %al, %cl
jne 0x8db20
incl (%r12)
movl %r13d, %edi
movq %rbx, %rsi
callq 0xf421
andb %al, %r15b
xorb $0x1, %r15b
movl -0x2c(%rbp), %edx
andb %dl, %r15b
cmpb $0x1, %r15b
jne 0x8dcd0
movq -0x40(%rbp), %rdi
movq %r14, %rsi
leaq -0x58(%rbp), %rdx
callq 0x111eb
movl %eax, %r15d
movq %rdx, %r14
movl %r13d, %edi
movq %rbx, %rsi
leaq -0x70(%rbp), %rdx
callq 0x111eb
cmpl $0x1, %eax
je 0x8dbce
testl %eax, %eax
jne 0x8dd52
movl %r15d, %ebx
movq %r14, %rax
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
andq %r15, %rax
sete %cl
testb $0x3, %r14b
setne %dl
orb %cl, %dl
jne 0x8dbaf
decl (%rax)
jne 0x8dbaf
movq %rbx, %rdi
shlq $0x30, %rdi
orq %r14, %rdi
leaq 0x83717(%rip), %rsi     # 0x1112c1
callq 0xd13d
leaq 0x1(,%rbx,2), %rdi
movl $0x1, %esi
callq 0xe83a
testl %eax, %eax
sete %al
movl %eax, -0x2c(%rbp)
jmp 0x8dc5d
movq %rdx, %rdi
callq 0xd745
movq %rax, %rbx
testl %r15d, %r15d
je 0x8dc10
cmpl $0x1, %r15d
jne 0x8dd52
movq %r14, %rdi
callq 0xd745
movq -0x38(%rbp), %rdi
movq %rax, %rsi
movq %rbx, %rdx
leaq -0x60(%rbp), %rcx
callq 0x8dd82
movl %eax, -0x2c(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x8dc1c
testb $0x1, %dl
jne 0x8dc28
movl $0x0, -0x2c(%rbp)
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
jmp 0x8dc5d
movq %rbx, %rax
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
andq %r15, %rax
sete %cl
testb $0x3, %bl
setne %sil
orb %cl, %sil
jne 0x8dc56
decl (%rax)
jne 0x8dc56
movq %rbx, %rdi
movq %rdx, %rsi
callq 0xd13d
movl $0x0, -0x2c(%rbp)
movl -0x58(%rbp), %edi
movq -0x50(%rbp), %r14
movq %r14, %rax
andq %r15, %rax
sete %cl
testb $0x3, %r14b
setne %dl
orb %cl, %dl
jne 0x8dc7a
incl (%rax)
movq %rdi, -0x40(%rbp)
movq %r14, %rsi
callq 0xf421
movl %eax, %r15d
movl -0x70(%rbp), %r13d
movq -0x68(%rbp), %rbx
movq %rbx, %r12
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq %rax, %r12
sete %al
testb $0x3, %bl
setne %cl
orb %al, %cl
jne 0x8dcb2
incl (%r12)
movl %r13d, %edi
movq %rbx, %rsi
callq 0xf421
andb %al, %r15b
xorb $0x1, %r15b
movl -0x2c(%rbp), %edx
testb %dl, %r15b
jne 0x8db42
leaq 0x835a2(%rip), %rsi     # 0x111279
testq %r12, %r12
movabsq $0xfffffffffffc, %r15   # imm = 0xFFFFFFFFFFFC
je 0x8dd0c
movl %ebx, %eax
andl $0x3, %eax
jne 0x8dd0c
decl (%r12)
jne 0x8dd0c
shlq $0x30, %r13
orq %rbx, %r13
movq %r13, %rdi
movq %rsi, %r12
movl %edx, %ebx
callq 0xd13d
movq %r12, %rsi
movl %ebx, %edx
andq %r14, %r15
sete %al
testb $0x3, %r14b
setne %cl
orb %al, %cl
jne 0x8dd36
decl (%r15)
jne 0x8dd36
movq -0x40(%rbp), %rdi
shlq $0x30, %rdi
orq %r14, %rdi
movl %edx, %ebx
callq 0xd13d
movl %ebx, %edx
movq -0x48(%rbp), %rax
movq -0x38(%rbp), %rcx
movq %rcx, (%rax)
movl %edx, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x20, %edi
callq 0xf5e4
movq $0x20, 0x10(%rax)
movups 0x52962(%rip), %xmm0    # 0xe06cd
movups %xmm0, 0x18(%rax)
movups 0x52967(%rip), %xmm0    # 0xe06dd
movups %xmm0, 0x28(%rax)
movq %rax, %rdi
callq 0x9302