	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function next_proc
LCPI0_0:
	.quad	-1                              ## 0xffffffffffffffff
	.quad	1000000000                      ## 0x3b9aca00
LCPI0_1:
	.space	16
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_next_proc
	.p2align	4, 0x90
_next_proc:                             ## @next_proc
	.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
	movl	%edi, %ebx
	movq	_sleeping@GOTPCREL(%rip), %rdi
	callq	_TAILQ_EMPTY
	testl	%eax, %eax
	je	LBB0_1
LBB0_22:
	xorl	%r12d, %r12d
LBB0_23:
	movq	%r12, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_sleeping@GOTPCREL(%rip), %r14
	leaq	-48(%rbp), %r15
	leaq	-64(%rbp), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_TAILQ_FIRST
	testq	%rax, %rax
	je	LBB0_3
## %bb.11:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %r12
	cmpq	$0, 8(%rax)
	je	LBB0_3
## %bb.12:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	_CLOCK_REALTIME@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r13, %rsi
	callq	_clock_gettime
	movdqu	8(%r12), %xmm0
	psubq	-64(%rbp), %xmm0
	movdqa	%xmm0, -64(%rbp)
	pextrq	$1, %xmm0, %rax
	testq	%rax, %rax
	js	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%xmm0, %rcx
	testq	%rcx, %rcx
	jns	LBB0_16
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r9d, %r9d
	jmp	LBB0_4
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	paddq	LCPI0_0(%rip), %xmm0
	movdqa	%xmm0, -64(%rbp)
	movq	%xmm0, %rcx
	pextrq	$1, %xmm0, %rax
	testq	%rcx, %rcx
	js	LBB0_17
LBB0_16:                                ##   in Loop: Header=BB0_2 Depth=1
	orq	%rax, %rcx
	movq	%r13, %r9
	je	LBB0_17
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	testl	%ebx, %ebx
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	pxor	%xmm0, %xmm0
	movdqa	%xmm0, -64(%rbp)
	movq	%r13, %r9
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_kq@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	movq	%r15, %rcx
	movl	$1, %r8d
	callq	_kevent
	cmpl	$-1, %eax
	je	LBB0_18
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$1, %eax
	jne	LBB0_8
## %bb.20:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	-44(%rbp), %edi
	movq	_WNOHANG@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%esi, %esi
	callq	_waitpid
	movl	-44(%rbp), %edi
	callq	_find_proc
	testq	%rax, %rax
	je	LBB0_2
	jmp	LBB0_21
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_EINTR@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_2
## %bb.19:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, %edi
	leaq	L_.str(%rip), %rsi
	callq	_err
	jmp	LBB0_2
LBB0_8:
	testl	%eax, %eax
	jne	LBB0_22
## %bb.9:
	testl	%ebx, %ebx
	jne	LBB0_22
## %bb.10:
	movq	_sleeping@GOTPCREL(%rip), %rdi
	callq	_TAILQ_FIRST
	movq	%rax, %r12
LBB0_17:
	movq	_JF_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 4(%r12)
	movq	%r12, %rdi
	callq	_clear_procs
	jmp	LBB0_23
LBB0_21:
	movq	%rax, %r12
	movl	-48(%rbp), %eax
	movl	%eax, (%r12)
	jmp	LBB0_23
	.cfi_endproc
                                        ## -- End function
	.comm	_sleeping,4,2                   ## @sleeping
	.comm	_CLOCK_REALTIME,4,2             ## @CLOCK_REALTIME
	.comm	_JF_TIMEOUT,4,2                 ## @JF_TIMEOUT
	.comm	_kq,4,2                         ## @kq
	.comm	_errno,4,2                      ## @errno
	.comm	_EINTR,4,2                      ## @EINTR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"kevent"

	.comm	_WNOHANG,4,2                    ## @WNOHANG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_next_proc                      ; -- Begin function next_proc
	.p2align	2
_next_proc:                             ; @next_proc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x19, x0
Lloh0:
	adrp	x0, _sleeping@GOTPAGE
Lloh1:
	ldr	x0, [x0, _sleeping@GOTPAGEOFF]
	bl	_TAILQ_EMPTY
	cbz	w0, LBB0_3
LBB0_1:
	mov	x22, #0
LBB0_2:
	mov	x0, x22
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_3:
Lloh2:
	adrp	x20, _sleeping@GOTPAGE
Lloh3:
	ldr	x20, [x20, _sleeping@GOTPAGEOFF]
Lloh4:
	adrp	x23, _kq@GOTPAGE
Lloh5:
	ldr	x23, [x23, _kq@GOTPAGEOFF]
Lloh6:
	adrp	x24, _errno@GOTPAGE
Lloh7:
	ldr	x24, [x24, _errno@GOTPAGEOFF]
Lloh8:
	adrp	x25, _EINTR@GOTPAGE
Lloh9:
	ldr	x25, [x25, _EINTR@GOTPAGEOFF]
Lloh10:
	adrp	x21, l_.str@PAGE
Lloh11:
	add	x21, x21, l_.str@PAGEOFF
Lloh12:
	adrp	x26, _WNOHANG@GOTPAGE
Lloh13:
	ldr	x26, [x26, _WNOHANG@GOTPAGEOFF]
	mov	w27, #51712
	movk	w27, #15258, lsl #16
Lloh14:
	adrp	x28, _CLOCK_REALTIME@GOTPAGE
Lloh15:
	ldr	x28, [x28, _CLOCK_REALTIME@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_TAILQ_FIRST
	cbz	x0, LBB0_11
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x22, x0
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_11
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x28]
	mov	x1, sp
	bl	_clock_gettime
	ldur	q0, [x22, #8]
	ldr	q1, [sp]
	sub.2d	v0, v0, v1
	str	q0, [sp]
	mov.d	x8, v0[1]
	fmov	x9, d0
	tbz	x8, #63, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	sub	x9, x9, #1
	add	x8, x8, x27
	stp	x9, x8, [sp]
LBB0_8:                                 ;   in Loop: Header=BB0_4 Depth=1
	tbnz	x9, #63, LBB0_21
; %bb.9:                                ;   in Loop: Header=BB0_4 Depth=1
	orr	x8, x9, x8
	cbz	x8, LBB0_21
; %bb.10:                               ;   in Loop: Header=BB0_4 Depth=1
	mov	x5, sp
	cbnz	w19, LBB0_12
	b	LBB0_13
LBB0_11:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x5, #0
	cbz	w19, LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x5, sp
	stp	xzr, xzr, [sp]
LBB0_13:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x23]
	add	x3, sp, #24
	mov	x1, #0
	mov	w2, #0
	mov	w4, #1
	bl	_kevent
	cmn	w0, #1
	b.eq	LBB0_16
; %bb.14:                               ;   in Loop: Header=BB0_4 Depth=1
	cmp	w0, #1
	b.ne	LBB0_18
; %bb.15:                               ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [sp, #28]
	ldr	w2, [x26]
	mov	x1, #0
	bl	_waitpid
	ldr	w0, [sp, #28]
	bl	_find_proc
	cbz	x0, LBB0_4
	b	LBB0_22
LBB0_16:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x24]
	ldr	w9, [x25]
	cmp	w8, w9
	b.eq	LBB0_4
; %bb.17:                               ;   in Loop: Header=BB0_4 Depth=1
	mov	w0, #1
	mov	x1, x21
	bl	_err
	b	LBB0_4
LBB0_18:
	cbnz	w0, LBB0_1
; %bb.19:
	cbnz	w19, LBB0_1
; %bb.20:
Lloh16:
	adrp	x0, _sleeping@GOTPAGE
Lloh17:
	ldr	x0, [x0, _sleeping@GOTPAGEOFF]
	bl	_TAILQ_FIRST
	mov	x22, x0
Lloh18:
	adrp	x8, _JF_TIMEOUT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _JF_TIMEOUT@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x0, #4]
	orr	w8, w9, w8
	str	w8, [x0, #4]
	bl	_clear_procs
	b	LBB0_2
LBB0_21:
Lloh21:
	adrp	x8, _JF_TIMEOUT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _JF_TIMEOUT@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	ldr	w9, [x22, #4]
	orr	w8, w9, w8
	str	w8, [x22, #4]
	mov	x0, x22
	bl	_clear_procs
	b	LBB0_2
LBB0_22:
	mov	x22, x0
	ldr	w8, [sp, #24]
	str	w8, [x0]
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_sleeping,4,2                   ; @sleeping
	.comm	_CLOCK_REALTIME,4,2             ; @CLOCK_REALTIME
	.comm	_JF_TIMEOUT,4,2                 ; @JF_TIMEOUT
	.comm	_kq,4,2                         ; @kq
	.comm	_errno,4,2                      ; @errno
	.comm	_EINTR,4,2                      ; @EINTR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"kevent"

	.comm	_WNOHANG,4,2                    ; @WNOHANG
.subsections_via_symbols
