	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function validate_encoding
_validate_encoding:                     ## @validate_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	%r8d, %r13d
	movq	%rcx, %r15
	movq	%rdx, %rbx
	movq	%rsi, %r12
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	callq	_istarts_with
	xorl	%r14d, %r14d
	testq	%rax, %rax
	je	LBB0_12
## %bb.1:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	callq	_has_prohibited_utf_bom
	testq	%rax, %rax
	je	LBB0_7
## %bb.2:
	movl	%r13d, -52(%rbp)                ## 4-byte Spill
	leaq	L_.str.1(%rip), %rdi
	callq	__
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	leaq	L_.str.2(%rip), %rdi
	callq	__
	movq	%rax, %r15
	movq	$0, -48(%rbp)
	movq	%r12, %rdi
	callq	_xstrdup_toupper
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_strlen
	cltq
	movb	$0, -2(%rax,%r13)
	leaq	L_.str(%rip), %rsi
	leaq	-48(%rbp), %rdx
	movq	%r13, %rdi
	callq	_skip_prefix
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	-48(%rbp), %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-48(%rbp), %rdx
	callq	_skip_prefix
LBB0_4:
	movq	-48(%rbp), %rdx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_advise
	movq	%r13, %rdi
	jmp	LBB0_5
LBB0_7:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	callq	_is_missing_required_utf_bom
	testq	%rax, %rax
	je	LBB0_12
## %bb.8:
	movl	%r13d, -52(%rbp)                ## 4-byte Spill
	leaq	L_.str.4(%rip), %rdi
	callq	__
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	leaq	L_.str.5(%rip), %rdi
	callq	__
	movq	%rax, %r13
	movq	$0, -48(%rbp)
	movq	%r12, %rdi
	callq	_xstrdup_toupper
	movq	%rax, %r15
	leaq	L_.str(%rip), %rsi
	leaq	-48(%rbp), %rdx
	movq	%rax, %rdi
	callq	_skip_prefix
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movq	-48(%rbp), %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-48(%rbp), %rdx
	callq	_skip_prefix
LBB0_10:
	movq	-48(%rbp), %rcx
	xorl	%r14d, %r14d
	movq	%r13, %rdi
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%rcx, %rdx
	xorl	%eax, %eax
	callq	_advise
	movq	%r15, %rdi
LBB0_5:
	callq	_free
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_11
## %bb.6:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r12, %rdx
	callq	_die
	jmp	LBB0_12
LBB0_11:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r12, %rdx
	callq	_error
	movl	%eax, %r14d
LBB0_12:
	movl	%r14d, %eax
	addq	$40, %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	"UTF"

L_.str.1:                               ## @.str.1
	.asciz	"BOM is prohibited in '%s' if encoded as %s"

L_.str.2:                               ## @.str.2
	.asciz	"The file '%s' contains a byte order mark (BOM). Please use UTF-%s as working-tree-encoding."

L_.str.3:                               ## @.str.3
	.asciz	"-"

L_.str.4:                               ## @.str.4
	.asciz	"BOM is required in '%s' if encoded as %s"

L_.str.5:                               ## @.str.5
	.asciz	"The file '%s' is missing a byte order mark (BOM). Please use UTF-%sBE or UTF-%sLE (depending on the byte order) as working-tree-encoding."

	.no_dead_strip	_validate_encoding
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function validate_encoding
_validate_encoding:                     ; @validate_encoding
	.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	x21, x4
	mov	x22, x3
	mov	x23, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_istarts_with
	cbz	x0, LBB0_12
; %bb.1:
	mov	x0, x19
	mov	x1, x23
	mov	x2, x22
	bl	_has_prohibited_utf_bom
	cbz	x0, LBB0_5
; %bb.2:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	__
	mov	x22, x0
Lloh4:
	adrp	x0, l_.str.2@PAGE
Lloh5:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	__
	mov	x23, x0
	str	xzr, [sp, #8]
	mov	x0, x19
	bl	_xstrdup_toupper
	mov	x24, x0
	bl	_strlen
	add	x8, x24, w0, sxtw
	sturb	wzr, [x8, #-2]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #8
	mov	x0, x24
	bl	_skip_prefix
	cbz	x0, LBB0_4
; %bb.3:
	ldr	x0, [sp, #8]
Lloh8:
	adrp	x1, l_.str.3@PAGE
Lloh9:
	add	x1, x1, l_.str.3@PAGEOFF
	add	x2, sp, #8
	bl	_skip_prefix
LBB0_4:
	ldr	x2, [sp, #8]
	b	LBB0_9
LBB0_5:
	mov	x0, x19
	mov	x1, x23
	mov	x2, x22
	bl	_is_missing_required_utf_bom
	cbz	x0, LBB0_12
; %bb.6:
Lloh10:
	adrp	x0, l_.str.4@PAGE
Lloh11:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	__
	mov	x22, x0
Lloh12:
	adrp	x0, l_.str.5@PAGE
Lloh13:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	__
	mov	x23, x0
	str	xzr, [sp, #8]
	mov	x0, x19
	bl	_xstrdup_toupper
	mov	x24, x0
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #8
	bl	_skip_prefix
	cbz	x0, LBB0_8
; %bb.7:
	ldr	x0, [sp, #8]
Lloh16:
	adrp	x1, l_.str.3@PAGE
Lloh17:
	add	x1, x1, l_.str.3@PAGEOFF
	add	x2, sp, #8
	bl	_skip_prefix
LBB0_8:
	ldr	x2, [sp, #8]
	str	x2, [sp]
LBB0_9:
	mov	x0, x23
	mov	x1, x20
	bl	_advise
	mov	x0, x24
	bl	_free
	mov	x0, x22
	mov	x1, x20
	mov	x2, x19
	cbz	w21, LBB0_11
; %bb.10:
	bl	_die
	mov	w0, #0
	b	LBB0_12
LBB0_11:
	bl	_error
LBB0_12:
	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 AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"UTF"

l_.str.1:                               ; @.str.1
	.asciz	"BOM is prohibited in '%s' if encoded as %s"

l_.str.2:                               ; @.str.2
	.asciz	"The file '%s' contains a byte order mark (BOM). Please use UTF-%s as working-tree-encoding."

l_.str.3:                               ; @.str.3
	.asciz	"-"

l_.str.4:                               ; @.str.4
	.asciz	"BOM is required in '%s' if encoded as %s"

l_.str.5:                               ; @.str.5
	.asciz	"The file '%s' is missing a byte order mark (BOM). Please use UTF-%sBE or UTF-%sLE (depending on the byte order) as working-tree-encoding."

	.no_dead_strip	_validate_encoding
.subsections_via_symbols
