	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nv50_bar_oneinit               ## -- Begin function nv50_bar_oneinit
	.p2align	4, 0x90
_nv50_bar_oneinit:                      ## @nv50_bar_oneinit
	.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
	callq	_nv50_bar
	movq	%rax, %r15
	movq	40(%rax), %r14
	leaq	16(%rax), %r13
	movq	%r14, %rdi
	movl	$131072, %esi                   ## imm = 0x20000
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	movq	%r13, %r9
	callq	_nvkm_gpuobj_new
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.1:
	movl	(%r15), %esi
	movq	16(%r15), %r8
	leaq	72(%r15), %r9
	movq	%r14, %rdi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_nvkm_gpuobj_new
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.2:
	movq	16(%r15), %r8
	leaq	64(%r15), %r9
	movq	%r14, %rdi
	movl	$16384, %esi                    ## imm = 0x4000
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_nvkm_gpuobj_new
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_3
LBB0_15:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	(%r14), %rax
	movq	%r14, %rdi
	movl	$3, %esi
	callq	*(%rax)
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movslq	%eax, %rdx
	leaq	56(%r15), %r12
	leaq	L_.str(%rip), %rax
	leaq	_nv50_bar_oneinit.bar2_lock(%rip), %r9
	movq	%r14, %rdi
	xorl	%esi, %esi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	pushq	%r12
	pushq	%rax
	callq	_nvkm_vmm_new
	addq	$16, %rsp
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.6:
	movq	56(%r15), %rax
	movq	_NVKM_SUBDEV_BAR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	shlq	$2, %rdi
	addq	8(%rax), %rdi
	callq	_atomic_inc
	movl	36(%r15), %eax
	movq	56(%r15), %rdi
	movl	%eax, (%rdi)
	callq	_nvkm_vmm_boot
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.7:
	movq	(%r12), %rdi
	movq	(%r13), %rax
	movl	(%rax), %esi
	callq	_nvkm_vmm_join
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.8:
	movq	16(%r15), %r8
	leaq	48(%r15), %r9
	movq	%r14, %rdi
	movl	$24, %esi
	movl	$16, %edx
	xorl	%ecx, %ecx
	callq	_nvkm_gpuobj_new
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.9:
	movl	-44(%rbp), %r12d                ## 4-byte Reload
	decl	%r12d
	movq	48(%r15), %rdi
	callq	_nvkm_kmap
	movq	48(%r15), %rdi
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	movl	$2143289344, %edx               ## imm = 0x7FC00000
	callq	_nvkm_wo32
	movq	48(%r15), %r13
	movl	%r12d, %edi
	callq	_lower_32_bits
	movq	%r13, %rdi
	movl	$4, %esi
	movl	%eax, %edx
	callq	_nvkm_wo32
	movq	48(%r15), %r13
	xorl	%edi, %edi
	callq	_lower_32_bits
	movq	%r13, %rdi
	movl	$8, %esi
	movl	%eax, %edx
	callq	_nvkm_wo32
	movq	48(%r15), %r13
	movl	%r12d, %edi
	callq	_upper_32_bits
	movl	%eax, %r12d
	shll	$24, %r12d
	xorl	%edi, %edi
	callq	_upper_32_bits
	orl	%eax, %r12d
	movq	%r13, %rdi
	movl	$12, %esi
	movl	%r12d, %edx
	callq	_nvkm_wo32
	movq	48(%r15), %rdi
	movl	$16, %esi
	xorl	%edx, %edx
	callq	_nvkm_wo32
	movq	48(%r15), %rdi
	movl	$20, %esi
	xorl	%edx, %edx
	callq	_nvkm_wo32
	movq	48(%r15), %rdi
	callq	_nvkm_done
	movl	$1, 32(%r15)
	movq	%r14, %rdi
	callq	_nvkm_bar_bar2_init
	movq	(%r14), %rax
	movq	%r14, %rdi
	movl	$1, %esi
	callq	*(%rax)
	testl	%eax, %eax
	je	LBB0_10
## %bb.11:
	movl	%eax, %r12d
	movslq	%eax, %rdx
	leaq	24(%r15), %rax
	leaq	L_.str.1(%rip), %rbx
	leaq	_nv50_bar_oneinit.bar1_lock(%rip), %r9
	movq	%r14, %rdi
	xorl	%esi, %esi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	pushq	%rax
	pushq	%rbx
	callq	_nvkm_vmm_new
	addq	$16, %rsp
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.12:
	movq	24(%r15), %rax
	movq	_NVKM_SUBDEV_BAR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	shlq	$2, %rdi
	addq	8(%rax), %rdi
	callq	_atomic_inc
	movl	36(%r15), %eax
	movq	24(%r15), %rdi
	movl	%eax, (%rdi)
	movq	16(%r15), %rax
	movl	(%rax), %esi
	callq	_nvkm_vmm_join
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.13:
	movq	16(%r15), %r8
	addq	$8, %r15
	movq	%r14, %rdi
	movl	$24, %esi
	movl	$16, %edx
	xorl	%ecx, %ecx
	movq	%r15, %r9
	callq	_nvkm_gpuobj_new
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.14:
	decl	%r12d
	movq	(%r15), %rdi
	callq	_nvkm_kmap
	movq	(%r15), %rdi
	xorl	%esi, %esi
	movl	$2143289344, %edx               ## imm = 0x7FC00000
	callq	_nvkm_wo32
	movq	(%r15), %rbx
	movl	%r12d, %edi
	callq	_lower_32_bits
	movq	%rbx, %rdi
	movl	$4, %esi
	movl	%eax, %edx
	callq	_nvkm_wo32
	movq	(%r15), %rbx
	xorl	%edi, %edi
	callq	_lower_32_bits
	movq	%rbx, %rdi
	movl	$8, %esi
	movl	%eax, %edx
	callq	_nvkm_wo32
	movq	(%r15), %r14
	movl	%r12d, %edi
	callq	_upper_32_bits
	movl	%eax, %ebx
	shll	$24, %ebx
	xorl	%edi, %edi
	callq	_upper_32_bits
	orl	%eax, %ebx
	movq	%r14, %rdi
	movl	$12, %esi
	movl	%ebx, %edx
	callq	_nvkm_wo32
	movq	(%r15), %rdi
	movl	$16, %esi
	xorl	%edx, %edx
	callq	_nvkm_wo32
	movq	(%r15), %rdi
	movl	$20, %esi
	xorl	%edx, %edx
	callq	_nvkm_wo32
	movq	(%r15), %rdi
	callq	_nvkm_done
	xorl	%ebx, %ebx
	jmp	LBB0_15
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_15
LBB0_10:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_nv50_bar_oneinit.bar1_lock,4,2 ## @nv50_bar_oneinit.bar1_lock
.zerofill __DATA,__bss,_nv50_bar_oneinit.bar2_lock,4,2 ## @nv50_bar_oneinit.bar2_lock
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"bar2"

	.comm	_NVKM_SUBDEV_BAR,8,3            ## @NVKM_SUBDEV_BAR
L_.str.1:                               ## @.str.1
	.asciz	"bar1"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nv50_bar_oneinit               ; -- Begin function nv50_bar_oneinit
	.p2align	2
_nv50_bar_oneinit:                      ; @nv50_bar_oneinit
	.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
	bl	_nv50_bar
	mov	x20, x0
	ldr	x19, [x0, #40]
	add	x21, x0, #16
	mov	x0, x19
	mov	w1, #131072
	mov	w2, #0
	mov	w3, #0
	mov	x4, #0
	mov	x5, x21
	bl	_nvkm_gpuobj_new
	cbnz	w0, LBB0_3
; %bb.1:
	ldr	w1, [x20]
	ldr	x4, [x20, #16]
	add	x5, x20, #72
	mov	x0, x19
	mov	w2, #0
	mov	w3, #0
	bl	_nvkm_gpuobj_new
	cbnz	w0, LBB0_3
; %bb.2:
	ldr	x4, [x20, #16]
	add	x5, x20, #64
	mov	x0, x19
	mov	w1, #16384
	mov	w2, #0
	mov	w3, #0
	bl	_nvkm_gpuobj_new
	cbz	w0, LBB0_4
LBB0_3:
	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
LBB0_4:
	ldr	x8, [x19]
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #3
	blr	x8
	cbz	w0, LBB0_14
; %bb.5:
	mov	x22, x0
	sxtw	x2, w22
	add	x23, x20, #56
Lloh0:
	adrp	x5, _nv50_bar_oneinit.bar2_lock@PAGE
Lloh1:
	add	x5, x5, _nv50_bar_oneinit.bar2_lock@PAGEOFF
Lloh2:
	adrp	x6, l_.str@PAGE
Lloh3:
	add	x6, x6, l_.str@PAGEOFF
	mov	x0, x19
	mov	w1, #0
	mov	x3, #0
	mov	w4, #0
	mov	x7, x23
	bl	_nvkm_vmm_new
	cbnz	w0, LBB0_3
; %bb.6:
	ldr	x8, [x20, #56]
	ldr	x8, [x8, #8]
Lloh4:
	adrp	x24, _NVKM_SUBDEV_BAR@GOTPAGE
Lloh5:
	ldr	x24, [x24, _NVKM_SUBDEV_BAR@GOTPAGEOFF]
	ldr	x9, [x24]
	add	x0, x8, x9, lsl #2
	bl	_atomic_inc
	ldr	w8, [x20, #36]
	ldr	x0, [x20, #56]
	str	w8, [x0]
	bl	_nvkm_vmm_boot
	cbnz	w0, LBB0_3
; %bb.7:
	ldr	x0, [x23]
	ldr	x8, [x21]
	ldr	w1, [x8]
	bl	_nvkm_vmm_join
	cbnz	w0, LBB0_3
; %bb.8:
	ldr	x4, [x20, #16]
	add	x5, x20, #48
	mov	x0, x19
	mov	w1, #24
	mov	w2, #16
	mov	w3, #0
	bl	_nvkm_gpuobj_new
	cbnz	w0, LBB0_3
; %bb.9:
	sub	w21, w22, #1
	ldr	x0, [x20, #48]
	bl	_nvkm_kmap
	ldr	x0, [x20, #48]
	mov	w1, #0
	mov	w2, #2143289344
	bl	_nvkm_wo32
	ldr	x22, [x20, #48]
	mov	x0, x21
	bl	_lower_32_bits
	mov	x2, x0
	mov	x0, x22
	mov	w1, #4
	bl	_nvkm_wo32
	ldr	x22, [x20, #48]
	mov	w0, #0
	bl	_lower_32_bits
	mov	x2, x0
	mov	x0, x22
	mov	w1, #8
	bl	_nvkm_wo32
	ldr	x22, [x20, #48]
	mov	x0, x21
	bl	_upper_32_bits
	mov	x21, x0
	mov	w0, #0
	bl	_upper_32_bits
	orr	w2, w0, w21, lsl #24
	mov	x0, x22
	mov	w1, #12
	bl	_nvkm_wo32
	ldr	x0, [x20, #48]
	mov	w1, #16
	mov	w2, #0
	bl	_nvkm_wo32
	ldr	x0, [x20, #48]
	mov	w1, #20
	mov	w2, #0
	bl	_nvkm_wo32
	ldr	x0, [x20, #48]
	bl	_nvkm_done
	mov	w8, #1
	str	w8, [x20, #32]
	mov	x0, x19
	bl	_nvkm_bar_bar2_init
	ldr	x8, [x19]
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #1
	blr	x8
	cbz	w0, LBB0_14
; %bb.10:
	mov	x21, x0
	sxtw	x2, w21
	add	x7, x20, #24
Lloh6:
	adrp	x5, _nv50_bar_oneinit.bar1_lock@PAGE
Lloh7:
	add	x5, x5, _nv50_bar_oneinit.bar1_lock@PAGEOFF
Lloh8:
	adrp	x6, l_.str.1@PAGE
Lloh9:
	add	x6, x6, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	w1, #0
	mov	x3, #0
	mov	w4, #0
	bl	_nvkm_vmm_new
	cbnz	w0, LBB0_3
; %bb.11:
	ldr	x8, [x20, #24]
	ldr	x8, [x8, #8]
	ldr	x9, [x24]
	add	x0, x8, x9, lsl #2
	bl	_atomic_inc
	ldr	w8, [x20, #36]
	ldp	x9, x0, [x20, #16]
	str	w8, [x0]
	ldr	w1, [x9]
	bl	_nvkm_vmm_join
	cbnz	w0, LBB0_3
; %bb.12:
	ldr	x4, [x20, #16]
	add	x20, x20, #8
	mov	x0, x19
	mov	w1, #24
	mov	w2, #16
	mov	w3, #0
	mov	x5, x20
	bl	_nvkm_gpuobj_new
	cbnz	w0, LBB0_3
; %bb.13:
	sub	w19, w21, #1
	ldr	x0, [x20]
	bl	_nvkm_kmap
	ldr	x0, [x20]
	mov	w1, #0
	mov	w2, #2143289344
	bl	_nvkm_wo32
	ldr	x21, [x20]
	mov	x0, x19
	bl	_lower_32_bits
	mov	x2, x0
	mov	x0, x21
	mov	w1, #4
	bl	_nvkm_wo32
	ldr	x21, [x20]
	mov	w0, #0
	bl	_lower_32_bits
	mov	x2, x0
	mov	x0, x21
	mov	w1, #8
	bl	_nvkm_wo32
	ldr	x21, [x20]
	mov	x0, x19
	bl	_upper_32_bits
	mov	x19, x0
	mov	w0, #0
	bl	_upper_32_bits
	orr	w2, w0, w19, lsl #24
	mov	x0, x21
	mov	w1, #12
	bl	_nvkm_wo32
	ldr	x0, [x20]
	mov	w1, #16
	mov	w2, #0
	bl	_nvkm_wo32
	ldr	x0, [x20]
	mov	w1, #20
	mov	w2, #0
	bl	_nvkm_wo32
	ldr	x0, [x20]
	bl	_nvkm_done
	mov	w0, #0
	b	LBB0_3
LBB0_14:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_3
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_nv50_bar_oneinit.bar1_lock,4,2 ; @nv50_bar_oneinit.bar1_lock
.zerofill __DATA,__bss,_nv50_bar_oneinit.bar2_lock,4,2 ; @nv50_bar_oneinit.bar2_lock
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"bar2"

	.comm	_NVKM_SUBDEV_BAR,8,3            ; @NVKM_SUBDEV_BAR
l_.str.1:                               ; @.str.1
	.asciz	"bar1"

.subsections_via_symbols
