	.file	"extr_fse_compress.c_FSE_count_simple.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	FSE_count_simple
	.type	FSE_count_simple, @function
FSE_count_simple:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	mov	r14, rcx
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rsi
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdx
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	r12d, DWORD PTR [rsi]
	xor	esi, esi
	mov	rbx, rdi
	lea	edx, 4[0+r12*4]
	call	memset@PLT
	test	r14, r14
	je	.L2
	lea	rdx, 0[rbp+r14*4]
	cmp	rbp, rdx
	jnb	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	movsx	rax, DWORD PTR 0[rbp]
	add	rbp, 4
	add	DWORD PTR [rbx+rax*4], 1
	cmp	rdx, rbp
	ja	.L3
.L4:
	mov	eax, r12d
	mov	edx, DWORD PTR [rbx+rax*4]
	test	edx, edx
	jne	.L6
	.p2align 4,,10
	.p2align 3
.L7:
	lea	eax, -1[r12]
	mov	r12, rax
	mov	eax, DWORD PTR [rbx+rax*4]
	test	eax, eax
	je	.L7
.L6:
	mov	DWORD PTR 0[r13], r12d
	xor	edx, edx
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L8:
	mov	ecx, edx
	mov	ecx, DWORD PTR [rbx+rcx*4]
	cmp	eax, ecx
	cmovb	rax, rcx
	add	edx, 1
	cmp	edx, r12d
	jbe	.L8
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	pop	rbx
	.cfi_def_cfa_offset 40
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 32
	mov	DWORD PTR 0[r13], 0
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	FSE_count_simple, .-FSE_count_simple
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_fse_compress.c_FSE_count_simple.c"
	.text
	.align	2
	.global	FSE_count_simple
	.syntax unified
	.arm
	.fpu softvfp
	.type	FSE_count_simple, %function
FSE_count_simple:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r5, r3
	ldr	r8, [r1]
	mov	r7, r1
	add	r9, r8, #1
	lsl	r9, r9, #2
	mov	r6, r2
	mov	r1, #0
	mov	r2, r9
	mov	r4, r0
	bl	memset
	cmp	r5, #0
	beq	.L2
	add	r0, r6, r5, lsl #2
	cmp	r6, r0
	bcs	.L4
.L3:
	ldr	r2, [r6], #4
	ldr	r3, [r4, r2, lsl #2]
	cmp	r0, r6
	add	r3, r3, #1
	str	r3, [r4, r2, lsl #2]
	bhi	.L3
.L4:
	sub	r9, r9, #4
	ldr	r3, [r4, r9]
	add	r2, r4, r9
	cmp	r3, #0
	bne	.L6
.L7:
	ldr	r3, [r2, #-4]!
	sub	r8, r8, #1
	cmp	r3, #0
	beq	.L7
.L6:
	mov	r0, #0
	str	r8, [r7]
	sub	r2, r4, #4
	add	r8, r4, r8, lsl #2
.L8:
	ldr	r3, [r2, #4]!
	cmp	r0, r3
	movcc	r0, r3
	cmp	r8, r2
	bne	.L8
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L2:
	mov	r0, r5
	str	r5, [r7]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
	.size	FSE_count_simple, .-FSE_count_simple
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
