	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, %r14
	movq	%rdi, %r13
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_png_debug
	movl	(%r13), %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_6
## %bb.5:
	movq	%r13, %rdi
	movl	%r15d, %esi
	callq	_png_crc_finish
	leaq	L_.str.2(%rip), %rsi
LBB0_14:
	movq	%r13, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_png_chunk_benign_error         ## TAILCALL
LBB0_1:
	leaq	L_.str.1(%rip), %rsi
	movq	%r13, %rdi
	callq	_png_chunk_error
LBB0_2:
	leal	1(%r15), %ebx
	leaq	L_.str.5(%rip), %rsi
	movl	$2, %edi
	movl	%ebx, %edx
	callq	_png_debug1
	movq	%r13, %rdi
	movl	%ebx, %esi
	movl	$2, %edx
	callq	_png_read_buffer
	testq	%rax, %rax
	je	LBB0_3
## %bb.11:
	movq	%rax, %r12
	movq	%r13, %rdi
	movq	%rax, %rsi
	movl	%r15d, %edx
	callq	_png_crc_read
	movslq	%r15d, %rax
	movl	$0, (%r12,%rax,4)
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_png_crc_finish
	testq	%rax, %rax
	jne	LBB0_28
## %bb.12:
	movl	(%r12), %eax
	decl	%eax
	cmpl	$2, %eax
	jae	LBB0_13
## %bb.15:
	movl	$1, -44(%rbp)
	movl	$0, -48(%rbp)
	leaq	-48(%rbp), %rdx
	leaq	-44(%rbp), %rcx
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_png_check_fp_number
	testq	%rax, %rax
	je	LBB0_18
## %bb.16:
	movslq	-44(%rbp), %rax
	cmpl	%r15d, %eax
	jge	LBB0_18
## %bb.17:
	leal	1(%rax), %ecx
	movl	%ecx, -44(%rbp)
	cmpl	$0, (%r12,%rax,4)
	je	LBB0_20
LBB0_18:
	leaq	L_.str.8(%rip), %rsi
LBB0_19:
	movq	%r13, %rdi
	callq	_png_chunk_benign_error
LBB0_28:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	testq	%r14, %r14
	je	LBB0_9
## %bb.7:
	movq	_PNG_INFO_sCAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	je	LBB0_9
## %bb.8:
	movq	%r13, %rdi
	movl	%r15d, %esi
	callq	_png_crc_finish
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_14
LBB0_3:
	leaq	L_.str.6(%rip), %rsi
	movq	%r13, %rdi
	callq	_png_chunk_benign_error
	movq	%r13, %rdi
	movl	%r15d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_png_crc_finish                 ## TAILCALL
LBB0_9:
	cmpl	$3, %r15d
	jg	LBB0_2
## %bb.10:
	movq	%r13, %rdi
	movl	%r15d, %esi
	callq	_png_crc_finish
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_14
LBB0_13:
	leaq	L_.str.7(%rip), %rsi
	jmp	LBB0_14
LBB0_20:
	movl	-48(%rbp), %edi
	callq	_PNG_FP_IS_POSITIVE
	testq	%rax, %rax
	je	LBB0_21
## %bb.22:
	movl	-44(%rbp), %ebx
	movl	$0, -48(%rbp)
	leaq	-48(%rbp), %rdx
	leaq	-44(%rbp), %rcx
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_png_check_fp_number
	testq	%rax, %rax
	je	LBB0_24
## %bb.23:
	cmpl	%r15d, -44(%rbp)
	jne	LBB0_24
## %bb.25:
	movl	-48(%rbp), %edi
	callq	_PNG_FP_IS_POSITIVE
	testq	%rax, %rax
	je	LBB0_26
## %bb.27:
	movl	(%r12), %edx
	addl	%r12d, %ebx
	leal	1(%r12), %ecx
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	%ebx, %r8d
	callq	_png_set_sCAL_s
	jmp	LBB0_28
LBB0_21:
	leaq	L_.str.9(%rip), %rsi
	jmp	LBB0_19
LBB0_24:
	leaq	L_.str.10(%rip), %rsi
	jmp	LBB0_19
LBB0_26:
	leaq	L_.str.11(%rip), %rsi
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"in png_handle_sCAL"

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

	.comm	_PNG_HAVE_IDAT,4,2              ## @PNG_HAVE_IDAT
L_.str.2:                               ## @.str.2
	.asciz	"out of place"

	.comm	_PNG_INFO_sCAL,4,2              ## @PNG_INFO_sCAL
L_.str.3:                               ## @.str.3
	.asciz	"duplicate"

L_.str.4:                               ## @.str.4
	.asciz	"invalid"

L_.str.5:                               ## @.str.5
	.asciz	"Allocating and reading sCAL chunk data (%u bytes)"

L_.str.6:                               ## @.str.6
	.asciz	"out of memory"

L_.str.7:                               ## @.str.7
	.asciz	"invalid unit"

L_.str.8:                               ## @.str.8
	.asciz	"bad width format"

L_.str.9:                               ## @.str.9
	.asciz	"non-positive width"

L_.str.10:                              ## @.str.10
	.asciz	"bad height format"

L_.str.11:                              ## @.str.11
	.asciz	"non-positive height"

.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:
	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	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_14
; %bb.2:
	mov	x0, x19
	mov	x1, x20
	bl	_png_crc_finish
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_3:
	mov	x0, x19
	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
	b	_png_chunk_benign_error
LBB0_4:
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_png_chunk_error
LBB0_5:
	add	w22, w20, #1
Lloh12:
	adrp	x1, l_.str.5@PAGE
Lloh13:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	w0, #2
	mov	x2, x22
	bl	_png_debug1
	mov	x0, x19
	mov	x1, x22
	mov	w2, #2
	bl	_png_read_buffer
	cbz	x0, LBB0_17
; %bb.6:
	mov	x22, x0
	mov	x0, x19
	mov	x1, x22
	mov	x2, x20
	bl	_png_crc_read
	str	wzr, [x22, w20, sxtw #2]
	mov	x0, x19
	mov	w1, #0
	bl	_png_crc_finish
	cbnz	x0, LBB0_13
; %bb.7:
	ldr	w8, [x22]
	sub	w8, w8, #1
	cmp	w8, #2
	b.hs	LBB0_20
; %bb.8:
	mov	w8, #1
	stp	wzr, w8, [sp, #8]
	add	x2, sp, #8
	add	x3, sp, #12
	mov	x0, x22
	mov	x1, x20
	bl	_png_check_fp_number
	cbz	x0, LBB0_11
; %bb.9:
	ldrsw	x8, [sp, #12]
	cmp	w8, w20
	b.ge	LBB0_11
; %bb.10:
	add	w9, w8, #1
	str	w9, [sp, #12]
	ldr	w8, [x22, x8, lsl #2]
	cbz	w8, LBB0_21
LBB0_11:
Lloh14:
	adrp	x1, l_.str.8@PAGE
Lloh15:
	add	x1, x1, l_.str.8@PAGEOFF
LBB0_12:
	mov	x0, x19
	bl	_png_chunk_benign_error
LBB0_13:
	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
LBB0_14:
	cbz	x21, LBB0_18
; %bb.15:
	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_18
; %bb.16:
	mov	x0, x19
	mov	x1, x20
	bl	_png_crc_finish
Lloh19:
	adrp	x1, l_.str.3@PAGE
Lloh20:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_3
LBB0_17:
Lloh21:
	adrp	x1, l_.str.6@PAGE
Lloh22:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x19
	bl	_png_chunk_benign_error
	mov	x0, x19
	mov	x1, x20
	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
	b	_png_crc_finish
LBB0_18:
	cmp	w20, #3
	b.gt	LBB0_5
; %bb.19:
	mov	x0, x19
	mov	x1, x20
	bl	_png_crc_finish
Lloh23:
	adrp	x1, l_.str.4@PAGE
Lloh24:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_3
LBB0_20:
Lloh25:
	adrp	x1, l_.str.7@PAGE
Lloh26:
	add	x1, x1, l_.str.7@PAGEOFF
	b	LBB0_3
LBB0_21:
	ldr	w0, [sp, #8]
	bl	_PNG_FP_IS_POSITIVE
	cbz	x0, LBB0_26
; %bb.22:
	ldr	w23, [sp, #12]
	str	wzr, [sp, #8]
	add	x2, sp, #8
	add	x3, sp, #12
	mov	x0, x22
	mov	x1, x20
	bl	_png_check_fp_number
	cbz	x0, LBB0_27
; %bb.23:
	ldr	w8, [sp, #12]
	cmp	w8, w20
	b.ne	LBB0_27
; %bb.24:
	ldr	w0, [sp, #8]
	bl	_PNG_FP_IS_POSITIVE
	cbz	x0, LBB0_28
; %bb.25:
	ldr	w2, [x22]
	add	w3, w22, #1
	add	w4, w23, w22
	mov	x0, x19
	mov	x1, x21
	bl	_png_set_sCAL_s
	b	LBB0_13
LBB0_26:
Lloh27:
	adrp	x1, l_.str.9@PAGE
Lloh28:
	add	x1, x1, l_.str.9@PAGEOFF
	b	LBB0_12
LBB0_27:
Lloh29:
	adrp	x1, l_.str.10@PAGE
Lloh30:
	add	x1, x1, l_.str.10@PAGEOFF
	b	LBB0_12
LBB0_28:
Lloh31:
	adrp	x1, l_.str.11@PAGE
Lloh32:
	add	x1, x1, l_.str.11@PAGEOFF
	b	LBB0_12
	.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
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"in png_handle_sCAL"

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

	.comm	_PNG_HAVE_IDAT,4,2              ; @PNG_HAVE_IDAT
l_.str.2:                               ; @.str.2
	.asciz	"out of place"

	.comm	_PNG_INFO_sCAL,4,2              ; @PNG_INFO_sCAL
l_.str.3:                               ; @.str.3
	.asciz	"duplicate"

l_.str.4:                               ; @.str.4
	.asciz	"invalid"

l_.str.5:                               ; @.str.5
	.asciz	"Allocating and reading sCAL chunk data (%u bytes)"

l_.str.6:                               ; @.str.6
	.asciz	"out of memory"

l_.str.7:                               ; @.str.7
	.asciz	"invalid unit"

l_.str.8:                               ; @.str.8
	.asciz	"bad width format"

l_.str.9:                               ; @.str.9
	.asciz	"non-positive width"

l_.str.10:                              ; @.str.10
	.asciz	"bad height format"

l_.str.11:                              ; @.str.11
	.asciz	"non-positive height"

.subsections_via_symbols
