	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iova_to_vaddr                  ## -- Begin function iova_to_vaddr
	.p2align	4, 0x90
_iova_to_vaddr:                         ## @iova_to_vaddr
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	(%rdi), %rax
	movq	_RXE_MEM_STATE_VALID@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.3:
	movq	%rsi, %r14
	movq	%rdi, %rbx
	cmpq	$0, 8(%rdi)
	je	LBB0_9
## %bb.4:
	movl	%edx, %r15d
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_mem_check_range
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_2
LBB0_1:
	leaq	L_.str(%rip), %rdi
LBB0_2:
	callq	_pr_warn
	xorl	%r14d, %r14d
LBB0_9:
	movq	%r14, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	leaq	-32(%rbp), %rdx
	leaq	-28(%rbp), %rcx
	leaq	-40(%rbp), %r8
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_lookup_iova
	movq	-40(%rbp), %r14
	movslq	%r15d, %rdx
	addq	%r14, %rdx
	movq	8(%rbx), %rax
	movslq	-32(%rbp), %rcx
	movq	(%rax,%rcx,8), %rax
	movq	(%rax), %rax
	movslq	-28(%rbp), %rcx
	shlq	$4, %rcx
	cmpq	(%rax,%rcx), %rdx
	jbe	LBB0_8
## %bb.7:
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_2
LBB0_8:
	addq	8(%rax,%rcx), %r14
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_RXE_MEM_STATE_VALID,8,3        ## @RXE_MEM_STATE_VALID
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"mem not in valid state\n"

L_.str.1:                               ## @.str.1
	.asciz	"range violation\n"

L_.str.2:                               ## @.str.2
	.asciz	"crosses page boundary\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iova_to_vaddr                  ; -- Begin function iova_to_vaddr
	.p2align	2
_iova_to_vaddr:                         ; @iova_to_vaddr
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _RXE_MEM_STATE_VALID@GOTPAGE
Lloh1:
	ldr	x9, [x9, _RXE_MEM_STATE_VALID@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	mov	x19, x1
	mov	x21, x0
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_6
; %bb.2:
	mov	x20, x2
	mov	x0, x21
	mov	x1, x19
	bl	_mem_check_range
	cbz	x0, LBB0_7
; %bb.3:
Lloh3:
	adrp	x0, l_.str.1@PAGE
Lloh4:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_5
LBB0_4:
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
LBB0_5:
	bl	_pr_warn
	mov	x19, #0
LBB0_6:
	mov	x0, x19
	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
	add	sp, sp, #64
	ret
LBB0_7:
	add	x2, sp, #4
	mov	x3, sp
	add	x4, sp, #8
	mov	x0, x21
	mov	x1, x19
	bl	_lookup_iova
	ldr	x8, [sp, #8]
	add	x11, x8, w20, sxtw
	ldr	x9, [x21, #8]
	ldrsw	x10, [sp, #4]
	ldr	x9, [x9, x10, lsl #3]
	ldr	x9, [x9]
	ldrsw	x10, [sp]
	lsl	x12, x10, #4
	ldr	x12, [x9, x12]
	cmp	x11, x12
	b.ls	LBB0_9
; %bb.8:
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_5
LBB0_9:
	add	x9, x9, x10, lsl #4
	ldr	x9, [x9, #8]
	add	x19, x9, x8
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_RXE_MEM_STATE_VALID,8,3        ; @RXE_MEM_STATE_VALID
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"mem not in valid state\n"

l_.str.1:                               ; @.str.1
	.asciz	"range violation\n"

l_.str.2:                               ; @.str.2
	.asciz	"crosses page boundary\n"

.subsections_via_symbols
