	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function drm_sched_entity_add_dependency_cb
_drm_sched_entity_add_dependency_cb:    ## @drm_sched_entity_add_dependency_cb
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	8(%rdi), %rdi
	movq	(%rdi), %rcx
	cmpq	%rax, %rcx
	je	LBB0_9
## %bb.1:
	incq	%rax
	cmpq	%rax, %rcx
	je	LBB0_9
## %bb.2:
	movq	24(%rbx), %rax
	movq	(%rax), %r14
	callq	_to_drm_sched_fence
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	cmpq	%r14, 8(%rax)
	je	LBB0_7
LBB0_4:
	movq	8(%rbx), %rdi
	leaq	16(%rbx), %rsi
	movq	_drm_sched_entity_wakeup@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_dma_fence_add_callback
	testl	%eax, %eax
	je	LBB0_11
## %bb.5:
	movq	8(%rbx), %rdi
	jmp	LBB0_9
LBB0_7:
	movq	%rax, %rdi
	callq	_dma_fence_get
	movq	%rax, %r14
	movq	8(%rbx), %rdi
	callq	_dma_fence_put
	movq	%r14, 8(%rbx)
	addq	$16, %rbx
	movq	_drm_sched_entity_clear_dep@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_dma_fence_add_callback
	testl	%eax, %eax
	je	LBB0_11
## %bb.8:
	movq	%r14, %rdi
LBB0_9:
	callq	_dma_fence_put
	xorl	%eax, %eax
LBB0_10:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_11:
	movl	$1, %eax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_drm_sched_entity_clear_dep,4,2 ## @drm_sched_entity_clear_dep
	.comm	_drm_sched_entity_wakeup,4,2    ## @drm_sched_entity_wakeup
	.no_dead_strip	_drm_sched_entity_add_dependency_cb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function drm_sched_entity_add_dependency_cb
_drm_sched_entity_add_dependency_cb:    ; @drm_sched_entity_add_dependency_cb
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	x0, [x0, #8]
	ldr	x8, [x19]
	ldr	x9, [x0]
	add	x10, x8, #1
	cmp	x9, x8
	ccmp	x9, x10, #4, ne
	b.eq	LBB0_7
; %bb.1:
	ldr	x8, [x19, #24]
	ldr	x20, [x8]
	bl	_to_drm_sched_fence
	cbz	x0, LBB0_3
; %bb.2:
	ldr	x8, [x0, #8]
	cmp	x8, x20
	b.eq	LBB0_5
LBB0_3:
	ldr	x0, [x19, #8]
	add	x1, x19, #16
Lloh0:
	adrp	x8, _drm_sched_entity_wakeup@GOTPAGE
Lloh1:
	ldr	x8, [x8, _drm_sched_entity_wakeup@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	bl	_dma_fence_add_callback
	cbz	w0, LBB0_9
; %bb.4:
	ldr	x0, [x19, #8]
	b	LBB0_7
LBB0_5:
	bl	_dma_fence_get
	mov	x20, x0
	ldr	x0, [x19, #8]
	bl	_dma_fence_put
	str	x20, [x19, #8]
	add	x1, x19, #16
Lloh3:
	adrp	x8, _drm_sched_entity_clear_dep@GOTPAGE
Lloh4:
	ldr	x8, [x8, _drm_sched_entity_clear_dep@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_dma_fence_add_callback
	cbz	w0, LBB0_9
; %bb.6:
	mov	x0, x20
LBB0_7:
	bl	_dma_fence_put
	mov	w0, #0
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_9:
	mov	w0, #1
	b	LBB0_8
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_drm_sched_entity_clear_dep,4,2 ; @drm_sched_entity_clear_dep
	.comm	_drm_sched_entity_wakeup,4,2    ; @drm_sched_entity_wakeup
	.no_dead_strip	_drm_sched_entity_add_dependency_cb
.subsections_via_symbols
