	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mlx4_ib_mmap
_mlx4_ib_mmap:                          ## @mlx4_ib_mmap
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movl	(%rdi), %edi
	callq	_to_mdev
	movq	%rax, %rbx
	movl	(%r15), %eax
	cmpl	$3, %eax
	je	LBB0_7
## %bb.1:
	cmpl	$1, %eax
	je	LBB0_5
## %bb.2:
	testl	%eax, %eax
	jne	LBB0_9
## %bb.3:
	movq	%r14, %rdi
	callq	_to_mucontext
	movl	(%rax), %r12d
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	4(%r15), %edi
	callq	_pgprot_noncached
	movq	%r14, %rdi
	movq	%r15, %rsi
	movl	%r12d, %edx
	movl	%ebx, %ecx
	jmp	LBB0_4
LBB0_7:
	movq	(%rbx), %rdi
	leaq	-40(%rbp), %rsi
	callq	_mlx4_get_internal_clock_params
	testl	%eax, %eax
	jne	LBB0_10
## %bb.8:
	movq	(%rbx), %rax
	movq	(%rax), %rax
	movl	(%rax), %edi
	movl	-36(%rbp), %esi
	callq	_pci_resource_start
	movl	%eax, %ebx
	addl	-40(%rbp), %ebx
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %ebx
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	4(%r15), %edi
	callq	_pgprot_noncached
	movq	%r14, %rdi
	movq	%r15, %rsi
	movl	%ebx, %edx
	movl	%r12d, %ecx
	movl	%eax, %r8d
	callq	_rdma_user_mmap_io
	jmp	LBB0_10
LBB0_5:
	movq	(%rbx), %rax
	cmpl	$0, 12(%rax)
	je	LBB0_9
## %bb.6:
	movq	%r14, %rdi
	callq	_to_mucontext
	movq	(%rbx), %rcx
	movl	8(%rcx), %ebx
	addl	(%rax), %ebx
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	4(%r15), %edi
	callq	_pgprot_writecombine
	movq	%r14, %rdi
	movq	%r15, %rsi
	movl	%ebx, %edx
	movl	%r12d, %ecx
LBB0_4:
	movl	%eax, %r8d
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_rdma_user_mmap_io              ## TAILCALL
LBB0_9:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_10:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.no_dead_strip	_mlx4_ib_mmap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mlx4_ib_mmap
_mlx4_ib_mmap:                          ; @mlx4_ib_mmap
	.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
	mov	x19, x1
	mov	x20, x0
	ldr	w0, [x0]
	bl	_to_mdev
	mov	x21, x0
	ldr	w8, [x19]
	cmp	w8, #3
	b.eq	LBB0_4
; %bb.1:
	cmp	w8, #1
	b.eq	LBB0_6
; %bb.2:
	cbnz	w8, LBB0_9
; %bb.3:
	mov	x0, x20
	bl	_to_mucontext
	ldr	w21, [x0]
Lloh0:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	ldr	w0, [x19, #4]
	bl	_pgprot_noncached
	b	LBB0_8
LBB0_4:
	ldr	x0, [x21]
	add	x1, sp, #8
	bl	_mlx4_get_internal_clock_params
	cbnz	w0, LBB0_10
; %bb.5:
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldr	w0, [x8]
	ldr	w1, [sp, #12]
	bl	_pci_resource_start
	ldr	w8, [sp, #8]
	add	w8, w8, w0
Lloh3:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	asr	w21, w8, w9
Lloh6:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	w22, [x8]
	ldr	w0, [x19, #4]
	bl	_pgprot_noncached
	mov	x4, x0
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	mov	x3, x22
	bl	_rdma_user_mmap_io
	b	LBB0_10
LBB0_6:
	ldr	x8, [x21]
	ldr	w8, [x8, #12]
	cbz	w8, LBB0_9
; %bb.7:
	mov	x0, x20
	bl	_to_mucontext
	ldr	w8, [x0]
	ldr	x9, [x21]
	ldr	w9, [x9, #8]
	add	w21, w9, w8
Lloh9:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh11:
	ldr	w22, [x8]
	ldr	w0, [x19, #4]
	bl	_pgprot_writecombine
LBB0_8:
	mov	x4, x0
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	mov	x3, x22
	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
	b	_rdma_user_mmap_io
LBB0_9:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_10:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.no_dead_strip	_mlx4_ib_mmap
.subsections_via_symbols
