	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_init_gdb                       ## -- Begin function init_gdb
	.p2align	4, 0x90
_init_gdb:                              ## @init_gdb
	.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	%edx, %r14d
	movl	%esi, %r15d
	movq	%rdi, %rbx
	testl	%edx, %edx
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rdi
	callq	_debug
	movq	_gdb_lock@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	callq	_pthread_mutex_init
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	leaq	L_.str.3(%rip), %rdx
	movl	$1, %edi
	movl	%eax, %esi
	callq	_errc
LBB0_2:
	movq	_idle_vcpus@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	callq	_pthread_cond_init
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.4(%rip), %rdx
	movl	$1, %edi
	movl	%eax, %esi
	callq	_errc
LBB0_4:
	movq	_ctx@GOTPCREL(%rip), %rax
	movq	%rbx, (%rax)
	movq	_PF_INET@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SOCK_STREAM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_socket
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_6
## %bb.5:
	leaq	L_.str.5(%rip), %rsi
	movl	$1, %edi
	callq	_err
LBB0_6:
	movl	$16, -40(%rbp)
	movq	_AF_INET@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
	movq	_INADDR_ANY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_htonl
	movl	%eax, -32(%rbp)
	movl	%r15d, %edi
	callq	_htons
	movl	%eax, -36(%rbp)
	leaq	-40(%rbp), %rsi
	movl	%ebx, %edi
	movl	$16, %edx
	callq	_bind
	testq	%rax, %rax
	jns	LBB0_8
## %bb.7:
	leaq	L_.str.6(%rip), %rsi
	movl	$1, %edi
	callq	_err
LBB0_8:
	movl	%ebx, %edi
	movl	$1, %esi
	callq	_listen
	testq	%rax, %rax
	js	LBB0_9
## %bb.10:
	testl	%r14d, %r14d
	je	LBB0_12
LBB0_11:
	movq	_stepping_vcpu@GOTPCREL(%rip), %rax
	movl	$-1, (%rax)
	movq	_stopped_vcpu@GOTPCREL(%rip), %rax
	movl	$-1, (%rax)
	movq	_vcpus_suspended@GOTPCREL(%rip), %rsi
	xorl	%edi, %edi
	callq	_CPU_SET
LBB0_12:
	movq	_F_GETFL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	xorl	%eax, %eax
	callq	_fcntl
	movq	_F_SETFL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	_O_NONBLOCK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_fcntl
	cmpl	$-1, %eax
	jne	LBB0_14
## %bb.13:
	leaq	L_.str.8(%rip), %rsi
	movl	$1, %edi
	callq	_err
LBB0_14:
	movl	%ebx, %edi
	callq	_limit_gdb_socket
	movq	_EVF_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_new_connection@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %edi
	xorl	%ecx, %ecx
	callq	_mevent_add
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	leaq	L_.str.7(%rip), %rsi
	movl	$1, %edi
	callq	_err
	testl	%r14d, %r14d
	jne	LBB0_11
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"==> starting on %d, %swaiting\n"

L_.str.1:                               ## @.str.1
	.space	1

L_.str.2:                               ## @.str.2
	.asciz	"not "

	.comm	_gdb_lock,4,2                   ## @gdb_lock
L_.str.3:                               ## @.str.3
	.asciz	"gdb mutex init"

	.comm	_idle_vcpus,4,2                 ## @idle_vcpus
L_.str.4:                               ## @.str.4
	.asciz	"gdb cv init"

	.comm	_ctx,8,3                        ## @ctx
	.comm	_PF_INET,4,2                    ## @PF_INET
	.comm	_SOCK_STREAM,4,2                ## @SOCK_STREAM
L_.str.5:                               ## @.str.5
	.asciz	"gdb socket create"

	.comm	_AF_INET,4,2                    ## @AF_INET
	.comm	_INADDR_ANY,4,2                 ## @INADDR_ANY
L_.str.6:                               ## @.str.6
	.asciz	"gdb socket bind"

L_.str.7:                               ## @.str.7
	.asciz	"gdb socket listen"

	.comm	_stepping_vcpu,4,2              ## @stepping_vcpu
	.comm	_stopped_vcpu,4,2               ## @stopped_vcpu
	.comm	_vcpus_suspended,4,2            ## @vcpus_suspended
	.comm	_F_GETFL,4,2                    ## @F_GETFL
	.comm	_F_SETFL,4,2                    ## @F_SETFL
	.comm	_O_NONBLOCK,4,2                 ## @O_NONBLOCK
L_.str.8:                               ## @.str.8
	.asciz	"Failed to mark gdb socket non-blocking"

	.comm	_EVF_READ,4,2                   ## @EVF_READ
	.comm	_new_connection,4,2             ## @new_connection
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_init_gdb                       ; -- Begin function init_gdb
	.p2align	2
_init_gdb:                              ; @init_gdb
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
Lloh0:
	adrp	x8, l_.str.1@PAGE
Lloh1:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh2:
	adrp	x9, l_.str.2@PAGE
Lloh3:
	add	x9, x9, l_.str.2@PAGEOFF
	cmp	w2, #0
	csel	x2, x9, x8, eq
Lloh4:
	adrp	x0, l_.str@PAGE
Lloh5:
	add	x0, x0, l_.str@PAGEOFF
	bl	_debug
Lloh6:
	adrp	x0, _gdb_lock@GOTPAGE
Lloh7:
	ldr	x0, [x0, _gdb_lock@GOTPAGEOFF]
	mov	x1, #0
	bl	_pthread_mutex_init
	cbz	w0, LBB0_2
; %bb.1:
	mov	x1, x0
Lloh8:
	adrp	x2, l_.str.3@PAGE
Lloh9:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	w0, #1
	bl	_errc
LBB0_2:
Lloh10:
	adrp	x0, _idle_vcpus@GOTPAGE
Lloh11:
	ldr	x0, [x0, _idle_vcpus@GOTPAGEOFF]
	mov	x1, #0
	bl	_pthread_cond_init
	cbz	w0, LBB0_4
; %bb.3:
	mov	x1, x0
Lloh12:
	adrp	x2, l_.str.4@PAGE
Lloh13:
	add	x2, x2, l_.str.4@PAGEOFF
	mov	w0, #1
	bl	_errc
LBB0_4:
Lloh14:
	adrp	x8, _ctx@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ctx@GOTPAGEOFF]
Lloh16:
	str	x20, [x8]
Lloh17:
	adrp	x8, _PF_INET@GOTPAGE
Lloh18:
	ldr	x8, [x8, _PF_INET@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
Lloh20:
	adrp	x8, _SOCK_STREAM@GOTPAGE
Lloh21:
	ldr	x8, [x8, _SOCK_STREAM@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_socket
	mov	x20, x0
	tbz	w0, #31, LBB0_6
; %bb.5:
Lloh23:
	adrp	x1, l_.str.5@PAGE
Lloh24:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_6:
	mov	w8, #16
Lloh25:
	adrp	x9, _AF_INET@GOTPAGE
Lloh26:
	ldr	x9, [x9, _AF_INET@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	str	w8, [sp, #16]
	str	w9, [sp, #28]
Lloh28:
	adrp	x8, _INADDR_ANY@GOTPAGE
Lloh29:
	ldr	x8, [x8, _INADDR_ANY@GOTPAGEOFF]
Lloh30:
	ldr	w0, [x8]
	bl	_htonl
	str	w0, [sp, #24]
	mov	x0, x21
	bl	_htons
	str	w0, [sp, #20]
	add	x1, sp, #16
	mov	x0, x20
	mov	w2, #16
	bl	_bind
	tbz	x0, #63, LBB0_8
; %bb.7:
Lloh31:
	adrp	x1, l_.str.6@PAGE
Lloh32:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_8:
	mov	x0, x20
	mov	w1, #1
	bl	_listen
	tbnz	x0, #63, LBB0_14
; %bb.9:
	cbz	w19, LBB0_11
LBB0_10:
Lloh33:
	adrp	x8, _stepping_vcpu@GOTPAGE
Lloh34:
	ldr	x8, [x8, _stepping_vcpu@GOTPAGEOFF]
	mov	w9, #-1
Lloh35:
	str	w9, [x8]
Lloh36:
	adrp	x8, _stopped_vcpu@GOTPAGE
Lloh37:
	ldr	x8, [x8, _stopped_vcpu@GOTPAGEOFF]
Lloh38:
	str	w9, [x8]
Lloh39:
	adrp	x1, _vcpus_suspended@GOTPAGE
Lloh40:
	ldr	x1, [x1, _vcpus_suspended@GOTPAGEOFF]
	mov	w0, #0
	bl	_CPU_SET
LBB0_11:
Lloh41:
	adrp	x8, _F_GETFL@GOTPAGE
Lloh42:
	ldr	x8, [x8, _F_GETFL@GOTPAGEOFF]
Lloh43:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_fcntl
Lloh44:
	adrp	x8, _F_SETFL@GOTPAGE
Lloh45:
	ldr	x8, [x8, _F_SETFL@GOTPAGEOFF]
Lloh46:
	ldr	w1, [x8]
Lloh47:
	adrp	x8, _O_NONBLOCK@GOTPAGE
Lloh48:
	ldr	x8, [x8, _O_NONBLOCK@GOTPAGEOFF]
Lloh49:
	ldr	w8, [x8]
	orr	w8, w8, w0
	str	x8, [sp]
	mov	x0, x20
	bl	_fcntl
	cmn	w0, #1
	b.ne	LBB0_13
; %bb.12:
Lloh50:
	adrp	x1, l_.str.8@PAGE
Lloh51:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_13:
	mov	x0, x20
	bl	_limit_gdb_socket
Lloh52:
	adrp	x8, _EVF_READ@GOTPAGE
Lloh53:
	ldr	x8, [x8, _EVF_READ@GOTPAGEOFF]
Lloh54:
	ldr	w1, [x8]
Lloh55:
	adrp	x8, _new_connection@GOTPAGE
Lloh56:
	ldr	x8, [x8, _new_connection@GOTPAGEOFF]
Lloh57:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x3, #0
	bl	_mevent_add
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_14:
Lloh58:
	adrp	x1, l_.str.7@PAGE
Lloh59:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	w0, #1
	bl	_err
	cbnz	w19, LBB0_10
	b	LBB0_11
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotStr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotStr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotStr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpAdd	Lloh58, Lloh59
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"==> starting on %d, %swaiting\n"

l_.str.1:                               ; @.str.1
	.space	1

l_.str.2:                               ; @.str.2
	.asciz	"not "

	.comm	_gdb_lock,4,2                   ; @gdb_lock
l_.str.3:                               ; @.str.3
	.asciz	"gdb mutex init"

	.comm	_idle_vcpus,4,2                 ; @idle_vcpus
l_.str.4:                               ; @.str.4
	.asciz	"gdb cv init"

	.comm	_ctx,8,3                        ; @ctx
	.comm	_PF_INET,4,2                    ; @PF_INET
	.comm	_SOCK_STREAM,4,2                ; @SOCK_STREAM
l_.str.5:                               ; @.str.5
	.asciz	"gdb socket create"

	.comm	_AF_INET,4,2                    ; @AF_INET
	.comm	_INADDR_ANY,4,2                 ; @INADDR_ANY
l_.str.6:                               ; @.str.6
	.asciz	"gdb socket bind"

l_.str.7:                               ; @.str.7
	.asciz	"gdb socket listen"

	.comm	_stepping_vcpu,4,2              ; @stepping_vcpu
	.comm	_stopped_vcpu,4,2               ; @stopped_vcpu
	.comm	_vcpus_suspended,4,2            ; @vcpus_suspended
	.comm	_F_GETFL,4,2                    ; @F_GETFL
	.comm	_F_SETFL,4,2                    ; @F_SETFL
	.comm	_O_NONBLOCK,4,2                 ; @O_NONBLOCK
l_.str.8:                               ; @.str.8
	.asciz	"Failed to mark gdb socket non-blocking"

	.comm	_EVF_READ,4,2                   ; @EVF_READ
	.comm	_new_connection,4,2             ; @new_connection
.subsections_via_symbols
