	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function test_tls_crypt_v2_setup
_test_tls_crypt_v2_setup:               ## @test_tls_crypt_v2_setup
	.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, %r14
	movl	$1, %edi
	movl	$64, %esi
	callq	_calloc
	movq	%rax, %rbx
	movq	%rax, (%r14)
	xorl	%eax, %eax
	callq	_gc_new
	leaq	36(%rbx), %r14
	movl	%eax, 36(%rbx)
	movq	_TLS_CRYPT_V2_MAX_METADATA_LEN@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	$16, %rdi
	movq	%r14, %rsi
	callq	_alloc_buf_gc
	movq	%rax, 56(%rbx)
	movq	(%r15), %rdi
	addq	$16, %rdi
	movq	%r14, %rsi
	callq	_alloc_buf_gc
	movq	%rax, 48(%rbx)
	movq	_TLS_CRYPT_V2_MAX_WKC_LEN@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	$16, %rdi
	movq	%r14, %rsi
	callq	_alloc_buf_gc
	movq	%rax, 40(%rbx)
	leaq	16(%rbx), %r14
	movq	24(%rbx), %rdi
	movl	$8, %esi
	callq	_rand_bytes
	movl	$2, 16(%rbx)
	xorl	%eax, %eax
	callq	_tls_crypt_kt
	movl	%eax, -32(%rbp)
	leaq	32(%rbx), %rdi
	movq	_KEY_DIRECTION_BIDIRECTIONAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str(%rip), %r8
	leaq	-32(%rbp), %rcx
	movq	%r14, %rsi
	callq	_init_key_ctx_bi
	movq	8(%rbx), %rdi
	movl	$8, %esi
	callq	_rand_bytes
	movl	$2, (%rbx)
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TLS_CRYPT_V2_MAX_METADATA_LEN,8,3 ## @TLS_CRYPT_V2_MAX_METADATA_LEN
	.comm	_TLS_CRYPT_V2_MAX_WKC_LEN,8,3   ## @TLS_CRYPT_V2_MAX_WKC_LEN
	.comm	_KEY_DIRECTION_BIDIRECTIONAL,4,2 ## @KEY_DIRECTION_BIDIRECTIONAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tls-crypt-v2 server key"

	.no_dead_strip	_test_tls_crypt_v2_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function test_tls_crypt_v2_setup
_test_tls_crypt_v2_setup:               ; @test_tls_crypt_v2_setup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x0
	mov	w0, #1
	mov	w1, #64
	bl	_calloc
	mov	x19, x0
	str	x0, [x20]
	bl	_gc_new
	mov	x20, x19
	str	w0, [x20, #36]!
Lloh0:
	adrp	x21, _TLS_CRYPT_V2_MAX_METADATA_LEN@GOTPAGE
Lloh1:
	ldr	x21, [x21, _TLS_CRYPT_V2_MAX_METADATA_LEN@GOTPAGEOFF]
	ldr	x8, [x21]
	add	x0, x8, #16
	mov	x1, x20
	bl	_alloc_buf_gc
	str	x0, [x19, #56]
	ldr	x8, [x21]
	add	x0, x8, #16
	mov	x1, x20
	bl	_alloc_buf_gc
	str	x0, [x19, #48]
Lloh2:
	adrp	x8, _TLS_CRYPT_V2_MAX_WKC_LEN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _TLS_CRYPT_V2_MAX_WKC_LEN@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	add	x0, x8, #16
	mov	x1, x20
	bl	_alloc_buf_gc
	str	x0, [x19, #40]
	ldr	x0, [x19, #24]
	mov	w1, #8
	bl	_rand_bytes
	mov	w21, #2
	mov	x20, x19
	str	w21, [x20, #16]!
	bl	_tls_crypt_kt
	str	w0, [sp, #8]
	add	x0, x19, #32
Lloh5:
	adrp	x8, _KEY_DIRECTION_BIDIRECTIONAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _KEY_DIRECTION_BIDIRECTIONAL@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
Lloh8:
	adrp	x4, l_.str@PAGE
Lloh9:
	add	x4, x4, l_.str@PAGEOFF
	add	x3, sp, #8
	mov	x1, x20
	bl	_init_key_ctx_bi
	ldr	x0, [x19, #8]
	mov	w1, #8
	bl	_rand_bytes
	str	w21, [x19]
	mov	w0, #0
	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
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_TLS_CRYPT_V2_MAX_METADATA_LEN,8,3 ; @TLS_CRYPT_V2_MAX_METADATA_LEN
	.comm	_TLS_CRYPT_V2_MAX_WKC_LEN,8,3   ; @TLS_CRYPT_V2_MAX_WKC_LEN
	.comm	_KEY_DIRECTION_BIDIRECTIONAL,4,2 ; @KEY_DIRECTION_BIDIRECTIONAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tls-crypt-v2 server key"

	.no_dead_strip	_test_tls_crypt_v2_setup
.subsections_via_symbols
