	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ldns_hexstring_to_data         ## -- Begin function ldns_hexstring_to_data
	.p2align	4, 0x90
_ldns_hexstring_to_data:                ## @ldns_hexstring_to_data
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	$-1, %ebx
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.1:
	movq	%rsi, %r15
	testq	%rsi, %rsi
	je	LBB0_6
## %bb.2:
	movq	%rdi, %r14
	movq	%r15, %rdi
	callq	_strlen
	movl	$-2, %ebx
	testb	$1, %al
	jne	LBB0_6
## %bb.3:
	movq	%r15, %rdi
	callq	_strlen
	incl	%eax
	xorl	%ebx, %ebx
	cmpl	$3, %eax
	jb	LBB0_6
## %bb.4:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movsbl	(%r15,%rbx,2), %edi
	callq	_ldns_hexdigit_to_int
	movq	%rax, %r12
	shll	$4, %r12d
	movsbl	1(%r15,%rbx,2), %edi
	callq	_ldns_hexdigit_to_int
	addl	%r12d, %eax
	movl	%eax, (%r14,%rbx,4)
	incq	%rbx
	movq	%r15, %rdi
	callq	_strlen
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	movslq	%ecx, %rax
	cmpq	%rax, %rbx
	jb	LBB0_5
LBB0_6:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ldns_hexstring_to_data         ; -- Begin function ldns_hexstring_to_data
	.p2align	2
_ldns_hexstring_to_data:                ; @ldns_hexstring_to_data
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	w21, #-1
	cbz	x0, LBB0_8
; %bb.1:
	mov	x19, x1
	cbz	x1, LBB0_8
; %bb.2:
	mov	x20, x0
	mov	x0, x19
	bl	_strlen
	tbnz	w0, #0, LBB0_5
; %bb.3:
	mov	x0, x19
	bl	_strlen
	add	w8, w0, #1
	cmp	w8, #3
	b.hs	LBB0_6
; %bb.4:
	mov	w21, #0
	b	LBB0_8
LBB0_5:
	mov	w21, #-2
	b	LBB0_8
LBB0_6:
	mov	x21, #0
	add	x23, x19, #1
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldursb	w0, [x23, #-1]
	bl	_ldns_hexdigit_to_int
	mov	x22, x0
	ldrsb	w0, [x23]
	bl	_ldns_hexdigit_to_int
	add	w8, w0, w22, lsl #4
	str	w8, [x20, x21, lsl #2]
	add	x21, x21, #1
	mov	x0, x19
	bl	_strlen
	cmp	w0, #0
	cinc	w8, w0, lt
	asr	w8, w8, #1
	add	x23, x23, #2
	cmp	x21, w8, sxtw
	b.lo	LBB0_7
LBB0_8:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
