	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function calc_size
_calc_size:                             ## @calc_size
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	movl	$8, (%rdx)
	movl	$4, %esi
	callq	_sldns_buffer_skip
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movq	%rax, %r13
	movq	%rbx, %rdi
	callq	_sldns_buffer_remaining
	xorl	%r12d, %r12d
	cmpq	%r13, %rax
	jl	LBB0_20
## %bb.1:
	movq	%r14, %rdi
	callq	_sldns_rr_descript
	testq	%r13, %r13
	jle	LBB0_18
## %bb.2:
	movq	%rax, %r14
	testq	%rax, %rax
	je	LBB0_18
## %bb.3:
	movq	(%r14), %rax
	testq	%rax, %rax
	movq	%rbx, %r12
	jle	LBB0_19
## %bb.4:
	testl	%eax, %eax
	je	LBB0_19
## %bb.5:
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	xorl	%r15d, %r15d
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rax
	movl	(%rax,%r15), %edi
	cmpl	$128, %edi
	je	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	cmpl	$129, %edi
	jne	LBB0_12
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	%r12, %rdi
	callq	_sldns_buffer_position
	movq	%rax, %rbx
	movq	%r12, %rdi
	callq	_pkt_dname_len
	movq	%r12, %r14
	xorl	%r12d, %r12d
	testq	%rax, %rax
	je	LBB0_20
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	callq	_sldns_buffer_position
	subq	%rbx, %rax
	cmpq	%r13, %rax
	ja	LBB0_20
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	%r14, %rdi
	callq	_sldns_buffer_position
	addq	%r13, %rbx
	subq	%rax, %rbx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	addl	%ecx, (%rax)
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	decl	%eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %r13
	movq	%r14, %r12
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	%r12, %rdi
	callq	_sldns_buffer_current
	movslq	(%rax), %rbx
	incq	%rbx
	testq	%rbx, %rbx
	jne	LBB0_13
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_6 Depth=1
	callq	_get_rdf_size
	movq	%rax, %rbx
	testq	%rbx, %rbx
	je	LBB0_15
LBB0_13:                                ##   in Loop: Header=BB0_6 Depth=1
	subq	%rbx, %r13
	jb	LBB0_21
## %bb.14:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_sldns_buffer_skip
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	addl	%ebx, (%rax)
LBB0_15:                                ##   in Loop: Header=BB0_6 Depth=1
	testq	%r13, %r13
	jle	LBB0_19
## %bb.16:                              ##   in Loop: Header=BB0_6 Depth=1
	addq	$4, %r15
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_6
	jmp	LBB0_19
LBB0_18:
	movq	%rbx, %r12
LBB0_19:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	addl	%r13d, (%rax)
	movq	%r12, %rdi
	movl	%r13d, %esi
	callq	_sldns_buffer_skip
	movl	$1, %r12d
LBB0_20:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_21:
	xorl	%r12d, %r12d
	jmp	LBB0_20
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_calc_size
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function calc_size
_calc_size:                             ; @calc_size
	.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	x20, x2
	mov	x22, x1
	mov	x19, x0
	mov	w8, #8
	str	w8, [x2]
	mov	w1, #4
	bl	_sldns_buffer_skip
	mov	x0, x19
	bl	_sldns_buffer_read_u16
	mov	x21, x0
	mov	x0, x19
	bl	_sldns_buffer_remaining
	cmp	x0, x21
	b.ge	LBB0_2
LBB0_1:
	mov	w0, #0
	b	LBB0_19
LBB0_2:
	mov	x0, x22
	bl	_sldns_rr_descript
	cmp	x21, #1
	b.lt	LBB0_18
; %bb.3:
	mov	x22, x0
	cbz	x0, LBB0_18
; %bb.4:
	ldr	x25, [x22]
	cmp	x25, #1
	b.lt	LBB0_18
; %bb.5:
	cbz	w25, LBB0_18
; %bb.6:
	mov	x26, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x22, #8]
	ldr	w0, [x8, x26]
	cmp	w0, #128
	b.eq	LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	cmp	w0, #129
	b.ne	LBB0_13
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x19
	bl	_sldns_buffer_position
	mov	x23, x0
	mov	x0, x19
	bl	_pkt_dname_len
	cbz	x0, LBB0_19
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x24, x0
	mov	x0, x19
	bl	_sldns_buffer_position
	sub	x8, x0, x23
	cmp	x8, x21
	b.hi	LBB0_1
; %bb.11:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x19
	bl	_sldns_buffer_position
	add	x8, x23, x21
	sub	x21, x8, x0
	ldr	w8, [x20]
	add	w8, w8, w24
	str	w8, [x20]
	sub	w25, w25, #1
	b	LBB0_16
LBB0_12:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x19
	bl	_sldns_buffer_current
	ldrsw	x8, [x0]
	add	x23, x8, #1
	cbnz	x23, LBB0_14
	b	LBB0_16
LBB0_13:                                ;   in Loop: Header=BB0_7 Depth=1
	bl	_get_rdf_size
	mov	x23, x0
	cbz	x23, LBB0_16
LBB0_14:                                ;   in Loop: Header=BB0_7 Depth=1
	subs	x21, x21, x23
	b.lo	LBB0_1
; %bb.15:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x19
	mov	x1, x23
	bl	_sldns_buffer_skip
	ldr	w8, [x20]
	add	w8, w8, w23
	str	w8, [x20]
LBB0_16:                                ;   in Loop: Header=BB0_7 Depth=1
	cmp	x21, #1
	b.lt	LBB0_18
; %bb.17:                               ;   in Loop: Header=BB0_7 Depth=1
	add	x26, x26, #4
	cbnz	w25, LBB0_7
LBB0_18:
	ldr	w8, [x20]
	add	w8, w8, w21
	str	w8, [x20]
	mov	x0, x19
	mov	x1, x21
	bl	_sldns_buffer_skip
	mov	w0, #1
LBB0_19:
	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
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_calc_size
.subsections_via_symbols
