	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_pos
_add_pos:                               ## @add_pos
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
                                        ## kill: def $r8d killed $r8d def $r8
	movq	%r8, -72(%rbp)                  ## 8-byte Spill
	movq	%rcx, %rbx
	movl	%edx, %r13d
	movq	%rsi, %r12
	movl	%edi, %r14d
	movl	%edx, %edi
	movq	%rcx, %rsi
	callq	__POSVECPTR
	movq	%rax, %r15
	movl	%r14d, %edi
	movq	%r12, %rsi
	callq	_POSDATALEN
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	%r14d, %edi
	movq	%r12, %rsi
	callq	_POSDATAPTR
	movq	%rax, %r12
	movl	%r13d, %edi
	movq	%rbx, %rsi
	callq	_POSDATAPTR
	movq	%rax, %r13
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	cmpl	$0, (%rbx)
	je	LBB0_2
## %bb.1:
	movl	(%r15), %edx
	jmp	LBB0_3
LBB0_2:
	movl	$0, (%r15)
	xorl	%edx, %edx
LBB0_3:
	movl	%edx, %eax
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	testl	%ecx, %ecx
	jle	LBB0_12
## %bb.4:
	movl	%ecx, %eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	movl	%edx, -52(%rbp)                 ## 4-byte Spill
	movl	%edx, %ecx
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	xorl	%ecx, %ecx
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=1
	movslq	%ecx, %rax
	movl	(%r13,%rax,4), %ebx
	movl	(%r12,%r14,4), %edi
	callq	_WEP_GETWEIGHT
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_WEP_SETWEIGHT
	movslq	(%r15), %rax
	movl	(%r13,%rax,4), %ebx
	movl	(%r12,%r14,4), %edi
	callq	_WEP_GETPOS
                                        ## kill: def $eax killed $eax def $rax
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	leal	(%rax,%rcx), %edi
	callq	_LIMITPOS
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_WEP_SETPOS
	movl	(%r15), %ecx
	incl	%ecx
	movl	%ecx, (%r15)
	incq	%r14
	cmpq	%r14, -48(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_10
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	_MAXNUMPOS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ecx
	jge	LBB0_10
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	testl	%ecx, %ecx
	je	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	movslq	%ecx, %rax
	movl	-4(%r13,%rax,4), %edi
	callq	_WEP_GETPOS
	movq	_MAXENTRYPOS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	decl	%edx
	movl	(%r15), %ecx
	cmpl	%edx, %eax
	jne	LBB0_9
LBB0_10:
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	movl	%edx, %eax
	cmpl	%edx, %ecx
	je	LBB0_12
## %bb.11:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	movl	(%r15), %eax
LBB0_12:
	subl	%edx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MAXNUMPOS,4,2                  ## @MAXNUMPOS
	.comm	_MAXENTRYPOS,4,2                ## @MAXENTRYPOS
	.no_dead_strip	_add_pos
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_pos
_add_pos:                               ; @add_pos
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x4
	mov	x19, x3
	mov	x23, x2
	mov	x22, x1
	mov	x25, x0
	mov	x0, x2
	mov	x1, x3
	bl	__POSVECPTR
	mov	x20, x0
	mov	x0, x25
	mov	x1, x22
	bl	_POSDATALEN
	mov	x24, x0
	mov	x0, x25
	mov	x1, x22
	bl	_POSDATAPTR
	mov	x22, x0
	mov	x0, x23
	mov	x1, x19
	bl	_POSDATAPTR
	mov	x23, x0
	ldr	w8, [x19]
	cbz	w8, LBB0_2
; %bb.1:
	ldr	w25, [x20]
	b	LBB0_3
LBB0_2:
	mov	w25, #0
	str	wzr, [x20]
LBB0_3:
	mov	x9, x25
	cmp	w24, #1
	b.lt	LBB0_11
; %bb.4:
Lloh0:
	adrp	x26, _MAXNUMPOS@GOTPAGE
Lloh1:
	ldr	x26, [x26, _MAXNUMPOS@GOTPAGEOFF]
Lloh2:
	adrp	x27, _MAXENTRYPOS@GOTPAGE
Lloh3:
	ldr	x27, [x27, _MAXENTRYPOS@GOTPAGEOFF]
	mov	x8, x25
	mov	w28, w24
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	w24, [x23, w8, sxtw #2]
	ldr	w0, [x22]
	bl	_WEP_GETWEIGHT
	mov	x1, x0
	mov	x0, x24
	bl	_WEP_SETWEIGHT
	ldrsw	x8, [x20]
	ldr	w24, [x23, x8, lsl #2]
	ldr	w0, [x22], #4
	bl	_WEP_GETPOS
	add	w0, w0, w21
	bl	_LIMITPOS
	mov	x1, x0
	mov	x0, x24
	bl	_WEP_SETPOS
	ldr	w8, [x20]
	add	w8, w8, #1
	str	w8, [x20]
	subs	x28, x28, #1
	b.eq	LBB0_9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w9, [x26]
	cmp	w8, w9
	b.ge	LBB0_9
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	cbz	w8, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	sub	w8, w8, #1
	ldr	w0, [x23, w8, sxtw #2]
	bl	_WEP_GETPOS
	ldr	w8, [x27]
	sub	w9, w8, #1
	ldr	w8, [x20]
	cmp	w0, w9
	b.ne	LBB0_5
LBB0_9:
	mov	x9, x25
	cmp	w8, w25
	b.eq	LBB0_11
; %bb.10:
	mov	w8, #1
	str	w8, [x19]
	ldr	w9, [x20]
LBB0_11:
	sub	w0, w9, w25
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_MAXNUMPOS,4,2                  ; @MAXNUMPOS
	.comm	_MAXENTRYPOS,4,2                ; @MAXENTRYPOS
	.no_dead_strip	_add_pos
.subsections_via_symbols
