	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function konicawc_find_fps
_konicawc_find_fps:                     ## @konicawc_find_fps
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
                                        ## kill: def $esi killed $esi def $rsi
	movl	%edi, %ebx
	leal	(%rsi,%rsi,2), %r15d
	leaq	L_.str(%rip), %rsi
	xorl	%r14d, %r14d
	movl	$1, %edi
	movl	%ebx, %edx
	movl	%r15d, %ecx
	xorl	%eax, %eax
	callq	_DEBUG
	movq	_spd_to_fps@GOTPCREL(%rip), %r12
	movq	(%r12), %rax
	movslq	%ebx, %r13
	movq	(%rax,%r13,8), %rax
	movl	(%rax), %ecx
	cmpl	%ecx, %r15d
	jle	LBB0_10
## %bb.1:
	movq	_MAX_SPEED@GOTPCREL(%rip), %rdx
	movq	(%rdx), %r14
	cmpl	(%rax,%r14,4), %r15d
	jge	LBB0_10
## %bb.2:
	testq	%r14, %r14
	je	LBB0_9
## %bb.3:
	movl	$1, %ebx
	cmpl	%ecx, %r15d
	jl	LBB0_7
	.p2align	4, 0x90
LBB0_5:
	cmpl	(%rax,%rbx,4), %r15d
	jle	LBB0_6
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%rbx, %r14
	je	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	(%rax,%rbx,4), %ecx
	incq	%rbx
	cmpl	%ecx, %r15d
	jge	LBB0_5
	jmp	LBB0_7
LBB0_9:
	incl	%r14d
	jmp	LBB0_10
LBB0_6:
	leaq	-1(%rbx), %r14
	movl	%r14d, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	%ebx, %eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	leaq	L_.str.1(%rip), %rsi
	movl	$2, %edi
	movl	%r15d, %edx
	movl	%r14d, %ecx
	movl	%ebx, %r8d
	xorl	%eax, %eax
	callq	_DEBUG
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rax
	movl	%r15d, %ecx
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	subl	(%rax,%rdx,4), %ecx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movl	(%rax,%rdx,4), %eax
	subl	%r15d, %eax
	cmpl	%eax, %ecx
	cmovll	%r14d, %ebx
	movl	%ebx, %r14d
LBB0_10:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"konica_find_fps: size = %d fps = %d"

	.comm	_spd_to_fps,8,3                 ## @spd_to_fps
	.comm	_MAX_SPEED,8,3                  ## @MAX_SPEED
L_.str.1:                               ## @.str.1
	.asciz	"fps %d between %d and %d"

	.no_dead_strip	_konicawc_find_fps
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function konicawc_find_fps
_konicawc_find_fps:                     ; @konicawc_find_fps
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.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
	mov	x20, x0
	add	w19, w1, w1, lsl #1
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	mov	x2, x20
	mov	x3, x19
	bl	_DEBUG
Lloh2:
	adrp	x21, _spd_to_fps@GOTPAGE
Lloh3:
	ldr	x21, [x21, _spd_to_fps@GOTPAGEOFF]
	ldr	x8, [x21]
	ldr	x8, [x8, w20, sxtw #3]
	ldr	w9, [x8]
	cmp	w19, w9
	b.le	LBB0_7
; %bb.1:
Lloh4:
	adrp	x10, _MAX_SPEED@GOTPAGE
Lloh5:
	ldr	x10, [x10, _MAX_SPEED@GOTPAGEOFF]
Lloh6:
	ldr	x0, [x10]
	ldr	w10, [x8, x0, lsl #2]
	cmp	w19, w10
	b.ge	LBB0_10
; %bb.2:
	cbz	x0, LBB0_8
; %bb.3:
	sxtw	x23, w20
	mov	w22, #1
	cmp	w19, w9
	b.lt	LBB0_5
LBB0_4:
	ldr	w9, [x8, x22, lsl #2]
	cmp	w19, w9
	b.le	LBB0_9
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x0, x22
	b.eq	LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w9, [x8, x22, lsl #2]
	add	x22, x22, #1
	cmp	w19, w9
	b.ge	LBB0_4
	b	LBB0_5
LBB0_7:
	mov	w0, #0
	b	LBB0_10
LBB0_8:
	add	w0, w0, #1
	b	LBB0_10
LBB0_9:
	sub	x20, x22, #1
	str	x22, [sp]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #2
	mov	x2, x19
	mov	x3, x20
	bl	_DEBUG
	ldr	x8, [x21]
	ldr	x8, [x8, x23, lsl #3]
	ldr	w9, [x8, w20, uxtw #2]
	sub	w9, w19, w9
	ldr	w8, [x8, w22, uxtw #2]
	sub	w8, w8, w19
	cmp	w9, w8
	csel	w0, w20, w22, lt
LBB0_10:
                                        ; kill: def $w0 killed $w0 killed $x0
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"konica_find_fps: size = %d fps = %d"

	.comm	_spd_to_fps,8,3                 ; @spd_to_fps
	.comm	_MAX_SPEED,8,3                  ; @MAX_SPEED
l_.str.1:                               ; @.str.1
	.asciz	"fps %d between %d and %d"

	.no_dead_strip	_konicawc_find_fps
.subsections_via_symbols
