	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_channel_output_poll            ## -- Begin function channel_output_poll
	.p2align	4, 0x90
_channel_output_poll:                   ## @channel_output_poll
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %r12
	cmpq	$0, (%r12)
	je	LBB0_13
## %bb.1:
	xorl	%ebx, %ebx
	movq	_SSH_CHANNEL_OPEN@GOTPCREL(%rip), %r14
	movq	_CHAN_CLOSE_RCVD@GOTPCREL(%rip), %r15
	jmp	LBB0_2
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	32(%r13), %esi
	leaq	L_.str(%rip), %rdi
	callq	_debug3
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	incq	%rbx
	cmpq	(%r12), %rbx
	jae	LBB0_13
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r12), %rax
	movq	(%rax,%rbx,8), %r13
	testq	%r13, %r13
	je	LBB0_12
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%r13), %rax
	cmpq	(%r14), %rax
	jne	LBB0_12
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	8(%r13), %eax
	movl	(%r15), %ecx
	movq	_CHAN_CLOSE_SENT@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	testl	%eax, %ecx
	jne	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	16(%r13), %rcx
	movq	_CHAN_INPUT_OPEN@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_CHAN_INPUT_WAIT_DRAIN@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_9
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	callq	_channel_output_poll_input_open
	movl	8(%r13), %eax
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_CHAN_EOF_SENT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	24(%r13), %rax
	movq	_CHAN_EXTENDED_READ@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	callq	_channel_output_poll_extended_read
	jmp	LBB0_12
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SSH_CHANNEL_OPEN,8,3           ## @SSH_CHANNEL_OPEN
	.comm	_CHAN_CLOSE_SENT,4,2            ## @CHAN_CLOSE_SENT
	.comm	_CHAN_CLOSE_RCVD,4,2            ## @CHAN_CLOSE_RCVD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"channel %d: will not send data after close"

	.comm	_CHAN_INPUT_OPEN,8,3            ## @CHAN_INPUT_OPEN
	.comm	_CHAN_INPUT_WAIT_DRAIN,8,3      ## @CHAN_INPUT_WAIT_DRAIN
	.comm	_CHAN_EOF_SENT,4,2              ## @CHAN_EOF_SENT
	.comm	_CHAN_EXTENDED_READ,8,3         ## @CHAN_EXTENDED_READ
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_channel_output_poll            ; -- Begin function channel_output_poll
	.p2align	2
_channel_output_poll:                   ; @channel_output_poll
	.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
	ldr	x22, [x0]
	ldr	x8, [x22]
	cbz	x8, LBB0_12
; %bb.1:
	mov	x19, x0
	mov	x23, #0
Lloh0:
	adrp	x24, _SSH_CHANNEL_OPEN@GOTPAGE
Lloh1:
	ldr	x24, [x24, _SSH_CHANNEL_OPEN@GOTPAGEOFF]
Lloh2:
	adrp	x25, _CHAN_CLOSE_SENT@GOTPAGE
Lloh3:
	ldr	x25, [x25, _CHAN_CLOSE_SENT@GOTPAGEOFF]
Lloh4:
	adrp	x26, _CHAN_CLOSE_RCVD@GOTPAGE
Lloh5:
	ldr	x26, [x26, _CHAN_CLOSE_RCVD@GOTPAGEOFF]
Lloh6:
	adrp	x28, _CHAN_INPUT_WAIT_DRAIN@GOTPAGE
Lloh7:
	ldr	x28, [x28, _CHAN_INPUT_WAIT_DRAIN@GOTPAGEOFF]
Lloh8:
	adrp	x27, _CHAN_EOF_SENT@GOTPAGE
Lloh9:
	ldr	x27, [x27, _CHAN_EOF_SENT@GOTPAGEOFF]
Lloh10:
	adrp	x20, l_.str@PAGE
Lloh11:
	add	x20, x20, l_.str@PAGEOFF
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w1, [x21, #32]
	mov	x0, x20
	bl	_debug3
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x23, x23, #1
	ldr	x8, [x22]
	cmp	x23, x8
	b.hs	LBB0_12
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x22, #8]
	ldr	x21, [x8, x23, lsl #3]
	cbz	x21, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x21]
	ldr	x9, [x24]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x21, #8]
	ldr	w9, [x25]
	ldr	w10, [x26]
	orr	w9, w10, w9
	tst	w9, w8
	b.ne	LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x9, [x21, #16]
Lloh12:
	adrp	x10, _CHAN_INPUT_OPEN@GOTPAGE
Lloh13:
	ldr	x10, [x10, _CHAN_INPUT_OPEN@GOTPAGEOFF]
Lloh14:
	ldr	x10, [x10]
	ldr	x11, [x28]
	cmp	x9, x10
	ccmp	x9, x11, #4, ne
	b.ne	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x21
	bl	_channel_output_poll_input_open
	ldr	w8, [x21, #8]
LBB0_9:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w9, [x27]
	tst	w9, w8
	b.ne	LBB0_3
; %bb.10:                               ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x21, #24]
Lloh15:
	adrp	x9, _CHAN_EXTENDED_READ@GOTPAGE
Lloh16:
	ldr	x9, [x9, _CHAN_EXTENDED_READ@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.11:                               ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x21
	bl	_channel_output_poll_extended_read
	b	LBB0_3
LBB0_12:
	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
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_SSH_CHANNEL_OPEN,8,3           ; @SSH_CHANNEL_OPEN
	.comm	_CHAN_CLOSE_SENT,4,2            ; @CHAN_CLOSE_SENT
	.comm	_CHAN_CLOSE_RCVD,4,2            ; @CHAN_CLOSE_RCVD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"channel %d: will not send data after close"

	.comm	_CHAN_INPUT_OPEN,8,3            ; @CHAN_INPUT_OPEN
	.comm	_CHAN_INPUT_WAIT_DRAIN,8,3      ; @CHAN_INPUT_WAIT_DRAIN
	.comm	_CHAN_EOF_SENT,4,2              ; @CHAN_EOF_SENT
	.comm	_CHAN_EXTENDED_READ,8,3         ; @CHAN_EXTENDED_READ
.subsections_via_symbols
