	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function do_attach
_do_attach:                             ## @do_attach
	.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
	movl	%edi, %r14d
	movq	%rsp, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_PATH_MAX@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r15
	movl	(%rbx), %ebx
	decl	%ebx
	movq	_nto_procfs_path@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	movl	%r14d, %edi
	callq	_PIDGET
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movq	%r12, %rcx
	movl	%eax, %r8d
	callq	_snprintf
	movq	_O_RDWR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_open
	movq	_ctl_fd@GOTPCREL(%rip), %r12
	movl	%eax, (%r12)
	cmpl	$-1, %eax
	jne	LBB0_2
## %bb.1:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	movq	%rbx, %rdi
	callq	_safe_strerror
	leaq	L_.str.1(%rip), %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_error
	movl	(%r12), %eax
LBB0_2:
	movq	_DCMD_PROC_STOP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	-112(%rbp), %rdx
	movl	%eax, %edi
	movl	$32, %ecx
	xorl	%r8d, %r8d
	callq	_devctl
	movq	_EOK@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_error
LBB0_4:
	movq	_SIGEV_SIGNAL_THREAD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -52(%rbp)
	movq	_SIGUSR1@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)
	xorps	%xmm0, %xmm0
	movups	%xmm0, -72(%rbp)
	movl	$-1, -80(%rbp)
	movl	(%r12), %edi
	movq	_DCMD_PROC_EVENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-80(%rbp), %rdx
	movl	$32, %ecx
	xorl	%r8d, %r8d
	callq	_devctl
	movl	(%r12), %edi
	movq	_DCMD_PROC_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-112(%rbp), %rdx
	movl	$32, %ecx
	xorl	%r8d, %r8d
	callq	_devctl
	cmpq	(%rbx), %rax
	jne	LBB0_7
## %bb.5:
	movq	__DEBUG_FLAG_STOPPED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -108(%rbp)
	je	LBB0_7
## %bb.6:
	xorl	%eax, %eax
	callq	_nto_node
	movl	%eax, %ebx
	movl	%r14d, %edi
	callq	_PIDGET
	movq	_SIGCONT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ebx, %edi
	movl	%eax, %esi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_SignalKill
LBB0_7:
	movq	_attach_flag@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
	xorl	%eax, %eax
	callq	_nto_init_solib_absolute_prefix
	movq	%r13, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_9
## %bb.8:
	movl	%r14d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PATH_MAX,4,2                   ## @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s/%d/as"

	.comm	_nto_procfs_path,8,3            ## @nto_procfs_path
	.comm	_O_RDWR,4,2                     ## @O_RDWR
	.comm	_ctl_fd,4,2                     ## @ctl_fd
L_.str.1:                               ## @.str.1
	.asciz	"Couldn't open proc file %s, error %d (%s)"

	.comm	_errno,8,3                      ## @errno
	.comm	_DCMD_PROC_STOP,4,2             ## @DCMD_PROC_STOP
	.comm	_EOK,8,3                        ## @EOK
L_.str.2:                               ## @.str.2
	.asciz	"Couldn't stop process"

	.comm	_SIGEV_SIGNAL_THREAD,4,2        ## @SIGEV_SIGNAL_THREAD
	.comm	_SIGUSR1,4,2                    ## @SIGUSR1
	.comm	_DCMD_PROC_EVENT,4,2            ## @DCMD_PROC_EVENT
	.comm	_DCMD_PROC_STATUS,4,2           ## @DCMD_PROC_STATUS
	.comm	__DEBUG_FLAG_STOPPED,4,2        ## @_DEBUG_FLAG_STOPPED
	.comm	_SIGCONT,4,2                    ## @SIGCONT
	.comm	_attach_flag,4,2                ## @attach_flag
	.no_dead_strip	_do_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function do_attach
_do_attach:                             ; @do_attach
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	sub	sp, sp, #80
	mov	x19, x0
	mov	x23, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
Lloh3:
	adrp	x12, _PATH_MAX@GOTPAGE
Lloh4:
	ldr	x12, [x12, _PATH_MAX@GOTPAGEOFF]
	ldr	w8, [x12]
	mov	x9, x8
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x1fffffff0
	sub	x20, x9, x8
	mov	sp, x20
	ldr	w8, [x12]
	sub	w21, w8, #1
Lloh7:
	adrp	x8, _nto_procfs_path@GOTPAGE
Lloh8:
	ldr	x8, [x8, _nto_procfs_path@GOTPAGEOFF]
Lloh9:
	ldr	x22, [x8]
	bl	_PIDGET
	mov	x4, x0
Lloh10:
	adrp	x2, l_.str@PAGE
Lloh11:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	mov	x1, x21
	mov	x3, x22
	bl	_snprintf
Lloh12:
	adrp	x8, _O_RDWR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _O_RDWR@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_open
Lloh15:
	adrp	x22, _ctl_fd@GOTPAGE
Lloh16:
	ldr	x22, [x22, _ctl_fd@GOTPAGEOFF]
	str	w0, [x22]
	cmn	w0, #1
	b.ne	LBB0_2
; %bb.1:
Lloh17:
	adrp	x8, _errno@GOTPAGE
Lloh18:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh19:
	ldr	x21, [x8]
	mov	x0, x21
	bl	_safe_strerror
                                        ; kill: def $w0 killed $w0 def $x0
	sub	sp, sp, #32
	stp	x21, x0, [sp, #8]
	str	x20, [sp]
Lloh20:
	adrp	x0, l_.str.1@PAGE
Lloh21:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_error
	add	sp, sp, #32
	ldr	w0, [x22]
LBB0_2:
Lloh22:
	adrp	x8, _DCMD_PROC_STOP@GOTPAGE
Lloh23:
	ldr	x8, [x8, _DCMD_PROC_STOP@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	sub	x2, x29, #88
	mov	w3, #32
	mov	w4, #0
	bl	_devctl
Lloh25:
	adrp	x20, _EOK@GOTPAGE
Lloh26:
	ldr	x20, [x20, _EOK@GOTPAGEOFF]
	ldr	x8, [x20]
	cmp	x0, x8
	b.eq	LBB0_4
; %bb.3:
Lloh27:
	adrp	x0, l_.str.2@PAGE
Lloh28:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_error
LBB0_4:
Lloh29:
	adrp	x8, _SIGEV_SIGNAL_THREAD@GOTPAGE
Lloh30:
	ldr	x8, [x8, _SIGEV_SIGNAL_THREAD@GOTPAGEOFF]
Lloh31:
	adrp	x9, _SIGUSR1@GOTPAGE
Lloh32:
	ldr	x9, [x9, _SIGUSR1@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
Lloh34:
	ldr	w9, [x9]
	stp	w9, w8, [x29, #-96]
	stp	xzr, xzr, [x29, #-112]
	mov	w8, #-1
	stur	w8, [x29, #-120]
	ldr	w0, [x22]
Lloh35:
	adrp	x8, _DCMD_PROC_EVENT@GOTPAGE
Lloh36:
	ldr	x8, [x8, _DCMD_PROC_EVENT@GOTPAGEOFF]
Lloh37:
	ldr	w1, [x8]
	sub	x2, x29, #120
	mov	w3, #32
	mov	w4, #0
	bl	_devctl
	ldr	w0, [x22]
Lloh38:
	adrp	x8, _DCMD_PROC_STATUS@GOTPAGE
Lloh39:
	ldr	x8, [x8, _DCMD_PROC_STATUS@GOTPAGEOFF]
Lloh40:
	ldr	w1, [x8]
	sub	x2, x29, #88
	mov	w3, #32
	mov	w4, #0
	bl	_devctl
	ldr	x8, [x20]
	cmp	x0, x8
	b.ne	LBB0_7
; %bb.5:
	ldur	w8, [x29, #-84]
Lloh41:
	adrp	x9, __DEBUG_FLAG_STOPPED@GOTPAGE
Lloh42:
	ldr	x9, [x9, __DEBUG_FLAG_STOPPED@GOTPAGEOFF]
Lloh43:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.6:
	bl	_nto_node
	mov	x20, x0
	mov	x0, x19
	bl	_PIDGET
	mov	x1, x0
Lloh44:
	adrp	x8, _SIGCONT@GOTPAGE
Lloh45:
	ldr	x8, [x8, _SIGCONT@GOTPAGEOFF]
Lloh46:
	ldr	w3, [x8]
	mov	x0, x20
	mov	w2, #0
	mov	w4, #0
	mov	w5, #0
	bl	_SignalKill
LBB0_7:
Lloh47:
	adrp	x8, _attach_flag@GOTPAGE
Lloh48:
	ldr	x8, [x8, _attach_flag@GOTPAGEOFF]
	mov	w9, #1
Lloh49:
	str	w9, [x8]
	bl	_nto_init_solib_absolute_prefix
	mov	sp, x23
	ldur	x8, [x29, #-56]
Lloh50:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh51:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh52:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_9
; %bb.8:
	mov	x0, x19
	sub	sp, x29, #48
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_9:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh33
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotStr	Lloh47, Lloh48, Lloh49
	.cfi_endproc
                                        ; -- End function
	.comm	_PATH_MAX,4,2                   ; @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s/%d/as"

	.comm	_nto_procfs_path,8,3            ; @nto_procfs_path
	.comm	_O_RDWR,4,2                     ; @O_RDWR
	.comm	_ctl_fd,4,2                     ; @ctl_fd
l_.str.1:                               ; @.str.1
	.asciz	"Couldn't open proc file %s, error %d (%s)"

	.comm	_errno,8,3                      ; @errno
	.comm	_DCMD_PROC_STOP,4,2             ; @DCMD_PROC_STOP
	.comm	_EOK,8,3                        ; @EOK
l_.str.2:                               ; @.str.2
	.asciz	"Couldn't stop process"

	.comm	_SIGEV_SIGNAL_THREAD,4,2        ; @SIGEV_SIGNAL_THREAD
	.comm	_SIGUSR1,4,2                    ; @SIGUSR1
	.comm	_DCMD_PROC_EVENT,4,2            ; @DCMD_PROC_EVENT
	.comm	_DCMD_PROC_STATUS,4,2           ; @DCMD_PROC_STATUS
	.comm	__DEBUG_FLAG_STOPPED,4,2        ; @_DEBUG_FLAG_STOPPED
	.comm	_SIGCONT,4,2                    ; @SIGCONT
	.comm	_attach_flag,4,2                ; @attach_flag
	.no_dead_strip	_do_attach
.subsections_via_symbols
