// File: /workspace/github_c_makefile_star2_O3/mirth-lang[P]mirth/bin/mirth1.c
// Function: mw_mirth_data_Tag_numzeresourcezeinputszefromzesig
static INT mw_mirth_data_Tag_numzeresourcezeinputszefromzesig (struct mirth_mirth_zaMirth* in_zaMirth_1, uint64_t in_Tag_2, struct mirth_mirth_zaMirth* *out_zaMirth_3) {
	struct mirth_mirth_zaMirth* v5;
	struct std_maybe_Maybe_1 v6 = mw_mirth_data_Tag_sigzy(in_zaMirth_1, in_Tag_2, &v5);
	struct mirth_mirth_zaMirth* branch_zaMirth_7;
	INT branch_Nat_8;
	switch ((v6).tag) {
		case std_maybe_Maybe_1_Some: {
			VAL v9 = mtp_std_maybe_Maybe_1_Some(v6);
			struct mirth_mirth_zaMirth* v10;
			struct std_list_List_1 v11 = mw_mirth_token_Token_sigzestackzetokens(v5, V_mirth_token_Token(v9), &v10);
			struct std_list_List_1 v12 = { .tag=std_list_List_1_Nil };
			struct std_list_List_1 v13;
			mw_std_list_List_1_buildzx(v12, &v13);
			bool v14 = true;
			struct mirth_mirth_zaMirth* r15 = v10;
			struct std_list_List_1 r16 = v13;
			struct std_list_List_1 v17 = v11;
			bool v18 = v14;
			bool v19 = v14;
			while (v19) {
				struct mirth_mirth_zaMirth* r20 = r15;
				struct std_list_List_1 r21 = r16;
				struct std_list_List_1 v22 = v17;
				bool v23 = v18;
				struct mirth_mirth_zaMirth* branch_zaMirth_24;
				struct std_list_List_1 branch_zaLister_25;
				struct std_list_List_1 branch_List_26;
				bool branch_Bool_27;
				switch ((v22).tag) {
					case std_list_List_1_Cons: {
						struct std_list_List_1 v28;
						VAL v29 = mtp_std_list_List_1_Cons(v22, &v28);
						incref(v29);
						struct mirth_mirth_zaMirth* v30;
						bool v31 = mw_mirth_token_Token_couldzebezesigzelabelzy(r20, V_mirth_token_Token(v29), &v30);
						bool v32 = !v31;
						struct mirth_mirth_zaMirth* branch_zaMirth_33;
						struct std_list_List_1 branch_zaLister_34;
						if (v32) {
							struct std_list_List_1 v35;
							mw_std_list_zaLister_1_pushzx(v29, r21, &v35);
							branch_zaLister_34 = v35;
							branch_zaMirth_33 = v30;
						} else {
							decref(v29);
							branch_zaLister_34 = r21;
							branch_zaMirth_33 = v30;
						}
						bool v36 = true;
						branch_Bool_27 = v36;
						branch_List_26 = v28;
						branch_zaLister_25 = branch_zaLister_34;
						branch_zaMirth_24 = branch_zaMirth_33;
					} break;
					case std_list_List_1_Nil: {
						struct std_list_List_1 v37 = { .tag=std_list_List_1_Nil };
						bool v38 = false;
						branch_Bool_27 = v38;
						branch_List_26 = v37;
						branch_zaLister_25 = r21;
						branch_zaMirth_24 = r20;
					} break;
					default: {
						do_panic(str_make("unexpected fallthrough in match\n", 32));
					}
				}
				v19 = branch_Bool_27;
				v18 = branch_Bool_27;
				v17 = branch_List_26;
				r16 = branch_zaLister_25;
				r15 = branch_zaMirth_24;
			}
			decref(MK_std_list_List_1(v17));
			struct std_list_List_1 v39 = mw_std_list_zaLister_1_donezx(r16);
			struct std_list_List_1 v40 = { .tag=std_list_List_1_Nil };
			struct std_list_List_1 v41;
			mw_std_list_List_1_buildzx(v40, &v41);
			bool v42 = true;
			struct mirth_mirth_zaMirth* r43 = r15;
			struct std_list_List_1 r44 = v41;
			struct std_list_List_1 v45 = v39;
			bool v46 = v42;
			bool v47 = v42;
			while (v47) {
				struct mirth_mirth_zaMirth* r48 = r43;
				struct std_list_List_1 r49 = r44;
				struct std_list_List_1 v50 = v45;
				bool v51 = v46;
				struct mirth_mirth_zaMirth* branch_zaMirth_52;
				struct std_list_List_1 branch_zaLister_53;
				struct std_list_List_1 branch_List_54;
				bool branch_Bool_55;
				switch ((v50).tag) {
					case std_list_List_1_Cons: {
						struct std_list_List_1 v56;
						VAL v57 = mtp_std_list_List_1_Cons(v50, &v56);
						struct mirth_mirth_zaMirth* v58;
						struct std_maybe_Maybe_1 v59 = mw_mirth_token_Token_lastzenamezy(r48, V_mirth_token_Token(v57), &v58);
						struct std_list_List_1 v60;
						mw_std_maybe_Maybe_1_for_1_sp2(r49, v59, &v60);
						bool v61 = true;
						branch_Bool_55 = v61;
						branch_List_54 = v56;
						branch_zaLister_53 = v60;
						branch_zaMirth_52 = v58;
					} break;
					case std_list_List_1_Nil: {
						struct std_list_List_1 v62 = { .tag=std_list_List_1_Nil };
						bool v63 = false;
						branch_Bool_55 = v63;
						branch_List_54 = v62;
						branch_zaLister_53 = r49;
						branch_zaMirth_52 = r48;
					} break;
					default: {
						do_panic(str_make("unexpected fallthrough in match\n", 32));
					}
				}
				v47 = branch_Bool_55;
				v46 = branch_Bool_55;
				v45 = branch_List_54;
				r44 = branch_zaLister_53;
				r43 = branch_zaMirth_52;
			}
			decref(MK_std_list_List_1(v45));
			struct std_list_List_1 v64 = mw_std_list_zaLister_1_donezx(r44);
			struct std_list_List_1 v65 = { .tag=std_list_List_1_Nil };
			struct std_list_List_1 v66;
			mw_std_list_List_1_buildzx(v65, &v66);
			bool v67 = true;
			struct mirth_mirth_zaMirth* r68 = r43;
			struct std_list_List_1 r69 = v66;
			struct std_list_List_1 v70 = v64;
			bool v71 = v67;
			bool v72 = v67;
			while (v72) {
				struct mirth_mirth_zaMirth* r73 = r68;
				struct std_list_List_1 r74 = r69;
				struct std_list_List_1 v75 = v70;
				bool v76 = v71;
				struct mirth_mirth_zaMirth* branch_zaMirth_77;
				struct std_list_List_1 branch_zaLister_78;
				struct std_list_List_1 branch_List_79;
				bool branch_Bool_80;
				switch ((v75).tag) {
					case std_list_List_1_Cons: {
						struct std_list_List_1 v81;
						VAL v82 = mtp_std_list_List_1_Cons(v75, &v81);
						incref(v82);
						incref(v82);
						struct mirth_mirth_zaMirth* v83;
						bool v84 = mw_mirth_name_Name_couldzebezeresourcezevar(r73, V_mirth_name_Name(v82), &v83);
						struct mirth_mirth_zaMirth* branch_zaMirth_85;
						bool branch_Bool_86;
						if (v84) {
							decref(v82);
							bool v87 = true;
							branch_Bool_86 = v87;
							branch_zaMirth_85 = v83;
						} else {
							struct mirth_mirth_zaMirth* v88;
							bool v89 = mw_mirth_name_Name_couldzebezeresourcezecon(v83, V_mirth_name_Name(v82), &v88);
							branch_Bool_86 = v89;
							branch_zaMirth_85 = v88;
						}
						struct mirth_mirth_zaMirth* branch_zaMirth_90;
						struct std_list_List_1 branch_zaLister_91;
						if (branch_Bool_86) {
							struct std_list_List_1 v92;
							mw_std_list_zaLister_1_pushzx(v82, r74, &v92);
							branch_zaLister_91 = v92;
							branch_zaMirth_90 = branch_zaMirth_85;
						} else {
							decref(v82);
							branch_zaLister_91 = r74;
							branch_zaMirth_90 = branch_zaMirth_85;
						}
						bool v93 = true;
						branch_Bool_80 = v93;
						branch_List_79 = v81;
						branch_zaLister_78 = branch_zaLister_91;
						branch_zaMirth_77 = branch_zaMirth_90;
					} break;
					case std_list_List_1_Nil: {
						struct std_list_List_1 v94 = { .tag=std_list_List_1_Nil };
						bool v95 = false;
						branch_Bool_80 = v95;
						branch_List_79 = v94;
						branch_zaLister_78 = r74;
						branch_zaMirth_77 = r73;
					} break;
					default: {
						do_panic(str_make("unexpected fallthrough in match\n", 32));
					}
				}
				v72 = branch_Bool_80;
				v71 = branch_Bool_80;
				v70 = branch_List_79;
				r69 = branch_zaLister_78;
				r68 = branch_zaMirth_77;
			}
			decref(MK_std_list_List_1(v70));
			struct std_list_List_1 v96 = mw_std_list_zaLister_1_donezx(r69);
			INT v97 = mw_std_list_List_1_len(v96);
			branch_Nat_8 = v97;
			branch_zaMirth_7 = r68;
		} break;
		case std_maybe_Maybe_1_None: {
			INT v98 = WRAP_I63(0LL);
			branch_Nat_8 = v98;
			branch_zaMirth_7 = v5;
		} break;
		default: {
			do_panic(str_make("unexpected fallthrough in match\n", 32));
		}
	}
	*out_zaMirth_3 = branch_zaMirth_7;
	return branch_Nat_8;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, %rbx
movq %rdi, %r14
leaq 0x109f17b(%rip), %rdi   # 0x1114d20
callq 0x13c85
movq %rax, %rdi
callq 0x13d82
movq %rax, %rdx
shrq $0x30, %rdx
movl $0x1, %ecx
je 0x75f41
movq %rbx, -0x68(%rbp)
cmpl $0x1, %edx
jne 0x75f56
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
movq %rax, %rdi
callq 0xd745
leaq -0x70(%rbp), %r12
movq %r14, %rdi
movq %rax, %rsi
movq %r12, %rdx
callq 0x73af8
movl %eax, %ebx
movq %rdx, %r13
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0xd01b
movl %eax, -0x2c(%rbp)
movq %rdx, %r15
movq (%r12), %r14
leaq -0x38(%rbp), %r12
cmpl $0x1, %ebx
jne 0x75d7c
movq %r13, %rdi
leaq -0x58(%rbp), %rsi
callq 0xd0aa
movq %rax, %rbx
movq %rdx, %r13
testb $0x1, %r13b
je 0x75c58
movq %rbx, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %bl
setne %dl
orb %cl, %dl
jne 0x75c58
incl (%rax)
movq %r14, %rdi
movq %rbx, %rsi
leaq -0x48(%rbp), %rdx
callq 0x30835
cmpl $0x1, %eax
jne 0x75d47
movq %r15, -0x60(%rbp)
movq %rdx, %rdi
callq 0xd745
movq -0x48(%rbp), %rdi
movq %rax, %rsi
movq %r12, %r15
movq %r12, %rdx
callq 0x3ff16
movq -0x38(%rbp), %r14
testb %al, %al
je 0x75d4d
cmpq %rbx, 0x109f757(%rip)   # 0x11153f8
leaq 0x1(%rbx), %rsi
movl $0x0, %eax
cmovbeq %rax, %rsi
movq %r14, %rdi
movq %r15, %rdx
callq 0x3ffe0
movl %eax, %r14d
movq %rdx, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %dl
setne %sil
orb %cl, %sil
jne 0x75cf5
decl (%rax)
jne 0x75cf5
movq %r14, %rdi
shlq $0x30, %rdi
orq %rdx, %rdi
leaq 0x9b5d1(%rip), %rsi     # 0x1112c1
callq 0xd13d
leaq 0x1(,%r14,2), %rdi
movl $0x1, %esi
callq 0xe83a
movq -0x38(%rbp), %r14
testl %eax, %eax
movq -0x60(%rbp), %r15
je 0x75d51
testb $0x1, %r13b
je 0x75d70
movq %rbx, %rax
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq %rcx, %rax
sete %cl
testb $0x3, %bl
setne %dl
orb %cl, %dl
jne 0x75d70
decl (%rax)
jne 0x75d70
movq %rbx, %rdi
movq %r13, %rsi
callq 0xd13d
jmp 0x75d70
movq -0x48(%rbp), %r14
jmp 0x75d51
movq -0x60(%rbp), %r15
movq %rbx, %rdi
movq %r13, %rsi
movl -0x2c(%rbp), %edx
movq %r15, %rcx
leaq -0x48(%rbp), %r8
callq 0x949e
movl -0x48(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x40(%rbp), %r15
movl -0x58(%rbp), %ebx
movq -0x50(%rbp), %r13
jmp 0x75c18
testl %ebx, %ebx
jne 0x75f56
xorl %edi, %edi
xorl %esi, %esi
movl -0x2c(%rbp), %edx
movq %r15, %rcx
callq 0xd01b
movl %eax, %r13d
movq %rdx, %r12
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0xd01b
movl %eax, %r15d
movq %rdx, %rbx
cmpl $0x1, %r13d
jne 0x75df7
movq %r12, %rdi
leaq -0x58(%rbp), %rsi
callq 0xd0aa
movq %r14, %rdi
movq %rax, %rsi
leaq -0x38(%rbp), %rdx
callq 0x70e63
movq %rdx, %rcx
movl %r15d, %edi
movq %rbx, %rsi
movl %eax, %edx
leaq -0x48(%rbp), %r8
callq 0x2f53f
movl -0x58(%rbp), %r13d
movq -0x50(%rbp), %r12
movl -0x48(%rbp), %r15d
movq -0x40(%rbp), %rbx
movq -0x38(%rbp), %r14
jmp 0x75dac
testl %r13d, %r13d
jne 0x75f56
xorl %edi, %edi
xorl %esi, %esi
movl %r15d, %edx
movq %rbx, %rcx
callq 0xd01b
movl %eax, %r12d
movq %rdx, %r13
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0xd01b
movl %eax, -0x2c(%rbp)
movq %rdx, %r15
cmpl $0x1, %r12d
jne 0x75f1c
movq %r13, %rdi
leaq -0x58(%rbp), %rsi
callq 0xd0aa
movq %rax, %rbx
movq %rdx, %r13
testb $0x1, %r13b
je 0x75e92
movq %rbx, %r12
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq %rax, %r12
sete %al
testb $0x3, %bl
setne %cl
orb %al, %cl
jne 0x75e92
addl $0x2, (%r12)
movq %r14, %rdi
movq %rbx, %rsi
leaq -0x38(%rbp), %rdx
callq 0x1eabe
testb %al, %al
je 0x75ec5
decl (%r12)
jne 0x75ea5
movq %rbx, %rdi
movq %r13, %rsi
callq 0xd13d
jmp 0x75ea5
movq %r14, %rdi
movq %rbx, %rsi
leaq -0x38(%rbp), %rdx
callq 0x1eabe
testb %al, %al
je 0x75eab
movq -0x38(%rbp), %r14
jmp 0x75edd
movq -0x38(%rbp), %rdi
movq %rbx, %rsi
leaq -0x48(%rbp), %rdx
callq 0x208a5
movq -0x48(%rbp), %r14
testb %al, %al
jne 0x75edd
jmp 0x75efc
movq -0x38(%rbp), %rdi
movq %rbx, %rsi
leaq -0x48(%rbp), %rdx
callq 0x208a5
movq -0x48(%rbp), %r14
testb %al, %al
je 0x75f09
movq %rbx, %rdi
movq %r13, %rsi
movl -0x2c(%rbp), %edx
movq %r15, %rcx
leaq -0x48(%rbp), %r8
callq 0x949e
movl -0x48(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x40(%rbp), %r15
movl -0x58(%rbp), %r12d
movq -0x50(%rbp), %r13
jmp 0x75e28
decl (%r12)
jne 0x75efc
movq %rbx, %rdi
movq %r13, %rsi
callq 0xd13d
jmp 0x75efc
testl %r12d, %r12d
jne 0x75f56
xorl %edi, %edi
xorl %esi, %esi
movl -0x2c(%rbp), %edx
movq %r15, %rcx
callq 0xd01b
movl %eax, %edi
movq %rdx, %rsi
callq 0x11653
movq %rax, %rcx
movq -0x68(%rbp), %rbx
movq %r14, (%rbx)
movq %rcx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x20, %edi
callq 0xf5e4
movq $0x20, 0x10(%rax)
movups 0x6a75e(%rip), %xmm0    # 0xe06cd
movups %xmm0, 0x18(%rax)
movups 0x6a763(%rip), %xmm0    # 0xe06dd
movups %xmm0, 0x28(%rax)
movq %rax, %rdi
callq 0x9302