	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_write_buff_set_pos             ## -- Begin function write_buff_set_pos
	.p2align	4, 0x90
_write_buff_set_pos:                    ## @write_buff_set_pos
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_cur_buff_len@GOTPCREL(%rip), %rax
	cmpl	%edi, (%rax)
	jl	LBB0_5
## %bb.1:
	movq	_result_buff_pos@GOTPCREL(%rip), %rcx
	movl	(%rcx), %eax
	cmpl	%edi, %eax
	jle	LBB0_2
## %bb.3:
	movl	%edi, (%rcx)
	movq	_buff@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	jmp	LBB0_4
LBB0_2:
	subl	%eax, %edi
	movq	_buff@GOTPCREL(%rip), %rax
	addl	(%rax), %edi
LBB0_4:
	movq	_wptr@GOTPCREL(%rip), %rax
	movl	%edi, (%rax)
LBB0_5:
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cur_buff_len,4,2               ## @cur_buff_len
	.comm	_result_buff_pos,4,2            ## @result_buff_pos
	.comm	_buff,4,2                       ## @buff
	.comm	_wptr,4,2                       ## @wptr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_write_buff_set_pos             ; -- Begin function write_buff_set_pos
	.p2align	2
_write_buff_set_pos:                    ; @write_buff_set_pos
	.cfi_startproc
; %bb.0:
Lloh0:
	adrp	x8, _cur_buff_len@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cur_buff_len@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w0
	b.lt	LBB0_5
; %bb.1:
Lloh3:
	adrp	x9, _result_buff_pos@GOTPAGE
Lloh4:
	ldr	x9, [x9, _result_buff_pos@GOTPAGEOFF]
	ldr	w8, [x9]
	cmp	w8, w0
	b.le	LBB0_3
; %bb.2:
	str	w0, [x9]
Lloh5:
	adrp	x8, _buff@GOTPAGE
Lloh6:
	ldr	x8, [x8, _buff@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	b	LBB0_4
LBB0_3:
Lloh8:
	adrp	x9, _buff@GOTPAGE
Lloh9:
	ldr	x9, [x9, _buff@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	sub	w8, w0, w8
	add	w8, w8, w9
LBB0_4:
Lloh11:
	adrp	x9, _wptr@GOTPAGE
Lloh12:
	ldr	x9, [x9, _wptr@GOTPAGEOFF]
Lloh13:
	str	w8, [x9]
LBB0_5:
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotStr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_cur_buff_len,4,2               ; @cur_buff_len
	.comm	_result_buff_pos,4,2            ; @result_buff_pos
	.comm	_buff,4,2                       ; @buff
	.comm	_wptr,4,2                       ; @wptr
.subsections_via_symbols
