	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mbedtls_ssl_resend             ## -- Begin function mbedtls_ssl_resend
	.p2align	4, 0x90
_mbedtls_ssl_resend:                    ## @mbedtls_ssl_resend
	.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, %r15
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	16(%r15), %rax
	movq	(%rax), %rcx
	movq	_MBEDTLS_SSL_RETRANS_SENDING@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rcx
	je	LBB0_2
## %bb.1:
	leaq	L_.str.1(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	16(%r15), %rax
	movq	24(%rax), %rcx
	movq	%rcx, 16(%rax)
	movq	%r15, %rdi
	callq	_ssl_swap_epochs
	movq	(%rbx), %rcx
	movq	16(%r15), %rax
	movq	%rcx, (%rax)
LBB0_2:
	movq	16(%rax), %rbx
	testq	%rbx, %rbx
	je	LBB0_9
## %bb.3:
	movq	_MBEDTLS_SSL_MSG_HANDSHAKE@GOTPCREL(%rip), %r12
	movq	_MBEDTLS_SSL_HS_FINISHED@GOTPCREL(%rip), %r13
	leaq	L_.str.2(%rip), %r14
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rbx), %rax
	cmpq	(%r12), %rax
	jne	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	8(%rbx), %rax
	movq	(%rax), %rax
	cmpq	(%r13), %rax
	jne	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r15, %rdi
	callq	_ssl_swap_epochs
LBB0_7:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	24(%r15), %edi
	movq	8(%rbx), %rsi
	movl	24(%rbx), %edx
	callq	_memcpy
	movl	24(%rbx), %eax
	movl	%eax, 28(%r15)
	movq	(%rbx), %rax
	movq	%rax, (%r15)
	movq	16(%rbx), %rax
	movq	16(%r15), %rcx
	movq	%rax, 16(%rcx)
	movl	24(%r15), %edx
	movl	$3, %edi
	movq	%r14, %rsi
	movl	$12, %ecx
	callq	_MBEDTLS_SSL_DEBUG_BUF
	movq	%r15, %rdi
	callq	_mbedtls_ssl_write_record
	testl	%eax, %eax
	jne	LBB0_14
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	16(%r15), %rax
	movq	16(%rax), %rbx
	testq	%rbx, %rbx
	jne	LBB0_4
LBB0_9:
	movq	8(%r15), %rcx
	movq	_MBEDTLS_SSL_HANDSHAKE_OVER@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_11
## %bb.10:
	movq	_MBEDTLS_SSL_RETRANS_FINISHED@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	jmp	LBB0_12
LBB0_14:
	movl	%eax, %ebx
	leaq	L_.str.3(%rip), %rsi
	movl	$1, %edi
	movl	%eax, %edx
	callq	_MBEDTLS_SSL_DEBUG_RET
	jmp	LBB0_13
LBB0_11:
	movq	_MBEDTLS_SSL_RETRANS_WAITING@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	8(%rax), %esi
	movq	%r15, %rdi
	callq	_ssl_set_timer
LBB0_12:
	leaq	L_.str.4(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	xorl	%ebx, %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"=> mbedtls_ssl_resend"

	.comm	_MBEDTLS_SSL_RETRANS_SENDING,8,3 ## @MBEDTLS_SSL_RETRANS_SENDING
L_.str.1:                               ## @.str.1
	.asciz	"initialise resending"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,8,3  ## @MBEDTLS_SSL_MSG_HANDSHAKE
	.comm	_MBEDTLS_SSL_HS_FINISHED,8,3    ## @MBEDTLS_SSL_HS_FINISHED
L_.str.2:                               ## @.str.2
	.asciz	"resent handshake message header"

L_.str.3:                               ## @.str.3
	.asciz	"mbedtls_ssl_write_record"

	.comm	_MBEDTLS_SSL_HANDSHAKE_OVER,8,3 ## @MBEDTLS_SSL_HANDSHAKE_OVER
	.comm	_MBEDTLS_SSL_RETRANS_FINISHED,8,3 ## @MBEDTLS_SSL_RETRANS_FINISHED
	.comm	_MBEDTLS_SSL_RETRANS_WAITING,8,3 ## @MBEDTLS_SSL_RETRANS_WAITING
L_.str.4:                               ## @.str.4
	.asciz	"<= mbedtls_ssl_resend"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mbedtls_ssl_resend             ; -- Begin function mbedtls_ssl_resend
	.p2align	2
_mbedtls_ssl_resend:                    ; @mbedtls_ssl_resend
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	ldr	x8, [x19, #16]
	ldr	x9, [x8]
Lloh2:
	adrp	x20, _MBEDTLS_SSL_RETRANS_SENDING@GOTPAGE
Lloh3:
	ldr	x20, [x20, _MBEDTLS_SSL_RETRANS_SENDING@GOTPAGEOFF]
	ldr	x10, [x20]
	cmp	x9, x10
	b.eq	LBB0_2
; %bb.1:
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	ldr	x8, [x19, #16]
	ldr	x9, [x8, #24]
	str	x9, [x8, #16]
	mov	x0, x19
	bl	_ssl_swap_epochs
	ldr	x9, [x20]
	ldr	x8, [x19, #16]
	str	x9, [x8]
LBB0_2:
	ldr	x21, [x8, #16]
	cbz	x21, LBB0_9
; %bb.3:
Lloh6:
	adrp	x22, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGE
Lloh7:
	ldr	x22, [x22, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGEOFF]
Lloh8:
	adrp	x23, _MBEDTLS_SSL_HS_FINISHED@GOTPAGE
Lloh9:
	ldr	x23, [x23, _MBEDTLS_SSL_HS_FINISHED@GOTPAGEOFF]
Lloh10:
	adrp	x20, l_.str.2@PAGE
Lloh11:
	add	x20, x20, l_.str.2@PAGEOFF
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	ldr	x9, [x22]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x21, #8]
	ldr	x8, [x8]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	bl	_ssl_swap_epochs
LBB0_7:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x19, #24]
	ldr	x1, [x21, #8]
	ldr	w2, [x21, #24]
	bl	_memcpy
	ldr	w8, [x21, #24]
	str	w8, [x19, #28]
	ldr	x8, [x21]
	str	x8, [x19]
	ldr	x8, [x21, #16]
	ldr	x9, [x19, #16]
	str	x8, [x9, #16]
	ldr	w2, [x19, #24]
	mov	w0, #3
	mov	x1, x20
	mov	w3, #12
	bl	_MBEDTLS_SSL_DEBUG_BUF
	mov	x0, x19
	bl	_mbedtls_ssl_write_record
	cbnz	w0, LBB0_11
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x19, #16]
	ldr	x21, [x8, #16]
	cbnz	x21, LBB0_4
LBB0_9:
	ldr	x9, [x19, #8]
Lloh12:
	adrp	x10, _MBEDTLS_SSL_HANDSHAKE_OVER@GOTPAGE
Lloh13:
	ldr	x10, [x10, _MBEDTLS_SSL_HANDSHAKE_OVER@GOTPAGEOFF]
Lloh14:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_12
; %bb.10:
Lloh15:
	adrp	x9, _MBEDTLS_SSL_RETRANS_FINISHED@GOTPAGE
Lloh16:
	ldr	x9, [x9, _MBEDTLS_SSL_RETRANS_FINISHED@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	str	x9, [x8]
	b	LBB0_13
LBB0_11:
	mov	x21, x0
Lloh18:
	adrp	x1, l_.str.3@PAGE
Lloh19:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #1
	mov	x2, x21
	bl	_MBEDTLS_SSL_DEBUG_RET
	b	LBB0_14
LBB0_12:
Lloh20:
	adrp	x9, _MBEDTLS_SSL_RETRANS_WAITING@GOTPAGE
Lloh21:
	ldr	x9, [x9, _MBEDTLS_SSL_RETRANS_WAITING@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	str	x9, [x8]
	ldr	w1, [x8, #8]
	mov	x0, x19
	bl	_ssl_set_timer
LBB0_13:
Lloh23:
	adrp	x1, l_.str.4@PAGE
Lloh24:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	mov	w21, #0
LBB0_14:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"=> mbedtls_ssl_resend"

	.comm	_MBEDTLS_SSL_RETRANS_SENDING,8,3 ; @MBEDTLS_SSL_RETRANS_SENDING
l_.str.1:                               ; @.str.1
	.asciz	"initialise resending"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,8,3  ; @MBEDTLS_SSL_MSG_HANDSHAKE
	.comm	_MBEDTLS_SSL_HS_FINISHED,8,3    ; @MBEDTLS_SSL_HS_FINISHED
l_.str.2:                               ; @.str.2
	.asciz	"resent handshake message header"

l_.str.3:                               ; @.str.3
	.asciz	"mbedtls_ssl_write_record"

	.comm	_MBEDTLS_SSL_HANDSHAKE_OVER,8,3 ; @MBEDTLS_SSL_HANDSHAKE_OVER
	.comm	_MBEDTLS_SSL_RETRANS_FINISHED,8,3 ; @MBEDTLS_SSL_RETRANS_FINISHED
	.comm	_MBEDTLS_SSL_RETRANS_WAITING,8,3 ; @MBEDTLS_SSL_RETRANS_WAITING
l_.str.4:                               ; @.str.4
	.asciz	"<= mbedtls_ssl_resend"

.subsections_via_symbols
