	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function iguanair_tx
_iguanair_tx:                           ## @iguanair_tx
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movq	%rsi, %r12
	movq	(%rdi), %r13
	leaq	12(%r13), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	testl	%ebx, %ebx
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	je	LBB0_1
## %bb.2:
	movl	%ebx, %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	xorl	%r15d, %r15d
	xorl	%ebx, %ebx
	movq	%r12, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%r15
	cmpq	-72(%rbp), %r15                 ## 8-byte Folded Reload
	je	LBB0_10
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_5 Depth 2
	movl	(%r13), %edi
	imull	(%r12,%r15,4), %edi
	movl	$1000000, %esi                  ## imm = 0xF4240
	callq	_DIV_ROUND_CLOSEST
	testl	%eax, %eax
	je	LBB0_9
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	%eax, %r14d
	movl	%r15d, %eax
	shll	$7, %eax
	movzbl	%al, %r12d
	movl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%r14d, %edi
	movl	$127, %esi
	callq	_min
	movl	4(%r13), %ecx
	cmpq	%rcx, %rbx
	jae	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=2
	movl	%eax, %ecx
	orl	%r12d, %ecx
	movq	16(%r13), %rdx
	movq	(%rdx), %rdx
	movl	%ecx, (%rdx,%rbx,4)
	incq	%rbx
	subl	%eax, %r14d
	jne	LBB0_5
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	jmp	LBB0_9
LBB0_6:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_14:
	movl	(%rax), %ebx
	callq	_mutex_unlock
	testl	%ebx, %ebx
	je	LBB0_17
## %bb.15:
	negl	%ebx
	movl	%ebx, %eax
	jmp	LBB0_18
LBB0_1:
	xorl	%ebx, %ebx
LBB0_10:
	movq	16(%r13), %rax
	movq	$0, 24(%rax)
	movq	_DIR_OUT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 20(%rax)
	movq	_CMD_SEND@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 16(%rax)
	movl	%ebx, 8(%rax)
	movl	$0, 8(%r13)
	addl	$32, %ebx
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_iguanair_send
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	movl	%eax, %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_mutex_unlock
	movl	%ebx, %eax
	jmp	LBB0_18
LBB0_12:
	cmpl	$0, 8(%r13)
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	je	LBB0_16
## %bb.13:
	movq	_EOVERFLOW@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_16:
	callq	_mutex_unlock
LBB0_17:
	movl	-52(%rbp), %eax                 ## 4-byte Reload
LBB0_18:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_DIR_OUT,4,2                    ## @DIR_OUT
	.comm	_CMD_SEND,4,2                   ## @CMD_SEND
	.comm	_EOVERFLOW,4,2                  ## @EOVERFLOW
	.no_dead_strip	_iguanair_tx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function iguanair_tx
_iguanair_tx:                           ; @iguanair_tx
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x2
	mov	x22, x1
	ldr	x21, [x0]
	add	x20, x21, #12
	mov	x0, x20
	bl	_mutex_lock
	cbz	w19, LBB0_10
; %bb.1:
	mov	x25, #0
	mov	w24, #0
	mov	w27, w19
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x25, x25, #1
	cmp	x25, x27
	b.eq	LBB0_11
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	ldr	w8, [x22, x25, lsl #2]
	ldr	w9, [x21]
	mul	w0, w9, w8
	mov	w1, #16960
	movk	w1, #15, lsl #16
	bl	_DIV_ROUND_CLOSEST
	cbz	w0, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x23, x0
	ubfiz	w28, w25, #7, #1
	mov	w26, w24
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x0, x23
	mov	w1, #127
	bl	_min
	ldr	w8, [x21, #4]
	cmp	x26, x8
	b.hs	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=2
	orr	w8, w0, w28
	ldr	x9, [x21, #16]
	ldr	x9, [x9]
	add	x24, x26, #1
	str	w8, [x9, x26, lsl #2]
	mov	x26, x24
	subs	w23, w23, w0
	b.ne	LBB0_5
	b	LBB0_2
LBB0_7:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_8:
	ldr	w21, [x8]
	mov	x0, x20
	bl	_mutex_unlock
	cbz	w21, LBB0_13
; %bb.9:
	neg	w19, w21
	b	LBB0_13
LBB0_10:
	mov	w24, #0
LBB0_11:
	ldr	x8, [x21, #16]
	str	xzr, [x8, #24]
Lloh2:
	adrp	x9, _DIR_OUT@GOTPAGE
Lloh3:
	ldr	x9, [x9, _DIR_OUT@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
Lloh5:
	adrp	x10, _CMD_SEND@GOTPAGE
Lloh6:
	ldr	x10, [x10, _CMD_SEND@GOTPAGEOFF]
Lloh7:
	ldr	w10, [x10]
	stp	w10, w9, [x8, #16]
	str	w24, [x8, #8]
	str	wzr, [x21, #8]
	add	w1, w24, #32
	mov	x0, x21
	bl	_iguanair_send
	cbz	w0, LBB0_14
; %bb.12:
	mov	x22, x0
	mov	x0, x20
	bl	_mutex_unlock
	mov	x19, x22
LBB0_13:
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_14:
	ldr	w8, [x21, #8]
	cbz	w8, LBB0_16
; %bb.15:
Lloh8:
	adrp	x8, _EOVERFLOW@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EOVERFLOW@GOTPAGEOFF]
	b	LBB0_8
LBB0_16:
	mov	x0, x20
	bl	_mutex_unlock
	b	LBB0_13
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_DIR_OUT,4,2                    ; @DIR_OUT
	.comm	_CMD_SEND,4,2                   ; @CMD_SEND
	.comm	_EOVERFLOW,4,2                  ; @EOVERFLOW
	.no_dead_strip	_iguanair_tx
.subsections_via_symbols
