	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sldns_str2wire_hip_buf         ## -- Begin function sldns_str2wire_hip_buf
	.p2align	4, 0x90
_sldns_str2wire_hip_buf:                ## @sldns_str2wire_hip_buf
	.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
	cmpq	$3, (%rdx)
	ja	LBB0_2
## %bb.1:
	movq	_LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL@GOTPCREL(%rip), %rax
LBB0_17:
	movl	(%rax), %eax
LBB0_18:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	%rdx, %r13
	movq	%rsi, %r15
	movq	%rdi, %r14
	leaq	-72(%rbp), %rsi
	movl	$10, %edx
	callq	_strtol
	movq	%rax, 8(%r15)
	movq	-72(%rbp), %r12
	cmpb	$32, (%r12)
	jne	LBB0_19
## %bb.3:
	movl	%r12d, %ebx
	subl	%r14d, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	incl	%ebx
	cmpb	$32, 1(%r12)
	leaq	1(%r12), %r12
	je	LBB0_4
## %bb.5:
	movq	%r12, %rdi
	movl	$32, %esi
	callq	_strchr
	testq	%rax, %rax
	je	LBB0_6
## %bb.8:
	movb	$0, (%rax)
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	(%r13), %rax
	addq	$-4, %rax
	movq	%rax, -48(%rbp)
	leaq	32(%r15), %rax
	leaq	-48(%rbp), %rdx
	movq	%r12, %rdi
	movq	%rax, %r12
	movq	%rax, %rsi
	callq	_sldns_str2wire_hex_buf
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movb	$32, (%rcx)
	movl	%eax, %edi
	movl	%ebx, %esi
	callq	_RET_ERR_SHIFT
	jmp	LBB0_18
LBB0_19:
	movq	_LDNS_WIREPARSE_ERR_SYNTAX_INT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	%r14d, %r12d
	movl	%r12d, %esi
	jmp	LBB0_7
LBB0_6:
	movq	_LDNS_WIREPARSE_ERR_SYNTAX@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%ebx, %esi
LBB0_7:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_RET_ERR                        ## TAILCALL
LBB0_10:
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	-48(%rbp), %rax
	cmpq	$256, %rax                      ## imm = 0x100
	jb	LBB0_12
## %bb.11:
	movb	$32, (%rcx)
	movq	_LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addl	$510, %ebx                      ## imm = 0x1FE
	movl	%ebx, %esi
	callq	_RET_ERR
	jmp	LBB0_18
LBB0_12:
	movq	%rax, (%r15)
	movq	%rcx, %rbx
	movb	$32, (%rcx)
	incq	%rbx
	movq	%rbx, -72(%rbp)
	movq	(%r13), %rax
	movq	-48(%rbp), %rcx
	subq	%rcx, %rax
	addq	$-4, %rax
	movq	%rax, -56(%rbp)
	leaq	(%r12,%rcx,8), %rsi
	leaq	-56(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_sldns_str2wire_b64_buf
	testl	%eax, %eax
	je	LBB0_14
## %bb.13:
	subl	%r14d, %ebx
	movl	%eax, %edi
	movl	%ebx, %esi
	callq	_RET_ERR_SHIFT
	jmp	LBB0_18
LBB0_14:
	movq	-56(%rbp), %rsi
	cmpq	$65536, %rsi                    ## imm = 0x10000
	jb	LBB0_16
## %bb.15:
	movq	_LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	%r14d, %ebx
	addl	$65535, %ebx                    ## imm = 0xFFFF
	movl	%ebx, %esi
	callq	_RET_ERR
	jmp	LBB0_18
LBB0_16:
	addq	$16, %r15
	movq	%r15, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_sldns_write_uint16
	movq	-48(%rbp), %rax
	movq	-56(%rbp), %rcx
	addq	%rcx, %rax
	addq	$4, %rax
	movq	%rax, (%r13)
	movq	_LDNS_WIREPARSE_ERR_OK@GOTPCREL(%rip), %rax
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.comm	_LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL,4,2 ## @LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL
	.comm	_LDNS_WIREPARSE_ERR_SYNTAX_INT,4,2 ## @LDNS_WIREPARSE_ERR_SYNTAX_INT
	.comm	_LDNS_WIREPARSE_ERR_SYNTAX,4,2  ## @LDNS_WIREPARSE_ERR_SYNTAX
	.comm	_LDNS_WIREPARSE_ERR_LABEL_OVERFLOW,4,2 ## @LDNS_WIREPARSE_ERR_LABEL_OVERFLOW
	.comm	_LDNS_WIREPARSE_ERR_OK,4,2      ## @LDNS_WIREPARSE_ERR_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sldns_str2wire_hip_buf         ; -- Begin function sldns_str2wire_hip_buf
	.p2align	2
_sldns_str2wire_hip_buf:                ; @sldns_str2wire_hip_buf
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	ldr	x8, [x2]
	cmp	x8, #3
	b.hi	LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL@GOTPAGEOFF]
LBB0_2:
	ldr	w0, [x8]
LBB0_3:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_4:
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	add	x1, sp, #24
	mov	w2, #10
	bl	_strtol
	str	x0, [x21, #8]
	ldr	x24, [sp, #24]
	ldrb	w8, [x24]
	cmp	w8, #32
	b.ne	LBB0_10
; %bb.5:
	sub	w23, w24, w19
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w8, [x24, #1]!
	add	w23, w23, #1
	cmp	w8, #32
	b.eq	LBB0_6
; %bb.7:
	mov	x0, x24
	mov	w1, #32
	bl	_strchr
	cbz	x0, LBB0_11
; %bb.8:
	mov	x22, x0
	strb	wzr, [x0]
	ldr	x8, [x20]
	sub	x8, x8, #4
	str	x8, [sp, #16]
	add	x25, x21, #32
	add	x2, sp, #16
	mov	x0, x24
	mov	x1, x25
	bl	_sldns_str2wire_hex_buf
	cbz	w0, LBB0_13
; %bb.9:
	mov	w8, #32
	strb	w8, [x22]
	mov	x1, x23
	bl	_RET_ERR_SHIFT
	b	LBB0_3
LBB0_10:
Lloh2:
	adrp	x8, _LDNS_WIREPARSE_ERR_SYNTAX_INT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_SYNTAX_INT@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	sub	w1, w24, w19
	b	LBB0_12
LBB0_11:
Lloh5:
	adrp	x8, _LDNS_WIREPARSE_ERR_SYNTAX@GOTPAGE
Lloh6:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_SYNTAX@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	mov	x1, x23
LBB0_12:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_RET_ERR
LBB0_13:
	ldr	x8, [sp, #16]
	cmp	x8, #256
	b.lo	LBB0_15
; %bb.14:
	mov	w8, #32
	strb	w8, [x22]
Lloh8:
	adrp	x8, _LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	add	w1, w23, #510
	bl	_RET_ERR
	b	LBB0_3
LBB0_15:
	str	x8, [x21]
	mov	w8, #32
	strb	w8, [x22], #1
	str	x22, [sp, #24]
	ldr	x8, [x20]
	ldr	x9, [sp, #16]
	sub	x8, x8, x9
	sub	x8, x8, #4
	str	x8, [sp, #8]
	add	x1, x25, x9, lsl #3
	add	x2, sp, #8
	mov	x0, x22
	bl	_sldns_str2wire_b64_buf
	cbz	w0, LBB0_17
; %bb.16:
	sub	w1, w22, w19
	bl	_RET_ERR_SHIFT
	b	LBB0_3
LBB0_17:
	ldr	x1, [sp, #8]
	cmp	x1, #16, lsl #12                ; =65536
	b.lo	LBB0_19
; %bb.18:
Lloh11:
	adrp	x8, _LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPAGE
Lloh12:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_LABEL_OVERFLOW@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	mov	w8, #65535
	sub	w9, w22, w19
	add	w1, w9, w8
	bl	_RET_ERR
	b	LBB0_3
LBB0_19:
	add	x0, x21, #16
                                        ; kill: def $w1 killed $w1 killed $x1
	bl	_sldns_write_uint16
	ldp	x9, x8, [sp, #8]
	add	x8, x8, x9
	add	x8, x8, #4
	str	x8, [x20]
Lloh14:
	adrp	x8, _LDNS_WIREPARSE_ERR_OK@GOTPAGE
Lloh15:
	ldr	x8, [x8, _LDNS_WIREPARSE_ERR_OK@GOTPAGEOFF]
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL,4,2 ; @LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL
	.comm	_LDNS_WIREPARSE_ERR_SYNTAX_INT,4,2 ; @LDNS_WIREPARSE_ERR_SYNTAX_INT
	.comm	_LDNS_WIREPARSE_ERR_SYNTAX,4,2  ; @LDNS_WIREPARSE_ERR_SYNTAX
	.comm	_LDNS_WIREPARSE_ERR_LABEL_OVERFLOW,4,2 ; @LDNS_WIREPARSE_ERR_LABEL_OVERFLOW
	.comm	_LDNS_WIREPARSE_ERR_OK,4,2      ; @LDNS_WIREPARSE_ERR_OK
.subsections_via_symbols
