	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mbfl_identify_encoding         ## -- Begin function mbfl_identify_encoding
	.p2align	4, 0x90
_mbfl_identify_encoding:                ## @mbfl_identify_encoding
	.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
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, %ebx
	movq	%rsi, %r13
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	movl	%edx, %edi
	movl	$32, %esi
	callq	_mbfl_calloc
	xorl	%r12d, %r12d
	testq	%rax, %rax
	je	LBB0_32
## %bb.1:
	movq	%rax, %r15
	testq	%r13, %r13
	je	LBB0_5
## %bb.2:
	testl	%ebx, %ebx
	jle	LBB0_5
## %bb.3:
	movl	%ebx, %r14d
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r12d, %edi
	shlq	$5, %rdi
	addq	%r15, %rdi
	movq	(%r13,%rbx,8), %rsi
	callq	_mbfl_identify_filter_init2
	cmpl	$1, %eax
	adcl	$0, %r12d
	incq	%rbx
	cmpq	%rbx, %r14
	jne	LBB0_4
LBB0_5:
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %r14
	movq	%r12, -64(%rbp)                 ## 8-byte Spill
	movl	%r12d, %r15d
	testq	%r14, %r14
	je	LBB0_15
## %bb.6:
	movq	(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_15
## %bb.7:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	decl	%eax
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_10 Depth 2
	cmpl	$0, -64(%rbp)                   ## 4-byte Folded Reload
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	jle	LBB0_13
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movq	%r15, %r13
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_10 Depth=2
	addq	$32, %rbx
	decq	%r13
	je	LBB0_13
LBB0_10:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	cmpq	$0, 16(%rbx)
	jne	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=2
	movzbl	(%r14), %edi
	movq	%rbx, %rsi
	callq	*24(%rbx)
	cmpq	$1, 16(%rbx)
	sbbl	$-1, %r12d
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_8 Depth=1
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	sete	%al
	cmpl	%r12d, -76(%rbp)                ## 4-byte Folded Reload
	setle	%cl
	testb	%cl, %al
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	jne	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_8 Depth=1
	incq	%r14
	decq	%rcx
	jne	LBB0_8
LBB0_15:
	cmpl	$0, -64(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_16
## %bb.17:
	movq	%r15, %rax
	shlq	$5, %rax
	xorl	%ecx, %ecx
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_18
	.p2align	4, 0x90
LBB0_21:                                ##   in Loop: Header=BB0_18 Depth=1
	addq	$32, %rcx
	cmpq	%rcx, %rax
	je	LBB0_23
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	cmpq	$0, 16(%rbx,%rcx)
	jne	LBB0_21
## %bb.19:                              ##   in Loop: Header=BB0_18 Depth=1
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_22
## %bb.20:                              ##   in Loop: Header=BB0_18 Depth=1
	cmpq	$0, 8(%rbx,%rcx)
	jne	LBB0_21
LBB0_22:
	movq	(%rbx,%rcx), %r12
	testq	%r12, %r12
	jne	LBB0_29
LBB0_23:
	leaq	16(%rbx), %rax
	xorl	%r12d, %r12d
	xorl	%ecx, %ecx
	jmp	LBB0_24
	.p2align	4, 0x90
LBB0_28:                                ##   in Loop: Header=BB0_24 Depth=1
	incq	%rcx
	addq	$32, %rax
	cmpq	%rcx, %r15
	je	LBB0_29
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	cmpq	$0, (%rax)
	jne	LBB0_28
## %bb.25:                              ##   in Loop: Header=BB0_24 Depth=1
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_24 Depth=1
	cmpq	$0, -8(%rax)
	jne	LBB0_28
LBB0_27:
	movl	%ecx, %eax
	shlq	$5, %rax
	movq	(%rbx,%rax), %r12
LBB0_29:
	incq	%r15
	.p2align	4, 0x90
LBB0_30:                                ## =>This Inner Loop Header: Depth=1
	leal	-2(%r15), %edi
	shlq	$5, %rdi
	addq	%rbx, %rdi
	callq	_mbfl_identify_filter_cleanup
	decq	%r15
	cmpq	$1, %r15
	ja	LBB0_30
	jmp	LBB0_31
LBB0_16:
	xorl	%r12d, %r12d
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_31:
	movq	%rbx, %rdi
	callq	_mbfl_free
LBB0_32:
	movq	%r12, %rax
	addq	$40, %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	_mbfl_identify_encoding         ; -- Begin function mbfl_identify_encoding
	.p2align	2
_mbfl_identify_encoding:                ; @mbfl_identify_encoding
	.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	x20, x3
	mov	x23, x2
	mov	x22, x1
	mov	x21, x0
	mov	x0, x2
	mov	w1, #32
	bl	_mbfl_calloc
	cbz	x0, LBB0_28
; %bb.1:
	mov	x19, x0
	mov	w24, #0
	cbz	x22, LBB0_5
; %bb.2:
	cmp	w23, #1
	b.lt	LBB0_5
; %bb.3:
	mov	w24, #0
	mov	w23, w23
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	w8, w24
	add	x0, x19, x8, lsl #5
	ldr	x1, [x22], #8
	bl	_mbfl_identify_filter_init2
	cmp	w0, #0
	cinc	w24, w24, eq
	subs	x23, x23, #1
	b.ne	LBB0_4
LBB0_5:
	ldr	x22, [x21, #8]
	cbz	x22, LBB0_15
; %bb.6:
	ldr	x23, [x21]
	cbz	x23, LBB0_15
; %bb.7:
	mov	w25, #0
	sub	w26, w24, #1
	mov	w27, w24
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_11 Depth 2
	cmp	w24, #1
	b.lt	LBB0_13
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x28, x27
	mov	x21, x19
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=2
	add	x21, x21, #32
	subs	x28, x28, #1
	b.eq	LBB0_13
LBB0_11:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x21, #16]
	cbnz	x8, LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=2
	ldr	x8, [x21, #24]
	ldrb	w0, [x22]
	mov	x1, x21
	blr	x8
	ldr	x8, [x21, #16]
	cmp	x8, #0
	cinc	w25, w25, ne
	b	LBB0_10
LBB0_13:                                ;   in Loop: Header=BB0_8 Depth=1
	cmp	w26, w25
	ccmp	w20, #0, #0, le
	b.eq	LBB0_15
; %bb.14:                               ;   in Loop: Header=BB0_8 Depth=1
	add	x22, x22, #1
	sub	x23, x23, #1
	cbnz	x23, LBB0_8
LBB0_15:
	cmp	w24, #1
	b.lt	LBB0_29
; %bb.16:
	mov	w8, w24
	add	x9, x19, #16
	mov	x10, x8
	b	LBB0_18
LBB0_17:                                ;   in Loop: Header=BB0_18 Depth=1
	add	x9, x9, #32
	subs	x10, x10, #1
	b.eq	LBB0_22
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x9]
	cbnz	x11, LBB0_17
; %bb.19:                               ;   in Loop: Header=BB0_18 Depth=1
	cbz	w20, LBB0_21
; %bb.20:                               ;   in Loop: Header=BB0_18 Depth=1
	ldur	x11, [x9, #-8]
	cbnz	x11, LBB0_17
LBB0_21:
	ldur	x21, [x9, #-16]
	cbnz	x21, LBB0_31
LBB0_22:
	mov	x9, #0
	add	x10, x19, #16
	b	LBB0_24
LBB0_23:                                ;   in Loop: Header=BB0_24 Depth=1
	add	x9, x9, #1
	add	x10, x10, #32
	cmp	x8, x9
	b.eq	LBB0_30
LBB0_24:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x10]
	cbnz	x11, LBB0_23
; %bb.25:                               ;   in Loop: Header=BB0_24 Depth=1
	cbz	w20, LBB0_27
; %bb.26:                               ;   in Loop: Header=BB0_24 Depth=1
	ldur	x11, [x10, #-8]
	cbnz	x11, LBB0_23
LBB0_27:
	and	x9, x9, #0xffffffff
	lsl	x9, x9, #5
	ldr	x21, [x19, x9]
	b	LBB0_31
LBB0_28:
	mov	x21, #0
	b	LBB0_34
LBB0_29:
	mov	x21, #0
	b	LBB0_33
LBB0_30:
	mov	x21, #0
LBB0_31:
	add	x20, x8, #1
LBB0_32:                                ; =>This Inner Loop Header: Depth=1
	sub	w8, w20, #2
	add	x0, x19, x8, lsl #5
	bl	_mbfl_identify_filter_cleanup
	sub	x20, x20, #1
	cmp	x20, #1
	b.hi	LBB0_32
LBB0_33:
	mov	x0, x19
	bl	_mbfl_free
LBB0_34:
	mov	x0, x21
	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
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
