	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_chassis_event_thread_free      ## -- Begin function chassis_event_thread_free
	.p2align	4, 0x90
_chassis_event_thread_free:             ## @chassis_event_thread_free
	.cfi_startproc
## %bb.0:
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.1:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movq	24(%rdi), %rdi
	testq	%rdi, %rdi
	je	LBB0_3
## %bb.2:
	callq	_g_thread_join
LBB0_3:
	cmpl	$-1, (%rbx)
	je	LBB0_5
## %bb.4:
	leaq	32(%rbx), %rdi
	callq	_event_del
	movl	(%rbx), %edi
	callq	_closesocket
LBB0_5:
	movl	4(%rbx), %edi
	cmpl	$-1, %edi
	je	LBB0_7
## %bb.6:
	callq	_closesocket
LBB0_7:
	cmpq	$0, 24(%rbx)
	je	LBB0_11
## %bb.8:
	movq	16(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_11
## %bb.9:
	callq	_event_base_free
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	%rax, %rdi
	callq	_network_mysqld_con_free
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movl	8(%rbx), %edi
	callq	_g_async_queue_try_pop
	testq	%rax, %rax
	jne	LBB0_10
## %bb.12:
	movl	8(%rbx), %edi
	callq	_g_async_queue_unref
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_g_free                         ## TAILCALL
LBB0_13:
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_chassis_event_thread_free      ; -- Begin function chassis_event_thread_free
	.p2align	2
_chassis_event_thread_free:             ; @chassis_event_thread_free
	.cfi_startproc
; %bb.0:
	cbz	x0, LBB0_13
; %bb.1:
	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
	mov	x19, x0
	ldr	x0, [x0, #24]
	cbz	x0, LBB0_3
; %bb.2:
	bl	_g_thread_join
LBB0_3:
	ldr	w8, [x19]
	cmn	w8, #1
	b.eq	LBB0_5
; %bb.4:
	add	x0, x19, #32
	bl	_event_del
	ldr	w0, [x19]
	bl	_closesocket
LBB0_5:
	ldr	w0, [x19, #4]
	cmn	w0, #1
	b.eq	LBB0_7
; %bb.6:
	bl	_closesocket
LBB0_7:
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_11
; %bb.8:
	ldr	x0, [x19, #16]
	cbz	x0, LBB0_11
; %bb.9:
	bl	_event_base_free
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	bl	_network_mysqld_con_free
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19, #8]
	bl	_g_async_queue_try_pop
	cbnz	x0, LBB0_10
; %bb.12:
	ldr	w0, [x19, #8]
	bl	_g_async_queue_unref
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_g_free
LBB0_13:
	.cfi_def_cfa wsp, 0
	.cfi_same_value w30
	.cfi_same_value w29
	.cfi_same_value w19
	.cfi_same_value w20
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
