	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wi_on_recv                     ## -- Begin function wi_on_recv
	.p2align	4, 0x90
_wi_on_recv:                            ## @wi_on_recv
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testl	%edx, %edx
	js	LBB0_1
## %bb.2:
	je	LBB0_3
## %bb.6:
	movl	%edx, %ebx
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	8(%rdi), %r12
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdx
	movl	%ebx, %ecx
	callq	_wi_on_debug
	movl	(%r12), %edi
	movq	%r15, %rsi
	movl	%ebx, %edx
	callq	_cb_begin_input
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	(%r14), %rax
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_8
LBB0_1:
	movq	_WI_ERROR@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_3:
	movq	_WI_SUCCESS@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %ebx
LBB0_5:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	%r14, %rdi
	callq	_wi_recv_loop
	movl	%eax, %ebx
	movl	(%r12), %edi
	callq	_cb_end_input
	testq	%rax, %rax
	je	LBB0_5
## %bb.10:
	movq	(%r14), %rax
	leaq	L_.str.2(%rip), %rsi
LBB0_8:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_WI_ERROR,4,2                   ## @WI_ERROR
	.comm	_WI_SUCCESS,4,2                 ## @WI_SUCCESS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"wi.recv"

L_.str.1:                               ## @.str.1
	.asciz	"begin_input buffer error"

L_.str.2:                               ## @.str.2
	.asciz	"end_input buffer error"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wi_on_recv                     ; -- Begin function wi_on_recv
	.p2align	2
_wi_on_recv:                            ; @wi_on_recv
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	tbnz	w2, #31, LBB0_4
; %bb.1:
	mov	x20, x2
	cbz	w2, LBB0_5
; %bb.2:
	mov	x21, x1
	mov	x19, x0
	ldr	x22, [x0, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x21
	mov	x3, x20
	bl	_wi_on_debug
	ldr	w0, [x22]
	mov	x1, x21
	mov	x2, x20
	bl	_cb_begin_input
	cbz	x0, LBB0_8
; %bb.3:
	ldr	x2, [x19]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_10
LBB0_4:
Lloh4:
	adrp	x8, _WI_ERROR@GOTPAGE
Lloh5:
	ldr	x8, [x8, _WI_ERROR@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:
Lloh6:
	adrp	x8, _WI_SUCCESS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _WI_SUCCESS@GOTPAGEOFF]
LBB0_6:
	ldr	w20, [x8]
LBB0_7:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_8:
	mov	x0, x19
	bl	_wi_recv_loop
	mov	x20, x0
	ldr	w0, [x22]
	bl	_cb_end_input
	cbz	x0, LBB0_7
; %bb.9:
	ldr	x2, [x19]
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_10:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	br	x2
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_WI_ERROR,4,2                   ; @WI_ERROR
	.comm	_WI_SUCCESS,4,2                 ; @WI_SUCCESS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"wi.recv"

l_.str.1:                               ; @.str.1
	.asciz	"begin_input buffer error"

l_.str.2:                               ; @.str.2
	.asciz	"end_input buffer error"

.subsections_via_symbols
