	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function thread_takeover_sc_cmd
_thread_takeover_sc_cmd:                ## @thread_takeover_sc_cmd
	.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
	movl	%esi, %r14d
	xorl	%eax, %eax
	callq	_cur_thread
	movq	%rax, %rbx
	leaq	-48(%rbp), %r15
	movq	%r15, -40(%rbp)
	movq	_THREAD_BASIC_INFO_COUNT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
	movl	4(%rbx), %edi
	movq	_THREAD_BASIC_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-40(%rbp), %rdx
	leaq	-28(%rbp), %rcx
	callq	_thread_info
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	%rax, %rdi
	callq	_safe_strerror
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_error
LBB0_2:
	movq	-40(%rbp), %rax
	movl	(%rax), %esi
	movl	%esi, (%rbx)
	testl	%r14d, %r14d
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	callq	_printf_unfiltered
	movq	-40(%rbp), %rax
LBB0_4:
	cmpq	%r15, %rax
	je	LBB0_6
## %bb.5:
	xorl	%eax, %eax
	callq	_mach_task_self
	movl	-40(%rbp), %esi
	movl	-28(%rbp), %edx
	shll	$2, %edx
	movl	%eax, %edi
	callq	_vm_deallocate
LBB0_6:
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_THREAD_BASIC_INFO_COUNT,4,2    ## @THREAD_BASIC_INFO_COUNT
	.comm	_THREAD_BASIC_INFO,4,2          ## @THREAD_BASIC_INFO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s."

L_.str.1:                               ## @.str.1
	.asciz	"Suspend count was %d.\n"

	.no_dead_strip	_thread_takeover_sc_cmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function thread_takeover_sc_cmd
_thread_takeover_sc_cmd:                ; @thread_takeover_sc_cmd
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	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
	mov	x19, x1
	bl	_cur_thread
	mov	x20, x0
	add	x8, sp, #24
	str	x8, [sp, #16]
Lloh0:
	adrp	x8, _THREAD_BASIC_INFO_COUNT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _THREAD_BASIC_INFO_COUNT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	ldr	w0, [x0, #4]
Lloh3:
	adrp	x8, _THREAD_BASIC_INFO@GOTPAGE
Lloh4:
	ldr	x8, [x8, _THREAD_BASIC_INFO@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #16
	add	x3, sp, #12
	bl	_thread_info
	cbz	x0, LBB0_2
; %bb.1:
	bl	_safe_strerror
	mov	x1, x0
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_error
LBB0_2:
	ldr	x8, [sp, #16]
	ldr	w1, [x8]
	str	w1, [x20]
	cbz	w19, LBB0_4
; %bb.3:
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_printf_unfiltered
	ldr	x8, [sp, #16]
LBB0_4:
	add	x9, sp, #24
	cmp	x8, x9
	b.eq	LBB0_6
; %bb.5:
	bl	_mach_task_self
	ldp	w8, w1, [sp, #12]
	lsl	w2, w8, #2
	bl	_vm_deallocate
LBB0_6:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_THREAD_BASIC_INFO_COUNT,4,2    ; @THREAD_BASIC_INFO_COUNT
	.comm	_THREAD_BASIC_INFO,4,2          ; @THREAD_BASIC_INFO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s."

l_.str.1:                               ; @.str.1
	.asciz	"Suspend count was %d.\n"

	.no_dead_strip	_thread_takeover_sc_cmd
.subsections_via_symbols
