	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_parse_packet                   ## -- Begin function parse_packet
	.p2align	4, 0x90
_parse_packet:                          ## @parse_packet
	.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	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %rbx
	callq	_sldns_buffer_remaining
	movq	_LDNS_HEADER_SIZE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jl	LBB0_1
## %bb.2:
	leaq	56(%r15), %rsi
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_sldns_buffer_read
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movq	%rax, 48(%r15)
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movl	%eax, (%r15)
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movl	%eax, 4(%r15)
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movl	%eax, 8(%r15)
	movq	%rbx, %rdi
	callq	_sldns_buffer_read_u16
	movl	%eax, 12(%r15)
	cmpl	$2, (%r15)
	jl	LBB0_3
LBB0_1:
	movq	_LDNS_RCODE_FORMERR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_parse_query_section
	testl	%eax, %eax
	jne	LBB0_10
## %bb.4:
	movq	_LDNS_SECTION_ANSWER@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	4(%r15), %r8d
	leaq	32(%r15), %r9
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	_parse_section
	testl	%eax, %eax
	jne	LBB0_10
## %bb.5:
	movq	_LDNS_SECTION_AUTHORITY@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	8(%r15), %r8d
	leaq	24(%r15), %r9
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	_parse_section
	testl	%eax, %eax
	jne	LBB0_10
## %bb.6:
	movq	%rbx, %rdi
	callq	_sldns_buffer_remaining
	movl	12(%r15), %r8d
	testq	%rax, %rax
	jne	LBB0_8
## %bb.7:
	cmpl	$1, %r8d
	je	LBB0_9
LBB0_8:
	movq	_LDNS_SECTION_ADDITIONAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	16(%r15), %r9
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	_parse_section
	testl	%eax, %eax
	jne	LBB0_10
LBB0_9:
	movq	24(%r15), %rax
	addq	32(%r15), %rax
	addq	16(%r15), %rax
	movq	%rax, 40(%r15)
	xorl	%eax, %eax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_LDNS_HEADER_SIZE,8,3           ## @LDNS_HEADER_SIZE
	.comm	_LDNS_RCODE_FORMERR,4,2         ## @LDNS_RCODE_FORMERR
	.comm	_LDNS_SECTION_ANSWER,4,2        ## @LDNS_SECTION_ANSWER
	.comm	_LDNS_SECTION_AUTHORITY,4,2     ## @LDNS_SECTION_AUTHORITY
	.comm	_LDNS_SECTION_ADDITIONAL,4,2    ## @LDNS_SECTION_ADDITIONAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_parse_packet                   ; -- Begin function parse_packet
	.p2align	2
_parse_packet:                          ; @parse_packet
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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, x2
	mov	x19, x1
	mov	x21, x0
	bl	_sldns_buffer_remaining
Lloh0:
	adrp	x8, _LDNS_HEADER_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LDNS_HEADER_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	b.lt	LBB0_2
; %bb.1:
	add	x1, x19, #56
	mov	x0, x21
	mov	w2, #4
	bl	_sldns_buffer_read
	mov	x0, x21
	bl	_sldns_buffer_read_u16
	str	x0, [x19, #48]
	mov	x0, x21
	bl	_sldns_buffer_read_u16
	str	w0, [x19]
	mov	x0, x21
	bl	_sldns_buffer_read_u16
	str	w0, [x19, #4]
	mov	x0, x21
	bl	_sldns_buffer_read_u16
	str	w0, [x19, #8]
	mov	x0, x21
	bl	_sldns_buffer_read_u16
	str	w0, [x19, #12]
	ldr	w8, [x19]
	cmp	w8, #2
	b.lt	LBB0_4
LBB0_2:
Lloh3:
	adrp	x8, _LDNS_RCODE_FORMERR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LDNS_RCODE_FORMERR@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
LBB0_3:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_4:
	mov	x0, x21
	mov	x1, x19
	bl	_parse_query_section
	cbnz	w0, LBB0_3
; %bb.5:
Lloh6:
	adrp	x8, _LDNS_SECTION_ANSWER@GOTPAGE
Lloh7:
	ldr	x8, [x8, _LDNS_SECTION_ANSWER@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
	ldr	w4, [x19, #4]
	add	x5, x19, #32
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_parse_section
	cbnz	w0, LBB0_3
; %bb.6:
Lloh9:
	adrp	x8, _LDNS_SECTION_AUTHORITY@GOTPAGE
Lloh10:
	ldr	x8, [x8, _LDNS_SECTION_AUTHORITY@GOTPAGEOFF]
Lloh11:
	ldr	w3, [x8]
	ldr	w4, [x19, #8]
	add	x5, x19, #24
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_parse_section
	cbnz	w0, LBB0_3
; %bb.7:
	mov	x0, x21
	bl	_sldns_buffer_remaining
	ldr	w4, [x19, #12]
	cbnz	x0, LBB0_9
; %bb.8:
	cmp	w4, #1
	b.eq	LBB0_10
LBB0_9:
Lloh12:
	adrp	x8, _LDNS_SECTION_ADDITIONAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _LDNS_SECTION_ADDITIONAL@GOTPAGEOFF]
Lloh14:
	ldr	w3, [x8]
	add	x5, x19, #16
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_parse_section
	cbnz	w0, LBB0_3
LBB0_10:
	mov	w0, #0
	ldp	x9, x8, [x19, #24]
	ldr	x10, [x19, #16]
	add	x8, x9, x8
	add	x8, x8, x10
	str	x8, [x19, #40]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_LDNS_HEADER_SIZE,8,3           ; @LDNS_HEADER_SIZE
	.comm	_LDNS_RCODE_FORMERR,4,2         ; @LDNS_RCODE_FORMERR
	.comm	_LDNS_SECTION_ANSWER,4,2        ; @LDNS_SECTION_ANSWER
	.comm	_LDNS_SECTION_AUTHORITY,4,2     ; @LDNS_SECTION_AUTHORITY
	.comm	_LDNS_SECTION_ADDITIONAL,4,2    ; @LDNS_SECTION_ADDITIONAL
.subsections_via_symbols
