	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mmap_ureg
_mmap_ureg:                             ## @mmap_ureg
	.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	%rdx, %r14
	movq	_QIB_HAS_HDRSUPP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rsi)
	setne	%cl
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	shlq	%cl, %rax
	movq	(%rdi), %rdx
	subq	8(%rdi), %rdx
	cmpq	%rax, %rdx
	jbe	LBB0_2
## %bb.1:
	movl	16(%rsi), %edi
	leaq	L_.str(%rip), %rsi
	callq	_qib_devinfo
	movq	_EFAULT@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_2:
	movq	%rdi, %rbx
	addq	8(%rsi), %r14
	movl	20(%rdi), %edi
	callq	_pgprot_noncached
	movl	%eax, 20(%rbx)
	movq	_VM_DONTCOPY@GOTPCREL(%rip), %rcx
	movq	_VM_DONTEXPAND@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	orl	%edx, 16(%rbx)
	movq	(%rbx), %r8
	movq	8(%rbx), %rsi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shrq	%cl, %r14
	subq	%rsi, %r8
	movq	%rbx, %rdi
	movq	%r14, %rdx
	movq	%r8, %rcx
	movl	%eax, %r8d
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_io_remap_pfn_range             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_QIB_HAS_HDRSUPP,4,2            ## @QIB_HAS_HDRSUPP
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"FAIL mmap userreg: reqlen %lx > PAGE\n"

	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_VM_DONTCOPY,4,2                ## @VM_DONTCOPY
	.comm	_VM_DONTEXPAND,4,2              ## @VM_DONTEXPAND
	.comm	_PAGE_SHIFT,8,3                 ## @PAGE_SHIFT
	.no_dead_strip	_mmap_ureg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mmap_ureg
_mmap_ureg:                             ; @mmap_ureg
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _QIB_HAS_HDRSUPP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _QIB_HAS_HDRSUPP@GOTPAGEOFF]
	ldr	w9, [x1]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w9
	cset	w8, ne
Lloh3:
	adrp	x9, _PAGE_SIZE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PAGE_SIZE@GOTPAGEOFF]
Lloh5:
	ldrsw	x9, [x9]
	lsl	x9, x9, x8
	ldp	x8, x10, [x0]
	sub	x8, x8, x10
	cmp	x8, x9
	b.ls	LBB0_2
; %bb.1:
	ldr	w0, [x1, #16]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x8
	bl	_qib_devinfo
Lloh8:
	adrp	x8, _EFAULT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_2:
	mov	x19, x0
	ldr	x8, [x1, #8]
	add	x20, x8, x2
	ldr	w0, [x0, #20]
	bl	_pgprot_noncached
	mov	x4, x0
Lloh11:
	adrp	x8, _VM_DONTCOPY@GOTPAGE
Lloh12:
	ldr	x8, [x8, _VM_DONTCOPY@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	adrp	x9, _VM_DONTEXPAND@GOTPAGE
Lloh15:
	ldr	x9, [x9, _VM_DONTEXPAND@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x19, #16]
	orr	w8, w8, w9
	stp	w8, w0, [x19, #16]
Lloh17:
	adrp	x8, _PAGE_SHIFT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _PAGE_SHIFT@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	lsr	x2, x20, x8
	ldp	x8, x1, [x19]
	sub	x3, x8, x1
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_io_remap_pfn_range
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_QIB_HAS_HDRSUPP,4,2            ; @QIB_HAS_HDRSUPP
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"FAIL mmap userreg: reqlen %lx > PAGE\n"

	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_VM_DONTCOPY,4,2                ; @VM_DONTCOPY
	.comm	_VM_DONTEXPAND,4,2              ; @VM_DONTEXPAND
	.comm	_PAGE_SHIFT,8,3                 ; @PAGE_SHIFT
	.no_dead_strip	_mmap_ureg
.subsections_via_symbols
