	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_png_handle_sCAL                ## -- Begin function png_handle_sCAL
	.p2align	4, 0x90
_png_handle_sCAL:                       ## @png_handle_sCAL
	.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	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %r12
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_png_debug
	movl	(%r12), %eax
	movq	_PNG_HAVE_IHDR@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_1
## %bb.4:
	movq	_PNG_HAVE_IDAT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_7
## %bb.5:
	leaq	L_.str.2(%rip), %rsi
LBB0_6:
	movq	%r12, %rdi
	callq	_png_warning
	movq	%r12, %rdi
	movq	%r14, %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_png_crc_finish                 ## TAILCALL
LBB0_1:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	callq	_png_error
LBB0_2:
	leaq	1(%r14), %rbx
	leaq	L_.str.4(%rip), %rsi
	movl	$2, %edi
	movq	%rbx, %rdx
	callq	_png_debug1
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_png_malloc_warn
	testq	%rax, %rax
	je	LBB0_3
## %bb.10:
	movq	%rax, %r15
	movq	%r12, %rdi
	movl	%r15d, %esi
	movq	%r14, %rdx
	callq	_png_crc_read
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_png_crc_finish
	testq	%rax, %rax
	jne	LBB0_15
## %bb.11:
	leaq	(%r15,%r14,4), %rax
	movl	$0, (%r15,%r14,4)
	movq	%r15, %rcx
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	cmpl	$0, (%rcx)
	leaq	4(%rcx), %rcx
	jne	LBB0_12
## %bb.13:
	cmpq	%rcx, %rax
	jae	LBB0_15
## %bb.14:
	leaq	L_.str.6(%rip), %rsi
	movq	%r12, %rdi
	callq	_png_warning
LBB0_15:
	movq	%r12, %rdi
	movq	%r15, %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_png_free                       ## TAILCALL
LBB0_7:
	testq	%r15, %r15
	je	LBB0_2
## %bb.8:
	movq	_PNG_INFO_sCAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_2
## %bb.9:
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_6
LBB0_3:
	leaq	L_.str.5(%rip), %rsi
	movq	%r12, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_png_warning                    ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"in png_handle_sCAL\n"

	.comm	_PNG_HAVE_IHDR,4,2              ## @PNG_HAVE_IHDR
L_.str.1:                               ## @.str.1
	.asciz	"Missing IHDR before sCAL"

	.comm	_PNG_HAVE_IDAT,4,2              ## @PNG_HAVE_IDAT
L_.str.2:                               ## @.str.2
	.asciz	"Invalid sCAL after IDAT"

	.comm	_PNG_INFO_sCAL,4,2              ## @PNG_INFO_sCAL
L_.str.3:                               ## @.str.3
	.asciz	"Duplicate sCAL chunk"

L_.str.4:                               ## @.str.4
	.asciz	"Allocating and reading sCAL chunk data (%lu bytes)\n"

L_.str.5:                               ## @.str.5
	.asciz	"Out of memory while processing sCAL chunk"

L_.str.6:                               ## @.str.6
	.asciz	"Truncated sCAL chunk"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_png_handle_sCAL                ; -- Begin function png_handle_sCAL
	.p2align	2
_png_handle_sCAL:                       ; @png_handle_sCAL
	.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	x20, x2
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_png_debug
	ldr	w8, [x19]
Lloh2:
	adrp	x9, _PNG_HAVE_IHDR@GOTPAGE
Lloh3:
	ldr	x9, [x9, _PNG_HAVE_IHDR@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.1:
Lloh5:
	adrp	x9, _PNG_HAVE_IDAT@GOTPAGE
Lloh6:
	ldr	x9, [x9, _PNG_HAVE_IDAT@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_12
; %bb.2:
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_3:
	mov	x0, x19
	bl	_png_warning
	mov	x0, x19
	mov	x1, x20
	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	_png_crc_finish
LBB0_4:
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_png_error
LBB0_5:
	add	x21, x20, #1
Lloh12:
	adrp	x1, l_.str.4@PAGE
Lloh13:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #2
	mov	x2, x21
	bl	_png_debug1
	mov	x0, x19
	mov	x1, x21
	bl	_png_malloc_warn
	cbz	x0, LBB0_15
; %bb.6:
	mov	x21, x0
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_png_crc_read
	mov	x0, x19
	mov	x1, #0
	bl	_png_crc_finish
	cbnz	x0, LBB0_11
; %bb.7:
	add	x8, x21, x20, lsl #2
	str	wzr, [x8]
	mov	x9, x21
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w10, [x9], #4
	cbnz	w10, LBB0_8
; %bb.9:
	cmp	x8, x9
	b.hs	LBB0_11
; %bb.10:
Lloh14:
	adrp	x1, l_.str.6@PAGE
Lloh15:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x19
	bl	_png_warning
LBB0_11:
	mov	x0, x19
	mov	x1, x21
	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	_png_free
LBB0_12:
	cbz	x21, LBB0_5
; %bb.13:
	ldr	w8, [x21]
Lloh16:
	adrp	x9, _PNG_INFO_sCAL@GOTPAGE
Lloh17:
	ldr	x9, [x9, _PNG_INFO_sCAL@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.14:
Lloh19:
	adrp	x1, l_.str.3@PAGE
Lloh20:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_3
LBB0_15:
Lloh21:
	adrp	x1, l_.str.5@PAGE
Lloh22:
	add	x1, x1, l_.str.5@PAGEOFF
	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	_png_warning
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"in png_handle_sCAL\n"

	.comm	_PNG_HAVE_IHDR,4,2              ; @PNG_HAVE_IHDR
l_.str.1:                               ; @.str.1
	.asciz	"Missing IHDR before sCAL"

	.comm	_PNG_HAVE_IDAT,4,2              ; @PNG_HAVE_IDAT
l_.str.2:                               ; @.str.2
	.asciz	"Invalid sCAL after IDAT"

	.comm	_PNG_INFO_sCAL,4,2              ; @PNG_INFO_sCAL
l_.str.3:                               ; @.str.3
	.asciz	"Duplicate sCAL chunk"

l_.str.4:                               ; @.str.4
	.asciz	"Allocating and reading sCAL chunk data (%lu bytes)\n"

l_.str.5:                               ; @.str.5
	.asciz	"Out of memory while processing sCAL chunk"

l_.str.6:                               ; @.str.6
	.asciz	"Truncated sCAL chunk"

.subsections_via_symbols
