	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ldns_dnssec_build_data_chain_dnskey
_ldns_dnssec_build_data_chain_dnskey:   ## @ldns_dnssec_build_data_chain_dnskey
	.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	%r8, -56(%rbp)                  ## 8-byte Spill
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	testq	%rcx, %rcx
	je	LBB0_8
## %bb.1:
	movq	%r9, %r13
	movq	%rcx, %rbx
	movq	%rdx, %r14
	movq	%rdi, %r12
	movl	16(%rbp), %r15d
	movq	%rcx, %rdi
	callq	_ldns_rr_list_rr_count
	testq	%rax, %rax
	jle	LBB0_8
## %bb.2:
	movl	%r15d, -48(%rbp)                ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_ldns_rr_list_clone
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movl	%eax, 16(%r15)
	movq	$0, 8(%r15)
	movq	_LDNS_RR_TYPE_DNSKEY@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	_LDNS_SECTION_ANY_NOQUESTION@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_ldns_pkt_rr_list_by_name_and_type
	testq	%rax, %rax
	je	LBB0_3
## %bb.6:
	movq	%rax, %rbx
	movq	%r12, %rdi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movq	%rax, %rdx
	movq	%r14, %rcx
	xorl	%r8d, %r8d
	callq	_ldns_dnssec_build_data_chain
	movq	%rax, (%r15)
	movq	_LDNS_RR_TYPE_DNSKEY@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	jmp	LBB0_7
LBB0_8:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	_LDNS_SECTION_ANY_NOQUESTION@GOTPCREL(%rip), %rbx
	movq	_LDNS_RR_TYPE_DNSKEY@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	%r12, %rdi
	movq	%r13, %rsi
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %r8d
	callq	_ldns_resolver_query
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%rax, %r14
	movq	_LDNS_RR_TYPE_DNSKEY@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movl	(%rbx), %ecx
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_ldns_pkt_rr_list_by_name_and_type
	movl	%r15d, %esi
	movq	%rax, %rbx
	movq	%r12, %rdi
	movq	%rax, %rdx
	movq	%r14, %rcx
	xorl	%r8d, %r8d
	callq	_ldns_dnssec_build_data_chain
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movq	_LDNS_RR_TYPE_DNSKEY@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movq	%r14, %rdi
	callq	_ldns_pkt_free
	jmp	LBB0_7
LBB0_4:
	xorl	%ebx, %ebx
LBB0_7:
	movq	%rbx, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ldns_rr_list_deep_free         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_LDNS_RR_TYPE_DNSKEY,8,3        ## @LDNS_RR_TYPE_DNSKEY
	.comm	_LDNS_SECTION_ANY_NOQUESTION,4,2 ## @LDNS_SECTION_ANY_NOQUESTION
	.no_dead_strip	_ldns_dnssec_build_data_chain_dnskey
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ldns_dnssec_build_data_chain_dnskey
_ldns_dnssec_build_data_chain_dnskey:   ; @ldns_dnssec_build_data_chain_dnskey
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	cbz	x3, LBB0_4
; %bb.1:
	mov	x23, x6
	mov	x22, x5
	mov	x19, x4
	mov	x25, x3
	mov	x24, x2
	mov	x20, x1
	mov	x21, x0
	mov	x0, x3
	bl	_ldns_rr_list_rr_count
	cmp	x0, #1
	b.lt	LBB0_4
; %bb.2:
	mov	x0, x25
	bl	_ldns_rr_list_clone
	str	w0, [x19, #16]
	str	xzr, [x19, #8]
Lloh0:
	adrp	x26, _LDNS_RR_TYPE_DNSKEY@GOTPAGE
Lloh1:
	ldr	x26, [x26, _LDNS_RR_TYPE_DNSKEY@GOTPAGEOFF]
	ldr	x2, [x26]
Lloh2:
	adrp	x27, _LDNS_SECTION_ANY_NOQUESTION@GOTPAGE
Lloh3:
	ldr	x27, [x27, _LDNS_SECTION_ANY_NOQUESTION@GOTPAGEOFF]
	ldr	w3, [x27]
	mov	x0, x24
	mov	x1, x22
	bl	_ldns_pkt_rr_list_by_name_and_type
	cbz	x0, LBB0_5
; %bb.3:
	mov	x25, x0
	mov	x0, x21
	mov	x1, x20
	mov	x2, x25
	mov	x3, x24
	mov	x4, #0
	bl	_ldns_dnssec_build_data_chain
	str	x0, [x19]
	ldr	x8, [x26]
	str	x8, [x0]
	b	LBB0_8
LBB0_4:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_5:
	ldr	x2, [x26]
	mov	x0, x21
	mov	x1, x22
	mov	x3, x23
	mov	x4, x20
	bl	_ldns_resolver_query
	cbz	x0, LBB0_7
; %bb.6:
	mov	x23, x0
	ldr	x2, [x26]
	ldr	w3, [x27]
	mov	x1, x22
	bl	_ldns_pkt_rr_list_by_name_and_type
	mov	x25, x0
	mov	x0, x21
	mov	x1, x20
	mov	x2, x25
	mov	x3, x23
	mov	x4, #0
	bl	_ldns_dnssec_build_data_chain
	str	x0, [x19]
	ldr	x8, [x26]
	str	x8, [x0]
	mov	x0, x23
	bl	_ldns_pkt_free
	b	LBB0_8
LBB0_7:
	mov	x25, #0
LBB0_8:
	mov	x0, x25
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_ldns_rr_list_deep_free
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_LDNS_RR_TYPE_DNSKEY,8,3        ; @LDNS_RR_TYPE_DNSKEY
	.comm	_LDNS_SECTION_ANY_NOQUESTION,4,2 ; @LDNS_SECTION_ANY_NOQUESTION
	.no_dead_strip	_ldns_dnssec_build_data_chain_dnskey
.subsections_via_symbols
