	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function insert_query
_insert_query:                          ## @insert_query
	.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	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %r13
	movq	16(%rdi), %rax
	testq	%rax, %rax
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.1:
	movq	(%rax), %rcx
	leaq	8(%rcx), %rax
	jmp	LBB0_3
LBB0_2:
	leaq	24(%r13), %rax
	movq	%r13, %rcx
LBB0_3:
	movq	(%rax), %r15
	movq	(%rcx), %rbx
	movq	%r14, %rdi
	callq	_sldns_buffer_remaining
	cltq
	movq	(%r13), %rcx
	addq	$8, %rcx
	cmpq	%rax, %rcx
	jbe	LBB0_5
## %bb.4:
	movq	_RETVAL_TRUNC@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_5:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	_dname_count_labels
	movq	%r12, %rbx
	movl	%eax, %r12d
	movq	%r14, %rdi
	callq	_sldns_buffer_position
	movq	%r15, %rdi
	movl	%r12d, %esi
	movl	%eax, %edx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	xorl	%r8d, %r8d
	movq	%rbx, %r9
	callq	_compress_tree_store
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movq	%r14, %rdi
	callq	_sldns_buffer_current
	movq	%r14, %rdi
	cmpq	%r15, %rax
	je	LBB0_8
## %bb.9:
	movq	%r15, %rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_sldns_buffer_write
	jmp	LBB0_10
LBB0_6:
	movq	_RETVAL_OUTMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_8:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_sldns_buffer_skip
LBB0_10:
	movl	12(%r13), %esi
	movq	%r14, %rdi
	callq	_sldns_buffer_write_u16
	movl	8(%r13), %esi
	movq	%r14, %rdi
	callq	_sldns_buffer_write_u16
	movq	_RETVAL_OK@GOTPCREL(%rip), %rax
LBB0_11:
	movl	(%rax), %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RETVAL_TRUNC,4,2               ## @RETVAL_TRUNC
	.comm	_RETVAL_OUTMEM,4,2              ## @RETVAL_OUTMEM
	.comm	_RETVAL_OK,4,2                  ## @RETVAL_OK
	.no_dead_strip	_insert_query
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function insert_query
_insert_query:                          ; @insert_query
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x22, x3
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_2
; %bb.1:
	ldr	x9, [x8]
	add	x8, x9, #8
	b	LBB0_3
LBB0_2:
	add	x8, x20, #24
	mov	x9, x20
LBB0_3:
	ldr	x24, [x8]
	ldr	x23, [x9]
	mov	x0, x19
	bl	_sldns_buffer_remaining
	ldr	x8, [x20]
	add	x8, x8, #8
	cmp	x8, w0, sxtw
	b.ls	LBB0_5
; %bb.4:
Lloh0:
	adrp	x8, _RETVAL_TRUNC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RETVAL_TRUNC@GOTPAGEOFF]
	b	LBB0_11
LBB0_5:
	mov	x0, x24
	bl	_dname_count_labels
	mov	x25, x0
	mov	x0, x19
	bl	_sldns_buffer_position
	mov	x2, x0
	mov	x0, x24
	mov	x1, x25
	mov	x3, x22
	mov	x4, #0
	mov	x5, x21
	bl	_compress_tree_store
	cbz	w0, LBB0_8
; %bb.6:
	mov	x0, x19
	bl	_sldns_buffer_current
	cmp	x0, x24
	b.eq	LBB0_9
; %bb.7:
	mov	x0, x19
	mov	x1, x24
	mov	x2, x23
	bl	_sldns_buffer_write
	b	LBB0_10
LBB0_8:
Lloh2:
	adrp	x8, _RETVAL_OUTMEM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RETVAL_OUTMEM@GOTPAGEOFF]
	b	LBB0_11
LBB0_9:
	mov	x0, x19
	mov	x1, x23
	bl	_sldns_buffer_skip
LBB0_10:
	ldr	w1, [x20, #12]
	mov	x0, x19
	bl	_sldns_buffer_write_u16
	ldr	w1, [x20, #8]
	mov	x0, x19
	bl	_sldns_buffer_write_u16
Lloh4:
	adrp	x8, _RETVAL_OK@GOTPAGE
Lloh5:
	ldr	x8, [x8, _RETVAL_OK@GOTPAGEOFF]
LBB0_11:
	ldr	w0, [x8]
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_RETVAL_TRUNC,4,2               ; @RETVAL_TRUNC
	.comm	_RETVAL_OUTMEM,4,2              ; @RETVAL_OUTMEM
	.comm	_RETVAL_OK,4,2                  ; @RETVAL_OK
	.no_dead_strip	_insert_query
.subsections_via_symbols
