	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rumptest_thread                ## -- Begin function rumptest_thread
	.p2align	4, 0x90
_rumptest_thread:                       ## @rumptest_thread
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_MUTEX_DEFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_IPL_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_mtx@GOTPCREL(%rip), %rdi
	callq	_mutex_init
	movq	_cv@GOTPCREL(%rip), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_cv_init
	movq	_PRI_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_KTHREAD_MPSAFE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_thethread@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str.1(%rip), %rax
	movq	%rax, (%rsp)
	leaq	-32(%rbp), %r9
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	callq	_kthread_create
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	callq	_panic
LBB0_2:
	movq	_mtx@GOTPCREL(%rip), %rdi
	callq	_mutex_enter
	movq	_value@GOTPCREL(%rip), %r15
	cmpq	$0, (%r15)
	jne	LBB0_5
## %bb.3:
	movq	_cv@GOTPCREL(%rip), %r14
	movq	_mtx@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_cv_wait
	cmpq	$0, (%r15)
	je	LBB0_4
LBB0_5:
	movq	_mtx@GOTPCREL(%rip), %rdi
	callq	_mutex_exit
	leaq	L_.str.3(%rip), %rdi
	xorl	%esi, %esi
	movl	$1, %edx
	xorl	%ecx, %ecx
	callq	_kpause
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mtx,4,2                        ## @mtx
	.comm	_MUTEX_DEFAULT,4,2              ## @MUTEX_DEFAULT
	.comm	_IPL_NONE,4,2                   ## @IPL_NONE
	.comm	_cv,4,2                         ## @cv
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"jooei"

	.comm	_PRI_NONE,4,2                   ## @PRI_NONE
	.comm	_KTHREAD_MPSAFE,4,2             ## @KTHREAD_MPSAFE
	.comm	_thethread,4,2                  ## @thethread
L_.str.1:                               ## @.str.1
	.asciz	"ktest"

L_.str.2:                               ## @.str.2
	.asciz	"thread creation failed: %d"

	.comm	_value,8,3                      ## @value
L_.str.3:                               ## @.str.3
	.asciz	"take1"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rumptest_thread                ; -- Begin function rumptest_thread
	.p2align	2
_rumptest_thread:                       ; @rumptest_thread
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
Lloh0:
	adrp	x8, _MUTEX_DEFAULT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MUTEX_DEFAULT@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _IPL_NONE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IPL_NONE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x0, _mtx@GOTPAGE
Lloh7:
	ldr	x0, [x0, _mtx@GOTPAGEOFF]
	bl	_mutex_init
Lloh8:
	adrp	x0, _cv@GOTPAGE
Lloh9:
	ldr	x0, [x0, _cv@GOTPAGEOFF]
Lloh10:
	adrp	x1, l_.str@PAGE
Lloh11:
	add	x1, x1, l_.str@PAGEOFF
	bl	_cv_init
Lloh12:
	adrp	x8, _PRI_NONE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _PRI_NONE@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
Lloh15:
	adrp	x8, _KTHREAD_MPSAFE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _KTHREAD_MPSAFE@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
Lloh18:
	adrp	x8, _thethread@GOTPAGE
Lloh19:
	ldr	x8, [x8, _thethread@GOTPAGEOFF]
Lloh20:
	ldr	w3, [x8]
Lloh21:
	adrp	x6, l_.str.1@PAGE
Lloh22:
	add	x6, x6, l_.str.1@PAGEOFF
	add	x5, sp, #8
	mov	x2, #0
	mov	x4, #0
	bl	_kthread_create
	cbz	w0, LBB0_2
; %bb.1:
	mov	x1, x0
Lloh23:
	adrp	x0, l_.str.2@PAGE
Lloh24:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_panic
LBB0_2:
Lloh25:
	adrp	x0, _mtx@GOTPAGE
Lloh26:
	ldr	x0, [x0, _mtx@GOTPAGEOFF]
	bl	_mutex_enter
Lloh27:
	adrp	x21, _value@GOTPAGE
Lloh28:
	ldr	x21, [x21, _value@GOTPAGEOFF]
	ldr	x8, [x21]
	cbnz	x8, LBB0_5
; %bb.3:
Lloh29:
	adrp	x19, _cv@GOTPAGE
Lloh30:
	ldr	x19, [x19, _cv@GOTPAGEOFF]
Lloh31:
	adrp	x20, _mtx@GOTPAGE
Lloh32:
	ldr	x20, [x20, _mtx@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	_cv_wait
	ldr	x8, [x21]
	cbz	x8, LBB0_4
LBB0_5:
Lloh33:
	adrp	x0, _mtx@GOTPAGE
Lloh34:
	ldr	x0, [x0, _mtx@GOTPAGEOFF]
	bl	_mutex_exit
Lloh35:
	adrp	x0, l_.str.3@PAGE
Lloh36:
	add	x0, x0, l_.str.3@PAGEOFF
	mov	w1, #0
	mov	w2, #1
	mov	x3, #0
	bl	_kpause
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_mtx,4,2                        ; @mtx
	.comm	_MUTEX_DEFAULT,4,2              ; @MUTEX_DEFAULT
	.comm	_IPL_NONE,4,2                   ; @IPL_NONE
	.comm	_cv,4,2                         ; @cv
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"jooei"

	.comm	_PRI_NONE,4,2                   ; @PRI_NONE
	.comm	_KTHREAD_MPSAFE,4,2             ; @KTHREAD_MPSAFE
	.comm	_thethread,4,2                  ; @thethread
l_.str.1:                               ; @.str.1
	.asciz	"ktest"

l_.str.2:                               ; @.str.2
	.asciz	"thread creation failed: %d"

	.comm	_value,8,3                      ; @value
l_.str.3:                               ; @.str.3
	.asciz	"take1"

.subsections_via_symbols
