	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dtls1_query_mtu                ## -- Begin function dtls1_query_mtu
	.p2align	4, 0x90
_dtls1_query_mtu:                       ## @dtls1_query_mtu
	.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	%rdi, %r15
	movq	(%rdi), %rax
	movq	(%rax), %rbx
	testq	%rbx, %rbx
	je	LBB0_1
## %bb.2:
	movq	%r15, %rdi
	callq	_SSL_get_wbio
	movl	%eax, %edi
	callq	_BIO_dgram_get_mtu_overhead
	subq	%rax, %rbx
	movq	(%r15), %rax
	movq	%rbx, 8(%rax)
	movq	$0, (%rax)
	jmp	LBB0_3
LBB0_1:
	movq	8(%rax), %rbx
LBB0_3:
	movq	%r15, %rdi
	callq	_dtls1_min_mtu
	cmpq	%rax, %rbx
	jge	LBB0_7
## %bb.4:
	movq	%r15, %rdi
	callq	_SSL_get_options
	movl	%eax, %ecx
	movq	_SSL_OP_NO_QUERY_MTU@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	testl	%ecx, (%rdx)
	jne	LBB0_8
## %bb.5:
	movq	%r15, %rdi
	callq	_SSL_get_wbio
	movq	_BIO_CTRL_DGRAM_QUERY_MTU@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_BIO_ctrl
	movq	%rax, %r14
	movq	(%r15), %rax
	movq	%r14, 8(%rax)
	movq	%r15, %rdi
	callq	_dtls1_min_mtu
	cmpq	%rax, %r14
	jge	LBB0_7
## %bb.6:
	movq	%r15, %rdi
	callq	_dtls1_min_mtu
	movq	(%r15), %rcx
	movq	%rax, 8(%rcx)
	movq	%r15, %rdi
	callq	_SSL_get_wbio
	movq	_BIO_CTRL_DGRAM_SET_MTU@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	(%r15), %rcx
	movq	8(%rcx), %rdx
	movl	%eax, %edi
	xorl	%ecx, %ecx
	callq	_BIO_ctrl
LBB0_7:
	movl	$1, %eax
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SSL_OP_NO_QUERY_MTU,4,2        ## @SSL_OP_NO_QUERY_MTU
	.comm	_BIO_CTRL_DGRAM_QUERY_MTU,4,2   ## @BIO_CTRL_DGRAM_QUERY_MTU
	.comm	_BIO_CTRL_DGRAM_SET_MTU,4,2     ## @BIO_CTRL_DGRAM_SET_MTU
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dtls1_query_mtu                ; -- Begin function dtls1_query_mtu
	.p2align	2
_dtls1_query_mtu:                       ; @dtls1_query_mtu
	.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	x19, x0
	ldr	x8, [x0]
	ldr	x20, [x8]
	cbz	x20, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_SSL_get_wbio
	bl	_BIO_dgram_get_mtu_overhead
	ldr	x8, [x19]
	sub	x20, x20, x0
	stp	xzr, x20, [x8]
	b	LBB0_3
LBB0_2:
	ldr	x20, [x8, #8]
LBB0_3:
	mov	x0, x19
	bl	_dtls1_min_mtu
	cmp	x20, x0
	b.ge	LBB0_8
; %bb.4:
	mov	x0, x19
	bl	_SSL_get_options
Lloh0:
	adrp	x8, _SSL_OP_NO_QUERY_MTU@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SSL_OP_NO_QUERY_MTU@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_6
; %bb.5:
	mov	w0, #0
	b	LBB0_9
LBB0_6:
	mov	x0, x19
	bl	_SSL_get_wbio
Lloh3:
	adrp	x8, _BIO_CTRL_DGRAM_QUERY_MTU@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BIO_CTRL_DGRAM_QUERY_MTU@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x2, #0
	mov	x3, #0
	bl	_BIO_ctrl
	mov	x20, x0
	ldr	x8, [x19]
	str	x0, [x8, #8]
	mov	x0, x19
	bl	_dtls1_min_mtu
	cmp	x20, x0
	b.ge	LBB0_8
; %bb.7:
	mov	x0, x19
	bl	_dtls1_min_mtu
	ldr	x8, [x19]
	str	x0, [x8, #8]
	mov	x0, x19
	bl	_SSL_get_wbio
Lloh6:
	adrp	x8, _BIO_CTRL_DGRAM_SET_MTU@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BIO_CTRL_DGRAM_SET_MTU@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	x8, [x19]
	ldr	x2, [x8, #8]
	mov	x3, #0
	bl	_BIO_ctrl
LBB0_8:
	mov	w0, #1
LBB0_9:
	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	_SSL_OP_NO_QUERY_MTU,4,2        ; @SSL_OP_NO_QUERY_MTU
	.comm	_BIO_CTRL_DGRAM_QUERY_MTU,4,2   ; @BIO_CTRL_DGRAM_QUERY_MTU
	.comm	_BIO_CTRL_DGRAM_SET_MTU,4,2     ; @BIO_CTRL_DGRAM_SET_MTU
.subsections_via_symbols
