	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function process_iTXt
_process_iTXt:                          ## @process_iTXt
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	8(%rdi), %r15
	xorl	%ebx, %ebx
	movl	$0, %edi
	testq	%r15, %r15
	je	LBB0_2
## %bb.1:
	xorl	%edi, %edi
	cmpq	$0, (%r14)
	sete	%dil
LBB0_2:
	callq	_assert
	movl	(%r15), %r12d
	movq	%r15, %rdi
	callq	_setpos
	cmpl	$4, %r12d
	movl	$4, %eax
	cmovll	%r12d, %eax
	movl	%r12d, %r15d
	subl	%eax, %r15d
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	%ebx, %r15d
	je	LBB0_11
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	incl	%ebx
	movq	%r14, %rdi
	callq	_reread_byte
	testq	%rax, %rax
	jne	LBB0_3
## %bb.5:
	movq	%r14, %rdi
	callq	_reread_byte
	testq	%rax, %rax
	je	LBB0_6
## %bb.7:
	subl	%ebx, %r12d
	leal	1(%r12), %r15d
	movq	%r14, %rdi
	callq	_reread_byte
	cmpl	$12, %r15d
	jl	LBB0_11
## %bb.8:
	addl	$4, %ebx
	addl	$-2, %r12d
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_reread_byte
	testq	%rax, %rax
	je	LBB0_14
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	decl	%r12d
	incl	%ebx
	cmpl	$8, %r12d
	ja	LBB0_9
LBB0_11:
	movq	_INVALID_ERROR_CODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	callq	_log_error
	xorl	%eax, %eax
LBB0_12:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_14 Depth=1
	decl	%r12d
	incl	%ebx
	cmpl	$9, %r12d
	jl	LBB0_11
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_reread_byte
	testq	%rax, %rax
	jne	LBB0_13
## %bb.15:
	movq	%r14, %rdi
	movl	%ebx, %esi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_zlib_check                     ## TAILCALL
LBB0_6:
	movl	$1, %eax
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_INVALID_ERROR_CODE,4,2         ## @INVALID_ERROR_CODE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"iTXt chunk length"

	.no_dead_strip	_process_iTXt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function process_iTXt
_process_iTXt:                          ; @process_iTXt
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x19, x0
	ldr	x20, [x0, #8]
	cbz	x20, LBB0_2
; %bb.1:
	ldr	x8, [x19]
	cmp	x8, #0
	cset	w0, eq
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	bl	_assert
	ldr	w21, [x20]
	mov	x0, x20
	bl	_setpos
	mov	w20, #0
	mov	w8, #4
	cmp	w21, #4
	csel	w8, w21, w8, lt
	sub	w22, w21, w8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w22, w20
	b.eq	LBB0_11
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	w20, w20, #1
	mov	x0, x19
	bl	_reread_byte
	cbnz	x0, LBB0_4
; %bb.6:
	mov	x0, x19
	bl	_reread_byte
	cbz	x0, LBB0_16
; %bb.7:
	sub	w8, w21, w20
	add	w22, w8, #1
	mov	x0, x19
	bl	_reread_byte
	cmp	w22, #12
	b.lt	LBB0_11
; %bb.8:
	neg	w20, w20
	sub	w21, w21, #2
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_reread_byte
	cbz	x0, LBB0_14
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	sub	w20, w20, #1
	add	w8, w21, w20
	cmp	w8, #8
	b.hi	LBB0_9
LBB0_11:
Lloh0:
	adrp	x8, _INVALID_ERROR_CODE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _INVALID_ERROR_CODE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_log_error
	mov	w0, #0
LBB0_12:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=1
	sub	w20, w20, #1
	add	w8, w21, w20
	cmp	w8, #9
	b.lt	LBB0_11
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_reread_byte
	cbnz	x0, LBB0_13
; %bb.15:
	mov	w8, #4
	sub	w1, w8, w20
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_zlib_check
LBB0_16:
	mov	w0, #1
	b	LBB0_12
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_INVALID_ERROR_CODE,4,2         ; @INVALID_ERROR_CODE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"iTXt chunk length"

	.no_dead_strip	_process_iTXt
.subsections_via_symbols
