	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function flushsh
_flushsh:                               ## @flushsh
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_BUCKETS@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	testl	%r8d, %r8d
	jle	LBB0_1
## %bb.2:
	movq	_bucket@GOTPCREL(%rip), %rcx
	movq	(%rcx), %r9
	xorl	%esi, %esi
	xorl	%edi, %edi
	xorl	%ecx, %ecx
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%rsi
	cmpq	%r8, %rsi
	je	LBB0_7
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movq	(%r9,%rsi,8), %rbx
	testq	%rbx, %rbx
	je	LBB0_6
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	xorl	%eax, %eax
	xorl	%edx, %edx
	cmpq	$0, 8(%rbx)
	setne	%al
	sete	%dl
	addl	%edx, %ecx
	addl	%eax, %edi
	movq	16(%rbx), %rbx
	testq	%rbx, %rbx
	jne	LBB0_4
	jmp	LBB0_6
LBB0_7:
	testl	%edi, %edi
	jne	LBB0_9
## %bb.8:
	testl	%ecx, %ecx
	jne	LBB0_22
LBB0_9:
	testl	%ecx, %ecx
	leaq	L_.str(%rip), %rax
	leaq	L_.str.1(%rip), %rsi
	cmovneq	%rax, %rsi
	jmp	LBB0_10
LBB0_1:
	leaq	L_.str.1(%rip), %rsi
LBB0_10:
	movq	_strings@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_fopen
	movq	%rax, %r15
	testq	%rax, %rax
	jne	LBB0_12
## %bb.11:
	movq	_strings@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rsi
	movl	$4, %edi
	callq	_err
LBB0_12:
	movq	_BUCKETS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_21
## %bb.13:
	xorl	%r12d, %r12d
	leaq	L_.str.2(%rip), %r14
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_14 Depth=1
	movq	_BUCKETS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_20:                                ##   in Loop: Header=BB0_14 Depth=1
	incq	%r12
	movslq	%eax, %rcx
	cmpq	%rcx, %r12
	jge	LBB0_21
LBB0_14:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_15 Depth 2
	movq	_bucket@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rcx,%r12,8), %r13
	testq	%r13, %r13
	jne	LBB0_15
	jmp	LBB0_20
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_15 Depth=2
	movq	16(%r13), %r13
	testq	%r13, %r13
	je	LBB0_19
LBB0_15:                                ##   Parent Loop BB0_14 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	8(%r13), %rdi
	movl	(%r13), %edx
	movl	4(%r13), %esi
	callq	_found
	cmpq	$0, 8(%r13)
	je	LBB0_18
## %bb.16:                              ##   in Loop: Header=BB0_15 Depth=2
	movl	4(%r13), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_fseek
	movl	(%r13), %ebx
	movl	%ebx, %edi
	callq	_strlen
	leaq	1(%rax), %rsi
	movl	%ebx, %edi
	movl	$1, %edx
	movq	%r15, %rcx
	callq	_fwrite
	movl	%eax, %edi
	callq	_ignore
	movq	%r15, %rdi
	callq	_ferror
	testq	%rax, %rax
	je	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_15 Depth=2
	movq	_strings@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$4, %edi
	movq	%r14, %rsi
	callq	_err
	jmp	LBB0_18
LBB0_21:
	movq	%r15, %rdi
	callq	_fclose
	movq	_EOF@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_22
## %bb.23:
	movq	_strings@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rsi
	movl	$4, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_err                            ## TAILCALL
LBB0_22:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BUCKETS,4,2                    ## @BUCKETS
	.comm	_bucket,8,3                     ## @bucket
	.comm	_strings,4,2                    ## @strings
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"r+"

L_.str.1:                               ## @.str.1
	.asciz	"w"

L_.str.2:                               ## @.str.2
	.asciz	"%s"

	.comm	_EOF,8,3                        ## @EOF
	.no_dead_strip	_flushsh
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function flushsh
_flushsh:                               ; @flushsh
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
Lloh0:
	adrp	x22, _BUCKETS@GOTPAGE
Lloh1:
	ldr	x22, [x22, _BUCKETS@GOTPAGEOFF]
	ldr	w8, [x22]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
Lloh4:
	adrp	x23, _bucket@GOTPAGE
Lloh5:
	ldr	x23, [x23, _bucket@GOTPAGEOFF]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.1:
	mov	x11, #0
	mov	w10, #0
	mov	w9, #0
	ldr	x12, [x23]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x11, x11, #1
	cmp	x11, x8
	b.eq	LBB0_5
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_4 Depth 2
	ldr	x13, [x12, x11, lsl #3]
	cbz	x13, LBB0_2
LBB0_4:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldp	x14, x13, [x13, #8]
	cmp	x14, #0
	cinc	w9, w9, eq
	cinc	w10, w10, ne
	cbnz	x13, LBB0_4
	b	LBB0_2
LBB0_5:
	cbnz	w10, LBB0_7
; %bb.6:
	cbnz	w9, LBB0_21
LBB0_7:
Lloh6:
	adrp	x8, l_.str@PAGE
Lloh7:
	add	x8, x8, l_.str@PAGEOFF
	cmp	w9, #0
	csel	x1, x8, x1, ne
LBB0_8:
Lloh8:
	adrp	x24, _strings@GOTPAGE
Lloh9:
	ldr	x24, [x24, _strings@GOTPAGEOFF]
	ldr	w0, [x24]
	bl	_fopen
	mov	x19, x0
	cbnz	x0, LBB0_10
; %bb.9:
	ldr	w2, [x24]
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #4
	bl	_err
LBB0_10:
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_19
; %bb.11:
	mov	x25, #0
Lloh12:
	adrp	x20, l_.str.2@PAGE
Lloh13:
	add	x20, x20, l_.str.2@PAGEOFF
	b	LBB0_14
LBB0_12:                                ;   in Loop: Header=BB0_14 Depth=1
	ldr	w8, [x22]
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=1
	add	x25, x25, #1
	cmp	x25, w8, sxtw
	b.ge	LBB0_19
LBB0_14:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_16 Depth 2
	ldr	x9, [x23]
	ldr	x26, [x9, x25, lsl #3]
	cbnz	x26, LBB0_16
	b	LBB0_13
LBB0_15:                                ;   in Loop: Header=BB0_16 Depth=2
	ldr	x26, [x26, #16]
	cbz	x26, LBB0_12
LBB0_16:                                ;   Parent Loop BB0_14 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x0, [x26, #8]
	ldp	w2, w1, [x26]
	bl	_found
	ldr	x8, [x26, #8]
	cbz	x8, LBB0_15
; %bb.17:                               ;   in Loop: Header=BB0_16 Depth=2
	ldr	w1, [x26, #4]
	mov	x0, x19
	mov	w2, #0
	bl	_fseek
	ldr	w21, [x26]
	mov	x0, x21
	bl	_strlen
	add	x1, x0, #1
	mov	x0, x21
	mov	w2, #1
	mov	x3, x19
	bl	_fwrite
	bl	_ignore
	mov	x0, x19
	bl	_ferror
	cbz	x0, LBB0_15
; %bb.18:                               ;   in Loop: Header=BB0_16 Depth=2
	ldr	w2, [x24]
	mov	w0, #4
	mov	x1, x20
	bl	_err
	b	LBB0_15
LBB0_19:
	mov	x0, x19
	bl	_fclose
Lloh14:
	adrp	x8, _EOF@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EOF@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_21
; %bb.20:
	ldr	w2, [x24]
Lloh17:
	adrp	x1, l_.str.2@PAGE
Lloh18:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #4
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_err
LBB0_21:
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_BUCKETS,4,2                    ; @BUCKETS
	.comm	_bucket,8,3                     ; @bucket
	.comm	_strings,4,2                    ; @strings
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"r+"

l_.str.1:                               ; @.str.1
	.asciz	"w"

l_.str.2:                               ; @.str.2
	.asciz	"%s"

	.comm	_EOF,8,3                        ; @EOF
	.no_dead_strip	_flushsh
.subsections_via_symbols
