	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nv50_vm_map_sg
_nv50_vm_map_sg:                        ## @nv50_vm_map_sg
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_NV_MEM_ACCESS_NOSNOOP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%rdi), %eax
	cmpl	$1, %eax
	movl	$3, %eax
	sbbl	$0, %eax
	testl	%r8d, %r8d
	je	LBB0_3
## %bb.1:
	movl	%ecx, %ebx
	movq	%rsi, %r12
	shll	$3, %ebx
	movl	%r8d, %ecx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	movq	%r9, -80(%rbp)                  ## 8-byte Spill
	movq	%rdx, -72(%rbp)                 ## 8-byte Spill
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r9,%r14,4), %esi
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_vm_addr
	movl	%eax, %r15d
	movl	%eax, %edi
	callq	_lower_32_bits
	movq	%r12, %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
	callq	_nv_wo32
	leal	4(%rbx), %r13d
	movl	%r15d, %edi
	callq	_upper_32_bits
	movq	%r12, %rdi
	movl	%r13d, %esi
	movl	%eax, %edx
	callq	_nv_wo32
	movq	-80(%rbp), %r9                  ## 8-byte Reload
	addl	$8, %ebx
	incq	%r14
	cmpl	%r14d, -56(%rbp)                ## 4-byte Folded Reload
	jne	LBB0_2
LBB0_3:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NV_MEM_ACCESS_NOSNOOP,4,2      ## @NV_MEM_ACCESS_NOSNOOP
	.no_dead_strip	_nv50_vm_map_sg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nv50_vm_map_sg
_nv50_vm_map_sg:                        ; @nv50_vm_map_sg
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _NV_MEM_ACCESS_NOSNOOP@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NV_MEM_ACCESS_NOSNOOP@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	mov	w8, #2
	cinc	w24, w8, ne
	cbz	w4, LBB0_3
; %bb.1:
	mov	x19, x5
	mov	x20, x4
	mov	x21, x2
	mov	x22, x1
	mov	x23, x0
	lsl	w25, w3, #3
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	sub	w20, w20, #1
	ldr	w1, [x19], #4
	ldr	w2, [x21]
	mov	x0, x23
	mov	x3, x24
	bl	_vm_addr
	mov	x26, x0
	bl	_lower_32_bits
	mov	x2, x0
	mov	x0, x22
	mov	x1, x25
	bl	_nv_wo32
	add	w27, w25, #4
	mov	x0, x26
	bl	_upper_32_bits
	mov	x2, x0
	mov	x0, x22
	mov	x1, x27
	bl	_nv_wo32
	add	w25, w25, #8
	cbnz	w20, LBB0_2
LBB0_3:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_NV_MEM_ACCESS_NOSNOOP,4,2      ; @NV_MEM_ACCESS_NOSNOOP
	.no_dead_strip	_nv50_vm_map_sg
.subsections_via_symbols
