	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dgram_read
_dgram_read:                            ## @dgram_read
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	8(%rdi), %rbx
	movl	$4, -52(%rbp)
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	movq	%rdi, %r15
	movl	%edx, -48(%rbp)                 ## 4-byte Spill
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_clear_socket_error
	leaq	-44(%rbp), %rdi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	movq	%r15, %rdi
	callq	_dgram_adjust_rcv_timeout
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	cmpq	$0, 8(%rbx)
	je	LBB0_4
## %bb.3:
	movq	_MSG_PEEK@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_4:
	movl	(%r15), %r13d
	leaq	-44(%rbp), %rdi
	callq	_BIO_ADDR_sockaddr_noconst
	leaq	-52(%rbp), %r9
	movl	%r13d, %edi
	movq	%r14, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	%r12d, %ecx
	movl	%eax, %r8d
	callq	_recvfrom
	movl	%eax, %r14d
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	cmpl	$0, 4(%rbx)
	jne	LBB0_7
## %bb.5:
	testl	%r14d, %r14d
	js	LBB0_7
## %bb.6:
	movq	_BIO_CTRL_DGRAM_SET_PEER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rcx
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_BIO_ctrl
	movq	%r15, %rdi
	callq	_BIO_clear_retry_flags
	jmp	LBB0_10
LBB0_1:
	xorl	%r14d, %r14d
	jmp	LBB0_11
LBB0_7:
	movq	%r15, %rdi
	callq	_BIO_clear_retry_flags
	testl	%r14d, %r14d
	jns	LBB0_10
## %bb.8:
	movl	%r14d, %edi
	callq	_BIO_dgram_should_retry
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movq	%r15, %rdi
	callq	_BIO_set_retry_read
	xorl	%eax, %eax
	callq	_get_last_socket_error
	movl	%eax, (%rbx)
LBB0_10:
	movq	%r15, %rdi
	callq	_dgram_reset_rcv_timeout
LBB0_11:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MSG_PEEK,4,2                   ## @MSG_PEEK
	.comm	_BIO_CTRL_DGRAM_SET_PEER,4,2    ## @BIO_CTRL_DGRAM_SET_PEER
	.no_dead_strip	_dgram_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dgram_read
_dgram_read:                            ; @dgram_read
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	ldr	x24, [x0, #8]
	mov	w8, #4
	str	w8, [sp, #8]
	cbz	x1, LBB0_4
; %bb.1:
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	bl	_clear_socket_error
	add	x0, sp, #12
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	mov	x0, x19
	bl	_dgram_adjust_rcv_timeout
	ldr	x8, [x24, #8]
Lloh0:
	adrp	x9, _MSG_PEEK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MSG_PEEK@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	cmp	x8, #0
	csel	w22, wzr, w9, eq
	ldr	w23, [x19]
	add	x0, sp, #12
	bl	_BIO_ADDR_sockaddr_noconst
	mov	x4, x0
	add	x5, sp, #8
	mov	x0, x23
	mov	x1, x21
	mov	x2, x20
	mov	x3, x22
	bl	_recvfrom
	mov	x20, x0
	ldr	w8, [x24, #4]
	cbnz	w8, LBB0_5
; %bb.2:
	tbnz	w20, #31, LBB0_5
; %bb.3:
Lloh3:
	adrp	x8, _BIO_CTRL_DGRAM_SET_PEER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BIO_CTRL_DGRAM_SET_PEER@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #0
	bl	_BIO_ctrl
	mov	x0, x19
	bl	_BIO_clear_retry_flags
	b	LBB0_8
LBB0_4:
	mov	w20, #0
	b	LBB0_9
LBB0_5:
	mov	x0, x19
	bl	_BIO_clear_retry_flags
	tbz	w20, #31, LBB0_8
; %bb.6:
	mov	x0, x20
	bl	_BIO_dgram_should_retry
	cbz	x0, LBB0_8
; %bb.7:
	mov	x0, x19
	bl	_BIO_set_retry_read
	bl	_get_last_socket_error
	str	w0, [x24]
LBB0_8:
	mov	x0, x19
	bl	_dgram_reset_rcv_timeout
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_MSG_PEEK,4,2                   ; @MSG_PEEK
	.comm	_BIO_CTRL_DGRAM_SET_PEER,4,2    ; @BIO_CTRL_DGRAM_SET_PEER
	.no_dead_strip	_dgram_read
.subsections_via_symbols
