	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function select_proxy
_select_proxy:                          ## @select_proxy
	.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	%edx, %r12d
	movl	(%rcx), %eax
	xorl	%edx, %edx
	cmpl	%r12d, %eax
	jae	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	cmpl	$128, %edi
	je	LBB0_7
## %bb.3:
	cmpl	$129, %edi
	jne	LBB0_12
## %bb.4:
	movq	_PLAY_STATE@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	%eax, %esi
	cmpq	%rdx, (%r14,%rsi,8)
	je	LBB0_6
## %bb.10:                              ##   in Loop: Header=BB0_5 Depth=1
	incl	%eax
	cmpl	%eax, %r12d
	jne	LBB0_5
## %bb.11:
	movl	%r12d, %edx
	jmp	LBB0_12
LBB0_1:
	xorl	%eax, %eax
	jmp	LBB0_13
LBB0_7:
	imull	$100, %r12d, %r15d
	movl	$1, %ebx
	movq	_PLAY_STATE@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_rand
	xorl	%edx, %edx
	divl	%r12d
                                        ## kill: def $edx killed $edx def $rdx
	movq	(%r14,%rdx,8), %rax
	cmpq	(%r13), %rax
	je	LBB0_12
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	leal	1(%rbx), %eax
	cmpl	%r15d, %ebx
	movl	%eax, %ebx
	jb	LBB0_8
	jmp	LBB0_12
LBB0_6:
	movl	%eax, (%rcx)
	movl	%eax, %edx
LBB0_12:
	xorl	%eax, %eax
	cmpl	%r12d, %edx
	cmovael	%eax, %edx
	leaq	(%r14,%rdx,8), %rcx
	movq	(%r14,%rdx,8), %rdx
	movq	_PLAY_STATE@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	cmoveq	%rcx, %rax
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PLAY_STATE,8,3                 ## @PLAY_STATE
	.no_dead_strip	_select_proxy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function select_proxy
_select_proxy:                          ; @select_proxy
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	w8, [x3]
	cmp	w8, w2
	b.hs	LBB0_7
; %bb.1:
	mov	x20, x2
	mov	x19, x1
Lloh0:
	adrp	x21, _PLAY_STATE@GOTPAGE
Lloh1:
	ldr	x21, [x21, _PLAY_STATE@GOTPAGEOFF]
	cmp	w0, #128
	b.eq	LBB0_8
; %bb.2:
	cmp	w0, #129
	b.ne	LBB0_10
; %bb.3:
	ldr	x9, [x21]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x19, w8, uxtw #3]
	cmp	x10, x9
	b.eq	LBB0_11
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	w8, w8, #1
	cmp	w20, w8
	b.ne	LBB0_4
; %bb.6:
	mov	x8, x20
	b	LBB0_12
LBB0_7:
	mov	x0, #0
	b	LBB0_13
LBB0_8:
	mov	w8, #100
	mul	w22, w20, w8
	mov	w23, #1
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	bl	_rand
	udiv	w8, w0, w20
	msub	w8, w8, w20, w0
	ldr	x9, [x19, w8, uxtw #3]
	ldr	x10, [x21]
	cmp	x9, x10
	ccmp	w23, w22, #2, ne
	add	w23, w23, #1
	b.lo	LBB0_9
	b	LBB0_12
LBB0_10:
	mov	w8, #0
	b	LBB0_12
LBB0_11:
	str	w8, [x3]
LBB0_12:
	cmp	w8, w20
	csel	w8, w8, wzr, lo
	add	x8, x19, w8, uxtw #3
	ldr	x9, [x8]
	ldr	x10, [x21]
	cmp	x9, x10
	csel	x0, x8, xzr, eq
LBB0_13:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_PLAY_STATE,8,3                 ; @PLAY_STATE
	.no_dead_strip	_select_proxy
.subsections_via_symbols
