	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function latency_runtime_event
_latency_runtime_event:                 ## @latency_runtime_event
	.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	%rcx, %r14
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r13
	leaq	L_.str(%rip), %rdx
	movq	%rsi, %rdi
	movq	%rbx, %rsi
	callq	_perf_evsel__intval
	movq	%rax, %r12
	leaq	L_.str.1(%rip), %rdx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_perf_evsel__intval
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_machine__findnew_thread
	movq	%rax, %r14
	leaq	4(%r13), %r15
	movq	%r15, %rdi
	movq	%rax, %rsi
	movq	%r13, %rdx
	callq	_thread_atoms_search
	movq	%rax, %r12
	movq	8(%rbx), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %eax
	movq	_MAX_CPUS@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	setge	%cl
	testl	%eax, %eax
	sets	%al
	orb	%cl, %al
	movzbl	%al, %edi
	callq	_BUG_ON
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	testq	%r12, %r12
	je	LBB0_1
LBB0_5:
	movq	%r12, %rdi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_add_runtime_event
	xorl	%ebx, %ebx
	jmp	LBB0_6
LBB0_1:
	movq	%r15, %r12
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_thread_atoms_insert
	movl	$-1, %ebx
	testq	%rax, %rax
	je	LBB0_2
LBB0_6:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%r13, %rdx
	callq	_thread_atoms_search
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r12
	movq	%rax, %rdi
	movl	$82, %esi
	movq	%r15, %rdx
	callq	_add_sched_out_event
	testq	%rax, %rax
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	jne	LBB0_6
	jmp	LBB0_5
LBB0_3:
	leaq	L_.str.2(%rip), %rdi
	callq	_pr_err
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pid"

L_.str.1:                               ## @.str.1
	.asciz	"runtime"

	.comm	_MAX_CPUS,4,2                   ## @MAX_CPUS
L_.str.2:                               ## @.str.2
	.asciz	"in-event: Internal tree error"

	.no_dead_strip	_latency_runtime_event
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function latency_runtime_event
_latency_runtime_event:                 ; @latency_runtime_event
	.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	x21, x3
	mov	x25, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x2, l_.str@PAGE
Lloh1:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x1
	mov	x1, x25
	bl	_perf_evsel__intval
	mov	x22, x0
Lloh2:
	adrp	x2, l_.str.1@PAGE
Lloh3:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x1, x25
	bl	_perf_evsel__intval
	mov	x19, x0
	mov	x0, x21
	mov	x1, x22
	bl	_machine__findnew_thread
	mov	x22, x0
	add	x23, x20, #4
	mov	x0, x23
	mov	x1, x22
	mov	x2, x20
	bl	_thread_atoms_search
	mov	x24, x0
	ldr	x21, [x25, #8]
	ldr	w8, [x25]
Lloh4:
	adrp	x9, _MAX_CPUS@GOTPAGE
Lloh5:
	ldr	x9, [x9, _MAX_CPUS@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	cmp	w8, #0
	ccmp	w8, w9, #0, ge
	cset	w0, ge
	bl	_BUG_ON
	cbz	x24, LBB0_2
LBB0_1:
	mov	x0, x24
	mov	x1, x19
	mov	x2, x21
	bl	_add_runtime_event
	mov	w0, #0
	b	LBB0_4
LBB0_2:
	mov	x0, x20
	mov	x1, x22
	bl	_thread_atoms_insert
	cbz	x0, LBB0_5
LBB0_3:
	mov	w0, #-1
LBB0_4:
	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
LBB0_5:
	mov	x0, x23
	mov	x1, x22
	mov	x2, x20
	bl	_thread_atoms_search
	cbz	x0, LBB0_7
; %bb.6:
	mov	x24, x0
	mov	w1, #82
	mov	x2, x21
	bl	_add_sched_out_event
	cbnz	x0, LBB0_3
	b	LBB0_1
LBB0_7:
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_err
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pid"

l_.str.1:                               ; @.str.1
	.asciz	"runtime"

	.comm	_MAX_CPUS,4,2                   ; @MAX_CPUS
l_.str.2:                               ; @.str.2
	.asciz	"in-event: Internal tree error"

	.no_dead_strip	_latency_runtime_event
.subsections_via_symbols
