	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qib_map_phys_fmr               ## -- Begin function qib_map_phys_fmr
	.p2align	4, 0x90
_qib_map_phys_fmr:                      ## @qib_map_phys_fmr
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r13
	movl	%edx, %r15d
	movq	%rsi, %r12
	movq	%rdi, %r14
	callq	_to_ifmr
	movq	%rax, %rbx
	leaq	40(%rax), %rdi
	callq	_atomic_read
	cmpl	$3, %eax
	jl	LBB0_3
## %bb.1:
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_3:
	cmpl	%r15d, (%rbx)
	jge	LBB0_5
## %bb.4:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_9
LBB0_5:
	movl	(%r14), %edi
	callq	_to_idev
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_spin_lock_irqsave
	movq	%r13, 32(%rbx)
	movq	%r13, 24(%rbx)
	movb	4(%rbx), %cl
	movl	$1, %r10d
	shll	%cl, %r10d
	movl	%r15d, %edx
	shll	%cl, %edx
	movl	%edx, 8(%rbx)
	testl	%r15d, %r15d
	jle	LBB0_8
## %bb.6:
	movq	16(%rbx), %r13
	movl	%r15d, %r11d
	xorl	%r8d, %r8d
	movq	_QIB_SEGSZ@GOTPCREL(%rip), %r9
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12,%rbx,8), %r15
	movl	%edi, %edx
	movq	(%r13,%rdx,8), %rcx
	movq	(%rcx), %rcx
	movslq	%esi, %rsi
	movq	%rsi, %rax
	shlq	$4, %rax
	movq	%r15, 8(%rcx,%rax)
	movq	(%r13,%rdx,8), %rcx
	movq	(%rcx), %rcx
	movl	%r10d, (%rcx,%rax)
	incl	%esi
	xorl	%eax, %eax
	cmpl	(%r9), %esi
	cmovel	%r8d, %esi
	sete	%al
	addl	%eax, %edi
	incq	%rbx
	cmpq	%rbx, %r11
	jne	LBB0_7
LBB0_8:
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	xorl	%eax, %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_QIB_SEGSZ,4,2                  ## @QIB_SEGSZ
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qib_map_phys_fmr               ; -- Begin function qib_map_phys_fmr
	.p2align	2
_qib_map_phys_fmr:                      ; @qib_map_phys_fmr
	.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	x23, x3
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	bl	_to_ifmr
	mov	x22, x0
	add	x0, x0, #40
	bl	_atomic_read
	cmp	w0, #3
	b.lt	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EBUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
	ldr	w8, [x22]
	cmp	w8, w21
	b.ge	LBB0_5
; %bb.3:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_9
LBB0_5:
	ldr	w0, [x20]
	bl	_to_idev
	mov	x20, x0
	bl	_spin_lock_irqsave
	stp	x23, x23, [x22, #24]
	ldr	w10, [x22, #4]
	lsl	w8, w21, w10
	str	w8, [x22, #8]
	cmp	w21, #1
	b.lt	LBB0_8
; %bb.6:
	mov	w8, #0
	mov	w9, #0
	mov	w11, #1
	lsl	w10, w11, w10
	ldr	x11, [x22, #16]
	mov	w12, w21
Lloh4:
	adrp	x13, _QIB_SEGSZ@GOTPAGE
Lloh5:
	ldr	x13, [x13, _QIB_SEGSZ@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x14, [x19], #8
	mov	w15, w9
	lsl	x15, x15, #3
	ldr	x16, [x11, x15]
	ldr	x16, [x16]
	sbfiz	x17, x8, #4, #32
	add	x16, x16, x17
	str	x14, [x16, #8]
	ldr	x14, [x11, x15]
	ldr	x14, [x14]
	str	w10, [x14, x17]
	add	w14, w8, #1
	ldr	w15, [x13]
	cmp	w14, w15
	cinc	w9, w9, eq
	csinc	w8, wzr, w8, eq
	subs	x12, x12, #1
	b.ne	LBB0_7
LBB0_8:
	mov	x0, x20
	bl	_spin_unlock_irqrestore
	mov	w0, #0
LBB0_9:
	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
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_QIB_SEGSZ,4,2                  ; @QIB_SEGSZ
.subsections_via_symbols
