	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vc4_wait_for_seqno             ## -- Begin function vc4_wait_for_seqno
	.p2align	4, 0x90
_vc4_wait_for_seqno:                    ## @vc4_wait_for_seqno
	.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
	movl	%ecx, %r12d
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rbx
	movq	%rdi, %r14
	callq	_to_vc4_dev
	movq	%rax, %r13
	movq	_wait@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_DEFINE_WAIT
	xorl	%r15d, %r15d
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	cmpq	%rbx, (%r13)
	jge	LBB0_13
## %bb.1:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movq	_jiffies@GOTPCREL(%rip), %rcx
	movq	%r14, %rbx
	movq	(%rcx), %r14
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_nsecs_to_jiffies
	movq	%rax, %r15
	addq	%r14, %r15
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	%rbx, %rdx
	callq	_trace_vc4_wait_for_seqno_begin
	movq	%r13, %rax
	addq	$8, %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_4 Depth=1
	xorl	%eax, %eax
	callq	_schedule
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	_TASK_INTERRUPTIBLE@GOTPCREL(%rip), %rax
	testl	%r12d, %r12d
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	_TASK_UNINTERRUPTIBLE@GOTPCREL(%rip), %rax
LBB0_6:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	(%rax), %edx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	_wait@GOTPCREL(%rip), %rsi
	callq	_prepare_to_wait
	testl	%r12d, %r12d
	je	LBB0_10
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_signal_pending
	testq	%rax, %rax
	jne	LBB0_8
LBB0_10:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	cmpq	%rax, (%r13)
	jge	LBB0_11
## %bb.14:                              ##   in Loop: Header=BB0_4 Depth=1
	cmpq	$-1, %rbx
	je	LBB0_18
## %bb.15:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_jiffies@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	movq	%r15, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	jne	LBB0_16
## %bb.17:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	%r15, %rdi
	subq	(%r14), %rdi
	callq	_schedule_timeout
	jmp	LBB0_4
LBB0_2:
	movq	_ETIME@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_13
LBB0_11:
	xorl	%r15d, %r15d
	jmp	LBB0_12
LBB0_8:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_16:
	movq	_ETIME@GOTPCREL(%rip), %rax
LBB0_9:
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_12:
	movq	_wait@GOTPCREL(%rip), %rsi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_finish_wait
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_trace_vc4_wait_for_seqno_end
LBB0_13:
	movl	%r15d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_wait,4,2                       ## @wait
	.comm	_ETIME,4,2                      ## @ETIME
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_TASK_INTERRUPTIBLE,4,2         ## @TASK_INTERRUPTIBLE
	.comm	_TASK_UNINTERRUPTIBLE,4,2       ## @TASK_UNINTERRUPTIBLE
	.comm	_current,4,2                    ## @current
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vc4_wait_for_seqno             ; -- Begin function vc4_wait_for_seqno
	.p2align	2
_vc4_wait_for_seqno:                    ; @vc4_wait_for_seqno
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x21, x3
	mov	x22, x2
	mov	x19, x1
	mov	x24, x0
	bl	_to_vc4_dev
	mov	x23, x0
Lloh0:
	adrp	x8, _wait@GOTPAGE
Lloh1:
	ldr	x8, [x8, _wait@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_DEFINE_WAIT
	ldr	x8, [x23]
	cmp	x8, x19
	b.ge	LBB0_10
; %bb.1:
	cbz	x22, LBB0_11
; %bb.2:
Lloh3:
	adrp	x27, _jiffies@GOTPAGE
Lloh4:
	ldr	x27, [x27, _jiffies@GOTPAGEOFF]
	ldr	x20, [x27]
	mov	x0, x22
	bl	_nsecs_to_jiffies
	add	x25, x0, x20
	str	x24, [sp, #8]                   ; 8-byte Folded Spill
	mov	x0, x24
	mov	x1, x19
	mov	x2, x22
	bl	_trace_vc4_wait_for_seqno_begin
	add	x24, x23, #8
Lloh5:
	adrp	x28, _TASK_INTERRUPTIBLE@GOTPAGE
Lloh6:
	ldr	x28, [x28, _TASK_INTERRUPTIBLE@GOTPAGEOFF]
Lloh7:
	adrp	x20, _TASK_UNINTERRUPTIBLE@GOTPAGE
Lloh8:
	ldr	x20, [x20, _TASK_UNINTERRUPTIBLE@GOTPAGEOFF]
Lloh9:
	adrp	x26, _wait@GOTPAGE
Lloh10:
	ldr	x26, [x26, _wait@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	bl	_schedule
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w21, #0
	csel	x8, x20, x28, eq
	ldr	w2, [x8]
	mov	x0, x24
	mov	x1, x26
	bl	_prepare_to_wait
	cbz	w21, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
Lloh11:
	adrp	x8, _current@GOTPAGE
Lloh12:
	ldr	x8, [x8, _current@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_signal_pending
	cbnz	x0, LBB0_13
LBB0_6:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x23]
	cmp	x8, x19
	b.ge	LBB0_12
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	cmn	x22, #1
	b.eq	LBB0_3
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x0, [x27]
	mov	x1, x25
	bl	_time_after_eq
	cbnz	x0, LBB0_14
; %bb.9:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x27]
	sub	x0, x25, x8
	bl	_schedule_timeout
	b	LBB0_4
LBB0_10:
	mov	w21, #0
	b	LBB0_17
LBB0_11:
Lloh14:
	adrp	x8, _ETIME@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ETIME@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_17
LBB0_12:
	mov	w21, #0
	b	LBB0_16
LBB0_13:
Lloh17:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
	b	LBB0_15
LBB0_14:
Lloh19:
	adrp	x8, _ETIME@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ETIME@GOTPAGEOFF]
LBB0_15:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_16:
Lloh21:
	adrp	x1, _wait@GOTPAGE
Lloh22:
	ldr	x1, [x1, _wait@GOTPAGEOFF]
	mov	x0, x24
	bl	_finish_wait
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	mov	x1, x19
	bl	_trace_vc4_wait_for_seqno_end
LBB0_17:
	mov	x0, x21
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_wait,4,2                       ; @wait
	.comm	_ETIME,4,2                      ; @ETIME
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_TASK_INTERRUPTIBLE,4,2         ; @TASK_INTERRUPTIBLE
	.comm	_TASK_UNINTERRUPTIBLE,4,2       ; @TASK_UNINTERRUPTIBLE
	.comm	_current,4,2                    ; @current
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
.subsections_via_symbols
