	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function find_channel_with_pending_x_on
_find_channel_with_pending_x_on:        ## @find_channel_with_pending_x_on
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	(%rdi), %rdi
	callq	_ARRAY_SIZE
	movl	%eax, %ecx
	movq	8(%r14), %rdx
	movq	_MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%eax, %eax
	testl	%esi, (%rdx)
	je	LBB0_14
## %bb.1:
	movl	8(%r15), %r8d
	cmpl	%ecx, %r8d
	jge	LBB0_2
## %bb.3:
	cmpl	%ecx, %r8d
	jl	LBB0_4
	jmp	LBB0_8
LBB0_2:
	movl	$1, 8(%r15)
	movl	$1, %r8d
	cmpl	%ecx, %r8d
	jge	LBB0_8
LBB0_4:
	movq	(%r15), %r9
	movq	_N_XON_REQ@GOTPCREL(%rip), %rdx
	movl	(%rdx), %esi
	movslq	%r8d, %rdx
	subl	%r8d, %ecx
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	incq	%rdx
	decl	%ecx
	je	LBB0_8
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	testl	%esi, (%r9,%rdx,4)
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	(%r14), %rbx
	movq	16(%r15), %rdi
	cmpq	(%rdi,%rdx,8), %rbx
	jne	LBB0_7
	jmp	LBB0_13
LBB0_8:
	cmpl	$2, %r8d
	jl	LBB0_14
## %bb.9:
	movq	(%r15), %r9
	movq	_N_XON_REQ@GOTPCREL(%rip), %rdx
	movl	(%rdx), %esi
	movl	%r8d, %edi
	movl	$1, %edx
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_10 Depth=1
	incq	%rdx
	cmpq	%rdx, %rdi
	je	LBB0_14
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	testl	%esi, (%r9,%rdx,4)
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	(%r14), %rbx
	movq	16(%r15), %rcx
	cmpq	(%rcx,%rdx,8), %rbx
	jne	LBB0_12
LBB0_13:
	leal	1(%rdx), %eax
	movl	%eax, 8(%r15)
	movl	%edx, %eax
LBB0_14:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL,4,2 ## @MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL
	.comm	_N_XON_REQ,4,2                  ## @N_XON_REQ
	.no_dead_strip	_find_channel_with_pending_x_on
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function find_channel_with_pending_x_on
_find_channel_with_pending_x_on:        ; @find_channel_with_pending_x_on
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
	mov	x19, x0
	ldr	x0, [x0]
	bl	_ARRAY_SIZE
	ldr	x9, [x20, #8]
	ldr	w9, [x9]
Lloh0:
	adrp	x10, _MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL@GOTPAGE
Lloh1:
	ldr	x10, [x10, _MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_14
; %bb.1:
	mov	x8, x0
	ldr	w9, [x19, #8]
	cmp	w9, w0
	b.lt	LBB0_3
; %bb.2:
	mov	w9, #1
	str	w9, [x19, #8]
LBB0_3:
	cmp	w9, w8
	b.ge	LBB0_8
; %bb.4:
	ldr	x10, [x19]
Lloh3:
	adrp	x11, _N_XON_REQ@GOTPAGE
Lloh4:
	ldr	x11, [x11, _N_XON_REQ@GOTPAGEOFF]
Lloh5:
	ldr	w11, [x11]
	sxtw	x0, w9
	sub	w8, w8, w9
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x0, x0, #1
	subs	w8, w8, #1
	b.eq	LBB0_8
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x10, x0, lsl #2]
	tst	w11, w12
	b.eq	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x12, [x20]
	ldr	x13, [x19, #16]
	ldr	x13, [x13, x0, lsl #3]
	cmp	x12, x13
	b.ne	LBB0_5
	b	LBB0_13
LBB0_8:
	cmp	w9, #2
	b.lt	LBB0_14
; %bb.9:
	ldr	x8, [x19]
Lloh6:
	adrp	x10, _N_XON_REQ@GOTPAGE
Lloh7:
	ldr	x10, [x10, _N_XON_REQ@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	mov	w9, w9
	mov	w0, #1
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x0, x0, #1
	cmp	x9, x0
	b.eq	LBB0_14
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x8, x0, lsl #2]
	tst	w10, w11
	b.eq	LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x11, [x20]
	ldr	x12, [x19, #16]
	ldr	x12, [x12, x0, lsl #3]
	cmp	x11, x12
	b.ne	LBB0_10
LBB0_13:
	add	w8, w0, #1
	str	w8, [x19, #8]
	b	LBB0_15
LBB0_14:
	mov	w0, #0
LBB0_15:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL,4,2 ; @MANUFACTURER_FEATURE_XONOFF_FLOW_CONTROL
	.comm	_N_XON_REQ,4,2                  ; @N_XON_REQ
	.no_dead_strip	_find_channel_with_pending_x_on
.subsections_via_symbols
