	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_vm_create              ## -- Begin function nouveau_vm_create
	.p2align	4, 0x90
_nouveau_vm_create:                     ## @nouveau_vm_create
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -56(%rbp)                  ## 8-byte Spill
	movl	%r8d, -44(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r12d
	movl	%edx, %r13d
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$48, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	addl	%r14d, %r13d
	leaq	40(%rax), %rdi
	callq	_INIT_LIST_HEAD
	movq	%r15, 32(%rbx)
	movl	$1, (%rbx)
	movb	(%r15), %cl
	addb	$12, %cl
	sarl	%cl, %r14d
	movl	%r14d, 4(%rbx)
	leal	-1(%r13), %edi
	sarl	%cl, %edi
	movl	%edi, 8(%rbx)
	subl	%r14d, %edi
	incl	%edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$48, %esi
	callq	_kcalloc
	movq	%rax, 16(%rbx)
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	subl	%r12d, %r13d
	movq	%rbx, %rdi
	addq	$24, %rdi
	sarl	$12, %r12d
	sarl	$12, %r13d
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	sarl	$12, %ecx
	movl	%r12d, %esi
	movl	%r13d, %edx
	callq	_nouveau_mm_init
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movl	%eax, %r14d
	movq	16(%rbx), %rdi
	callq	_kfree
	movq	%rbx, %rdi
	callq	_kfree
	jmp	LBB0_7
LBB0_3:
	movq	%rbx, %rdi
	callq	_kfree
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_7
LBB0_6:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%rbx, (%rax)
	xorl	%r14d, %r14d
LBB0_7:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_vm_create              ; -- Begin function nouveau_vm_create
	.p2align	2
_nouveau_vm_create:                     ; @nouveau_vm_create
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x5
	mov	x21, x4
	mov	x22, x3
	mov	x25, x2
	mov	x23, x1
	mov	x24, x0
Lloh0:
	adrp	x26, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x26, [x26, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x26]
	mov	w0, #48
	bl	_kzalloc
	cbz	x0, LBB0_5
; %bb.1:
	mov	x20, x0
	add	w25, w25, w23
	add	x0, x0, #40
	bl	_INIT_LIST_HEAD
	str	x24, [x20, #32]
	mov	w8, #1
	ldr	w9, [x24]
	add	w9, w9, #12
	asr	w10, w23, w9
	stp	w8, w10, [x20]
	sub	w8, w25, #1
	asr	w8, w8, w9
	str	w8, [x20, #8]
	sub	w8, w8, w10
	add	w0, w8, #1
	ldr	w2, [x26]
	mov	w1, #48
	bl	_kcalloc
	str	x0, [x20, #16]
	cbz	x0, LBB0_4
; %bb.2:
	asr	w1, w22, #12
	sub	w8, w25, w22
	add	x0, x20, #24
	asr	w2, w8, #12
	asr	w3, w21, #12
	bl	_nouveau_mm_init
	mov	x21, x0
	cbz	w0, LBB0_6
; %bb.3:
	ldr	x0, [x20, #16]
	bl	_kfree
	mov	x0, x20
	bl	_kfree
	b	LBB0_7
LBB0_4:
	mov	x0, x20
	bl	_kfree
LBB0_5:
Lloh2:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_7
LBB0_6:
	str	x20, [x19]
LBB0_7:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
