	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function thread_func
_thread_func:                           ## @thread_func
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	(%rdi), %rbx
	movq	8(%rdi), %r13
	callq	_free
	movq	(%r13), %rdx
	leaq	L_.str(%rip), %rsi
	leaq	-80(%rbp), %r14
	movq	%r14, %rdi
	callq	_sprintf
	movq	_PR_SET_NAME@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_prctl
	xorl	%eax, %eax
	callq	_self_open_counters
	testl	%eax, %eax
	js	LBB0_6
## %bb.1:
	movl	%eax, %r14d
	leaq	48(%r13), %rax
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	leaq	4(%rbx), %rax
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
	leaq	24(%r13), %rax
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%r12d, %r14d
	movl	%r12d, %edi
	callq	_get_cpu_usage_nsec_self
	subq	%r15, %rax
	movq	%rax, 32(%r13)
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_sem_post
	movq	%rax, %rdi
	callq	_BUG_ON
	movq	%rbx, %rdi
	callq	_pthread_mutex_lock
	movq	%rax, %rdi
	callq	_BUG_ON
	movq	%rbx, %rdi
	callq	_pthread_mutex_unlock
	movq	%rax, %rdi
	callq	_BUG_ON
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movq	-104(%rbp), %rdi                ## 8-byte Reload
	callq	_sem_post
	movq	%rax, %rdi
	callq	_BUG_ON
	movq	-96(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	callq	_pthread_mutex_lock
	movq	%rax, %rdi
	callq	_BUG_ON
	movq	%r15, %rdi
	callq	_pthread_mutex_unlock
	movq	%rax, %rdi
	callq	_BUG_ON
	movl	%r14d, %r12d
	movl	%r14d, %edi
	callq	_get_cpu_usage_nsec_self
	movq	%rax, %r15
	cmpq	$0, 8(%r13)
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%r14, 16(%r13)
	movq	40(%r13), %rax
	movl	(%rax,%r14,4), %esi
	movq	%rbx, %rdi
	callq	_perf_sched__process_event
	incq	%r14
	cmpq	8(%r13), %r14
	jb	LBB0_4
	jmp	LBB0_5
LBB0_6:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_8
## %bb.7:
	xorl	%eax, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	":%s"

	.comm	_PR_SET_NAME,4,2                ## @PR_SET_NAME
	.no_dead_strip	_thread_func
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function thread_func
_thread_func:                           ; @thread_func
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	ldp	x19, x25, [x0]
	bl	_free
	ldr	x2, [x25]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x0, sp, #2
	bl	_sprintf
Lloh5:
	adrp	x8, _PR_SET_NAME@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PR_SET_NAME@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	add	x1, sp, #2
	bl	_prctl
	bl	_self_open_counters
	tbnz	w0, #31, LBB0_6
; %bb.1:
	mov	x20, x0
	add	x21, x25, #48
	add	x22, x19, #4
	add	x23, x25, #24
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x20
	bl	_get_cpu_usage_nsec_self
	sub	x8, x0, x24
	str	x8, [x25, #32]
	mov	x0, x23
	bl	_sem_post
	bl	_BUG_ON
	mov	x0, x19
	bl	_pthread_mutex_lock
	bl	_BUG_ON
	mov	x0, x19
	bl	_pthread_mutex_unlock
	bl	_BUG_ON
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	mov	x0, x21
	bl	_sem_post
	bl	_BUG_ON
	mov	x0, x22
	bl	_pthread_mutex_lock
	bl	_BUG_ON
	mov	x0, x22
	bl	_pthread_mutex_unlock
	bl	_BUG_ON
	mov	x0, x20
	bl	_get_cpu_usage_nsec_self
	mov	x24, x0
	ldr	x8, [x25, #8]
	cbz	x8, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x26, #0
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	str	x26, [x25, #16]
	ldr	x8, [x25, #40]
	ldr	w1, [x8, x26, lsl #2]
	mov	x0, x19
	bl	_perf_sched__process_event
	add	x26, x26, #1
	ldr	x8, [x25, #8]
	cmp	x26, x8
	b.lo	LBB0_5
	b	LBB0_2
LBB0_6:
	ldr	x8, [sp, #24]
Lloh8:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh9:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_8
; %bb.7:
	mov	x0, #0
	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
	add	sp, sp, #112
	ret
LBB0_8:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	":%s"

	.comm	_PR_SET_NAME,4,2                ; @PR_SET_NAME
	.no_dead_strip	_thread_func
.subsections_via_symbols
