	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_write_event                    ## -- Begin function write_event
	.p2align	4, 0x90
_write_event:                           ## @write_event
	.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
	movl	%ecx, %r14d
	movl	%edx, %r12d
	movl	%esi, %r13d
	movl	%edi, %r15d
	movl	%esi, %edi
	movl	%edx, %esi
	movl	%ecx, %edx
	callq	_gen_split_param
	movl	%eax, %ecx
	movq	_log_split_mod@GOTPCREL(%rip), %rsi
	cltd
	idivl	(%rsi)
	movl	%edx, %ebx
	negl	%ebx
	testl	%ecx, %ecx
	cmovgl	%edx, %ebx
	movq	_z@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	cmpl	$422, %ebx                      ## imm = 0x1A6
	jne	LBB0_2
## %bb.1:
	movslq	%r13d, %rax
	incl	(%rcx,%rax,4)
	incl	(%rcx)
	movl	%r12d, %eax
	cltd
	idivl	(%rsi)
	movl	%eax, %edx
	negl	%edx
	testl	%r12d, %r12d
	movq	_u@GOTPCREL(%rip), %rsi
	movq	(%rsi), %rsi
	cmovgl	%eax, %edx
	movslq	%edx, %rax
	incl	(%rsi,%rax,4)
	addq	$4, %rcx
	jmp	LBB0_4
LBB0_2:
	incl	4(%rcx)
	cmpl	$1, %ebx
	jne	LBB0_5
## %bb.3:
	movq	_USERMOD@GOTPCREL(%rip), %rcx
	movl	%r15d, %eax
	cltd
	idivl	(%rcx)
	movq	_MAXUSERS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, %edx
	shrl	$31, %edx
	addl	%ecx, %edx
	sarl	%edx
	addl	%eax, %edx
	movl	%edx, %eax
	notl	%eax
	shrl	$31, %eax
	xorl	%edi, %edi
	cmpl	%ecx, %edx
	cmovll	%eax, %edi
	callq	_assert
	movq	_a@GOTPCREL(%rip), %rsi
	movq	_MAXUSERS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	movl	%r15d, %eax
	cltd
	movq	_USERMOD@GOTPCREL(%rip), %rdi
	idivl	(%rdi)
	addl	%ecx, %eax
	movslq	%eax, %rcx
	shlq	$2, %rcx
	addq	(%rsi), %rcx
LBB0_4:
	incl	(%rcx)
LBB0_5:
	movq	_c@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	%ebx, %ecx
	incl	(%rax,%rcx,4)
	movq	_LEV_BOOKMARK_INSERT@GOTPCREL(%rip), %rax
	addl	(%rax), %r13d
	movl	%ebx, %edi
	movl	%r13d, %esi
	callq	_write_int
	movl	%ebx, %edi
	movl	%r15d, %esi
	callq	_write_int
	movl	%ebx, %edi
	movl	%r12d, %esi
	callq	_write_int
	movl	%ebx, %edi
	movl	%r14d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_write_int                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_log_split_mod,4,2              ## @log_split_mod
	.comm	_z,8,3                          ## @z
	.comm	_u,8,3                          ## @u
	.comm	_USERMOD,4,2                    ## @USERMOD
	.comm	_MAXUSERS,4,2                   ## @MAXUSERS
	.comm	_a,8,3                          ## @a
	.comm	_c,8,3                          ## @c
	.comm	_LEV_BOOKMARK_INSERT,4,2        ## @LEV_BOOKMARK_INSERT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_write_event                    ; -- Begin function write_event
	.p2align	2
_write_event:                           ; @write_event
	.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
	mov	x19, x3
	mov	x20, x2
	mov	x23, x1
	mov	x21, x0
	mov	x0, x1
	mov	x1, x2
	mov	x2, x3
	bl	_gen_split_param
Lloh0:
	adrp	x9, _log_split_mod@GOTPAGE
Lloh1:
	ldr	x9, [x9, _log_split_mod@GOTPAGEOFF]
	ldr	w8, [x9]
	sdiv	w10, w0, w8
	msub	w8, w10, w8, w0
	cmp	w0, #0
	cneg	w22, w8, le
Lloh2:
	adrp	x8, _z@GOTPAGE
Lloh3:
	ldr	x8, [x8, _z@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	cmp	w22, #422
	b.ne	LBB0_2
; %bb.1:
	sbfiz	x10, x23, #2, #32
	ldr	w11, [x8, x10]
	add	w11, w11, #1
	str	w11, [x8, x10]
	ldr	w10, [x8]
	add	w10, w10, #1
	str	w10, [x8], #4
Lloh5:
	adrp	x10, _u@GOTPAGE
Lloh6:
	ldr	x10, [x10, _u@GOTPAGEOFF]
Lloh7:
	ldr	x10, [x10]
	ldr	w9, [x9]
	sdiv	w9, w20, w9
	cmp	w20, #0
	cneg	w9, w9, le
	sbfiz	x9, x9, #2, #32
	ldr	w11, [x10, x9]
	add	w11, w11, #1
	str	w11, [x10, x9]
	b	LBB0_4
LBB0_2:
	ldr	w9, [x8, #4]
	add	w9, w9, #1
	str	w9, [x8, #4]
	cmp	w22, #1
	b.ne	LBB0_5
; %bb.3:
Lloh8:
	adrp	x24, _USERMOD@GOTPAGE
Lloh9:
	ldr	x24, [x24, _USERMOD@GOTPAGEOFF]
	ldr	w8, [x24]
	sdiv	w8, w21, w8
Lloh10:
	adrp	x25, _MAXUSERS@GOTPAGE
Lloh11:
	ldr	x25, [x25, _MAXUSERS@GOTPAGEOFF]
	ldr	w9, [x25]
	cmp	w9, #0
	cinc	w10, w9, lt
	add	w8, w8, w10, asr #1
	mvn	w10, w8
	lsr	w10, w10, #31
	cmp	w8, w9
	csel	w0, w10, wzr, lt
	bl	_assert
Lloh12:
	adrp	x8, _a@GOTPAGE
Lloh13:
	ldr	x8, [x8, _a@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	ldr	w9, [x25]
	cmp	w9, #0
	cinc	w9, w9, lt
	ldr	w10, [x24]
	sdiv	w10, w21, w10
	add	w9, w10, w9, asr #1
	add	x8, x8, w9, sxtw #2
LBB0_4:
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
LBB0_5:
Lloh15:
	adrp	x8, _c@GOTPAGE
Lloh16:
	ldr	x8, [x8, _c@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	lsl	x9, x22, #2
	ldr	w10, [x8, x9]
	add	w10, w10, #1
	str	w10, [x8, x9]
Lloh18:
	adrp	x8, _LEV_BOOKMARK_INSERT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _LEV_BOOKMARK_INSERT@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	add	w1, w8, w23
	mov	x0, x22
	bl	_write_int
	mov	x0, x22
	mov	x1, x21
	bl	_write_int
	mov	x0, x22
	mov	x1, x20
	bl	_write_int
	mov	x0, x22
	mov	x1, x19
	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	_write_int
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_log_split_mod,4,2              ; @log_split_mod
	.comm	_z,8,3                          ; @z
	.comm	_u,8,3                          ; @u
	.comm	_USERMOD,4,2                    ; @USERMOD
	.comm	_MAXUSERS,4,2                   ; @MAXUSERS
	.comm	_a,8,3                          ; @a
	.comm	_c,8,3                          ; @c
	.comm	_LEV_BOOKMARK_INSERT,4,2        ; @LEV_BOOKMARK_INSERT
.subsections_via_symbols
