	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function validate_region_size
_validate_region_size:                  ## @validate_region_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	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	16(%rdi), %rax
	movslq	(%rax), %rcx
	leal	2097151(%rcx), %edi
	testq	%rcx, %rcx
	cmovnsl	%ecx, %edi
	sarl	$21, %edi
	movslq	%edi, %rdx
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.6:
	movq	%rsi, %rbx
	cmpq	%rsi, %rcx
	jae	LBB0_9
## %bb.7:
	leaq	L_.str.2(%rip), %rcx
	jmp	LBB0_8
LBB0_1:
	cmpl	$8193, %edi                     ## imm = 0x2001
	jb	LBB0_15
## %bb.2:
	leaq	-1(%rdx), %rax
	testq	%rax, %rdx
	jne	LBB0_4
## %bb.3:
	xorl	%ebx, %ebx
	jmp	LBB0_5
LBB0_9:
	cmpq	%rbx, %rdx
	jbe	LBB0_11
## %bb.10:
	leaq	L_.str.3(%rip), %rdi
	movq	%rbx, %rsi
	callq	_DMERR
	movq	16(%r14), %rax
	leaq	L_.str.4(%rip), %rcx
	jmp	LBB0_8
LBB0_15:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_DMINFO
	movl	$8192, %ebx                     ## imm = 0x2000
	jmp	LBB0_16
LBB0_11:
	movq	%rbx, %rdi
	callq	_is_power_of_2
	testl	%eax, %eax
	je	LBB0_12
## %bb.13:
	cmpq	%rbx, (%r14)
	jbe	LBB0_16
## %bb.14:
	movq	16(%r14), %rax
	leaq	L_.str.6(%rip), %rcx
	jmp	LBB0_8
LBB0_4:
	xorl	%edi, %edi
	callq	_fls
	movl	$1, %edx
	movl	%eax, %ecx
	shll	%cl, %edx
	movslq	%edx, %rbx
LBB0_5:
	leaq	L_.str(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_DMINFO
LBB0_16:
	shlq	$9, %rbx
	movq	%rbx, 8(%r14)
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_12:
	movq	16(%r14), %rax
	leaq	L_.str.5(%rip), %rcx
LBB0_8:
	movq	%rcx, 8(%rax)
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_17:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Choosing default region size of %lu sectors"

L_.str.1:                               ## @.str.1
	.asciz	"Choosing default region size of 4MiB"

L_.str.2:                               ## @.str.2
	.asciz	"Supplied region size is too large"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.3:                               ## @.str.3
	.asciz	"Supplied region_size (%lu sectors) below minimum (%lu)"

L_.str.4:                               ## @.str.4
	.asciz	"Supplied region size is too small"

L_.str.5:                               ## @.str.5
	.asciz	"Region size is not a power of 2"

L_.str.6:                               ## @.str.6
	.asciz	"Region size is smaller than the chunk size"

	.no_dead_strip	_validate_region_size
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function validate_region_size
_validate_region_size:                  ; @validate_region_size
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldrsw	x9, [x8]
	mov	w10, #2097151
	add	w10, w9, w10
	cmp	w9, #0
	csel	w10, w10, w9, lt
	sbfx	x2, x10, #21, #11
	cbz	x1, LBB0_3
; %bb.1:
	mov	x20, x1
	cmp	x9, x1
	b.hs	LBB0_6
; %bb.2:
Lloh0:
	adrp	x9, l_.str.2@PAGE
Lloh1:
	add	x9, x9, l_.str.2@PAGEOFF
	str	x9, [x8, #8]
	b	LBB0_17
LBB0_3:
	cmp	w2, #2, lsl #12                 ; =8192
	b.ls	LBB0_8
; %bb.4:
	sub	x8, x2, #1
	tst	x2, x8
	b.ne	LBB0_12
; %bb.5:
	mov	x20, #0
	b	LBB0_13
LBB0_6:
	cmp	x2, x20
	b.ls	LBB0_9
; %bb.7:
Lloh2:
	adrp	x0, l_.str.3@PAGE
Lloh3:
	add	x0, x0, l_.str.3@PAGEOFF
	mov	x1, x20
	bl	_DMERR
Lloh4:
	adrp	x8, l_.str.4@PAGE
Lloh5:
	add	x8, x8, l_.str.4@PAGEOFF
	b	LBB0_16
LBB0_8:
Lloh6:
	adrp	x0, l_.str.1@PAGE
Lloh7:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DMINFO
	mov	w20, #8192
	b	LBB0_14
LBB0_9:
	mov	x0, x20
	bl	_is_power_of_2
	cbz	w0, LBB0_15
; %bb.10:
	ldr	x8, [x19]
	cmp	x8, x20
	b.ls	LBB0_14
; %bb.11:
Lloh8:
	adrp	x8, l_.str.6@PAGE
Lloh9:
	add	x8, x8, l_.str.6@PAGEOFF
	b	LBB0_16
LBB0_12:
	mov	x0, #0
	bl	_fls
	mov	w8, #1
	lsl	w8, w8, w0
	sxtw	x20, w8
LBB0_13:
	str	x20, [sp]
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DMINFO
LBB0_14:
	mov	w0, #0
	lsl	x8, x20, #9
	str	x8, [x19, #8]
	b	LBB0_18
LBB0_15:
Lloh12:
	adrp	x8, l_.str.5@PAGE
Lloh13:
	add	x8, x8, l_.str.5@PAGEOFF
LBB0_16:
	ldr	x9, [x19, #16]
	str	x8, [x9, #8]
LBB0_17:
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_18:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Choosing default region size of %lu sectors"

l_.str.1:                               ; @.str.1
	.asciz	"Choosing default region size of 4MiB"

l_.str.2:                               ; @.str.2
	.asciz	"Supplied region size is too large"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.3:                               ; @.str.3
	.asciz	"Supplied region_size (%lu sectors) below minimum (%lu)"

l_.str.4:                               ; @.str.4
	.asciz	"Supplied region size is too small"

l_.str.5:                               ; @.str.5
	.asciz	"Region size is not a power of 2"

l_.str.6:                               ; @.str.6
	.asciz	"Region size is smaller than the chunk size"

	.no_dead_strip	_validate_region_size
.subsections_via_symbols
