	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ds_shutdown
_ds_shutdown:                           ## @ds_shutdown
	.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
	movq	%rdi, %rbx
	movq	_RS_OPT_SVC_ACTIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_2
## %bb.1:
	movq	_RS_SVC_REM_DGRAM@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_udp_svc@GOTPCREL(%rip), %rdi
	movq	%rbx, %rsi
	callq	_rs_notify_svc
LBB0_2:
	movq	_O_NONBLOCK@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	testl	%eax, 4(%rbx)
	je	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_rs_set_nonblocking
LBB0_4:
	movq	_rs_readable@GOTPCREL(%rip), %rax
	movq	_rs_writable@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	notl	%ecx
	andl	%ecx, 8(%rbx)
	movq	_ds_all_sends_done@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_ds_process_cqs
	movl	4(%rbx), %esi
	testl	%esi, (%r14)
	je	LBB0_5
## %bb.6:
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_rs_set_nonblocking             ## TAILCALL
LBB0_5:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RS_OPT_SVC_ACTIVE,4,2          ## @RS_OPT_SVC_ACTIVE
	.comm	_udp_svc,4,2                    ## @udp_svc
	.comm	_RS_SVC_REM_DGRAM,4,2           ## @RS_SVC_REM_DGRAM
	.comm	_O_NONBLOCK,4,2                 ## @O_NONBLOCK
	.comm	_rs_readable,4,2                ## @rs_readable
	.comm	_rs_writable,4,2                ## @rs_writable
	.comm	_ds_all_sends_done,4,2          ## @ds_all_sends_done
	.no_dead_strip	_ds_shutdown
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ds_shutdown
_ds_shutdown:                           ; @ds_shutdown
	.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
	mov	x19, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _RS_OPT_SVC_ACTIVE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _RS_OPT_SVC_ACTIVE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _RS_SVC_REM_DGRAM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RS_SVC_REM_DGRAM@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x0, _udp_svc@GOTPAGE
Lloh7:
	ldr	x0, [x0, _udp_svc@GOTPAGEOFF]
	mov	x1, x19
	bl	_rs_notify_svc
LBB0_2:
	ldr	w8, [x19, #4]
Lloh8:
	adrp	x20, _O_NONBLOCK@GOTPAGE
Lloh9:
	ldr	x20, [x20, _O_NONBLOCK@GOTPAGEOFF]
	ldr	w9, [x20]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.3:
	mov	x0, x19
	mov	w1, #0
	bl	_rs_set_nonblocking
LBB0_4:
Lloh10:
	adrp	x8, _rs_readable@GOTPAGE
Lloh11:
	ldr	x8, [x8, _rs_readable@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _rs_writable@GOTPAGE
Lloh14:
	ldr	x9, [x9, _rs_writable@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x19, #8]
	bic	w8, w9, w8
	str	w8, [x19, #8]
Lloh16:
	adrp	x8, _ds_all_sends_done@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ds_all_sends_done@GOTPAGEOFF]
Lloh18:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #0
	bl	_ds_process_cqs
	ldr	w1, [x19, #4]
	ldr	w8, [x20]
	tst	w8, w1
	b.eq	LBB0_6
; %bb.5:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_rs_set_nonblocking
LBB0_6:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_RS_OPT_SVC_ACTIVE,4,2          ; @RS_OPT_SVC_ACTIVE
	.comm	_udp_svc,4,2                    ; @udp_svc
	.comm	_RS_SVC_REM_DGRAM,4,2           ; @RS_SVC_REM_DGRAM
	.comm	_O_NONBLOCK,4,2                 ; @O_NONBLOCK
	.comm	_rs_readable,4,2                ; @rs_readable
	.comm	_rs_writable,4,2                ; @rs_writable
	.comm	_ds_all_sends_done,4,2          ; @ds_all_sends_done
	.no_dead_strip	_ds_shutdown
.subsections_via_symbols
