	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_r_io_zip_get_by_file_idx       ## -- Begin function r_io_zip_get_by_file_idx
	.p2align	4, 0x90
_r_io_zip_get_by_file_idx:              ## @r_io_zip_get_by_file_idx
	.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
	movq	%rsi, %r14
	movq	%rdx, %rsi
	movl	%ecx, %edx
	movl	%r8d, %ecx
	callq	_r_io_zip_open_archive
	movq	%rax, %r12
	testq	%r14, %r14
	je	LBB0_2
## %bb.1:
	testq	%r12, %r12
	je	LBB0_2
## %bb.3:
	movq	%r12, %rdi
	callq	_zip_get_num_files
	movq	%rax, %r15
	movq	%r14, %rdi
	callq	_atoi
	movq	%rax, %r13
	testq	%rax, %rax
	je	LBB0_4
## %bb.9:
	cmpq	%r15, %r13
	jge	LBB0_2
## %bb.10:
	testq	%r15, %r15
	jg	LBB0_6
	jmp	LBB0_12
LBB0_4:
	cmpb	$48, (%r14)
	jne	LBB0_2
## %bb.5:
	testq	%r15, %r15
	jle	LBB0_2
LBB0_6:
	leaq	-48(%rbp), %rbx
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_zip_stat_init
	movq	%r12, %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	movq	%rbx, %rcx
	callq	_zip_stat_index
	cmpq	%r14, %r13
	je	LBB0_8
## %bb.11:                              ##   in Loop: Header=BB0_7 Depth=1
	incq	%r14
	cmpq	%r14, %r15
	jne	LBB0_7
LBB0_12:
	xorl	%ebx, %ebx
	jmp	LBB0_13
LBB0_2:
	movq	%r12, %rdi
	callq	_zip_close
	xorl	%ebx, %ebx
	jmp	LBB0_14
LBB0_8:
	movl	-48(%rbp), %edi
	callq	_strdup
	movq	%rax, %rbx
LBB0_13:
	movq	%r12, %rdi
	callq	_zip_close
LBB0_14:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_r_io_zip_get_by_file_idx       ; -- Begin function r_io_zip_get_by_file_idx
	.p2align	2
_r_io_zip_get_by_file_idx:              ; @r_io_zip_get_by_file_idx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x22, x1
	mov	x1, x2
	mov	x2, x3
	mov	x3, x4
	bl	_r_io_zip_open_archive
	mov	x19, x0
	cbz	x22, LBB0_11
; %bb.1:
	cbz	x19, LBB0_11
; %bb.2:
	mov	x0, x19
	bl	_zip_get_num_files
	mov	x20, x0
	mov	x0, x22
	bl	_atoi
	mov	x21, x0
	cbz	x0, LBB0_5
; %bb.3:
	cmp	x21, x20
	b.ge	LBB0_11
; %bb.4:
	cmp	x20, #1
	b.ge	LBB0_7
	b	LBB0_10
LBB0_5:
	ldrb	w8, [x22]
	cmp	w8, #48
	b.ne	LBB0_11
; %bb.6:
	cmp	x20, #0
	b.le	LBB0_11
LBB0_7:
	mov	x22, #0
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #8
	bl	_zip_stat_init
	add	x3, sp, #8
	mov	x0, x19
	mov	x1, x22
	mov	w2, #0
	bl	_zip_stat_index
	cmp	x21, x22
	b.eq	LBB0_12
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	add	x22, x22, #1
	cmp	x20, x22
	b.ne	LBB0_8
LBB0_10:
	mov	x20, #0
	b	LBB0_13
LBB0_11:
	mov	x0, x19
	bl	_zip_close
	mov	x20, #0
	b	LBB0_14
LBB0_12:
	ldr	w0, [sp, #8]
	bl	_strdup
	mov	x20, x0
LBB0_13:
	mov	x0, x19
	bl	_zip_close
LBB0_14:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
