	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_w32_detach                     ## -- Begin function w32_detach
	.p2align	4, 0x90
_w32_detach:                            ## @w32_detach
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	xorl	%ebx, %ebx
	cmpl	$-1, %esi
	je	LBB0_5
## %bb.1:
	cmpl	%esi, (%rdi)
	jne	LBB0_5
## %bb.2:
	movq	8(%rdi), %r14
	cmpq	$0, (%r14)
	je	LBB0_5
## %bb.3:
	movq	_W32_DETTACH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	8(%r14), %rdi
	movq	(%rdi), %rcx
	movl	%eax, 8(%rcx)
	movl	%esi, (%rcx)
	callq	_w32dbg_wrap_wait_ret
	movq	(%r14), %rdi
	movq	8(%r14), %rax
	movq	(%rax), %rax
	movl	4(%rax), %ebx
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.4:
	callq	_CloseHandle
	movq	$0, (%r14)
LBB0_5:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_W32_DETTACH,4,2                ## @W32_DETTACH
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_w32_detach                     ; -- Begin function w32_detach
	.p2align	2
_w32_detach:                            ; @w32_detach
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cmn	w1, #1
	b.eq	LBB0_5
; %bb.1:
	ldr	w8, [x0]
	cmp	w8, w1
	b.ne	LBB0_5
; %bb.2:
	ldr	x20, [x0, #8]
	ldr	x8, [x20]
	cbz	x8, LBB0_5
; %bb.3:
Lloh0:
	adrp	x8, _W32_DETTACH@GOTPAGE
Lloh1:
	ldr	x8, [x8, _W32_DETTACH@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	x0, [x20, #8]
	ldr	x9, [x0]
	str	w8, [x9, #8]
	str	w1, [x9]
	bl	_w32dbg_wrap_wait_ret
	ldp	x0, x8, [x20]
	ldr	x8, [x8]
	ldr	w19, [x8, #4]
	cbz	x0, LBB0_6
; %bb.4:
	bl	_CloseHandle
	str	xzr, [x20]
	b	LBB0_6
LBB0_5:
	mov	w19, #0
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_W32_DETTACH,4,2                ; @W32_DETTACH
.subsections_via_symbols
