	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function extract
_extract:                               ## @extract
	.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	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	_PNG_LIBPNG_VER_STRING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%ecx, %ecx
	movl	%ecx, %esi
	movl	%ecx, %edx
	callq	_png_create_read_struct
	movq	%rax, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, (%r14)
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_png_jmpbuf
	movl	%eax, %edi
	callq	_setjmp
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	xorl	%eax, %eax
	movl	%eax, %ebx
	leaq	-40(%rbp), %rdi
	leaq	-32(%rbp), %rsi
	movq	%rbx, %rdx
	jmp	LBB0_12
LBB0_1:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_fprintf
	xorl	%eax, %eax
                                        ## kill: def $rax killed $eax
	jmp	LBB0_13
LBB0_4:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_png_init_io
	movq	%rbx, %rdi
	callq	_png_create_info_struct
	movq	%rax, -32(%rbp)
	movq	%rax, %r15
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_png_error
LBB0_6:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_png_read_info
	leaq	-56(%rbp), %rdx
	leaq	-52(%rbp), %rcx
	leaq	-48(%rbp), %r8
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %r9
	callq	_png_get_iCCP
	movq	_PNG_INFO_iCCP@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_10
## %bb.7:
	movq	(%r14), %r14
	movq	%r14, %rdi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	%rax, %rbx
	movq	-48(%rbp), %rsi
	movq	%rax, %rdi
	movq	%r14, %rdx
	callq	_memcpy
	jmp	LBB0_11
LBB0_10:
	movq	_no_profile@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	jmp	LBB0_11
LBB0_9:
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	callq	_png_error
	xorl	%eax, %eax
	movl	%eax, %ebx
LBB0_11:
	xorl	%eax, %eax
	movl	%eax, %edx
	leaq	-40(%rbp), %rdi
	leaq	-32(%rbp), %rsi
LBB0_12:
	callq	_png_destroy_read_struct
	movq	%rbx, %rax
LBB0_13:
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PNG_LIBPNG_VER_STRING,4,2      ## @PNG_LIBPNG_VER_STRING
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"iccfrompng: version library mismatch?\n"

L_.str.1:                               ## @.str.1
	.asciz	"OOM allocating info structure"

	.comm	_PNG_INFO_iCCP,4,2              ## @PNG_INFO_iCCP
L_.str.2:                               ## @.str.2
	.asciz	"OOM allocating profile buffer"

	.comm	_no_profile,8,3                 ## @no_profile
	.no_dead_strip	_extract
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function extract
_extract:                               ; @extract
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, _PNG_LIBPNG_VER_STRING@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PNG_LIBPNG_VER_STRING@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	w1, #0
	mov	w2, #0
	mov	w3, #0
	bl	_png_create_read_struct
	mov	x8, #0
	stp	xzr, x0, [sp, #16]
	str	xzr, [x19]
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	bl	_png_jmpbuf
	bl	_setjmp
	cbz	x0, LBB0_4
; %bb.2:
	mov	x19, #0
	add	x0, sp, #24
	add	x1, sp, #16
	mov	x2, #0
	b	LBB0_12
LBB0_3:
Lloh3:
	adrp	x8, _stderr@GOTPAGE
Lloh4:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	bl	_fprintf
	mov	x0, #0
	b	LBB0_13
LBB0_4:
	mov	x0, x20
	mov	x1, x21
	bl	_png_init_io
	mov	x0, x20
	bl	_png_create_info_struct
	mov	x21, x0
	str	x0, [sp, #16]
	cbnz	x0, LBB0_6
; %bb.5:
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_png_error
LBB0_6:
	mov	x0, x20
	mov	x1, x21
	bl	_png_read_info
	add	x2, sp, #12
	add	x3, sp, #8
	mov	x4, sp
	mov	x0, x20
	mov	x1, x21
	mov	x5, x19
	bl	_png_get_iCCP
Lloh10:
	adrp	x8, _PNG_INFO_iCCP@GOTPAGE
Lloh11:
	ldr	x8, [x8, _PNG_INFO_iCCP@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_9
; %bb.7:
	ldr	x19, [x19]
	mov	x0, x19
	bl	_malloc
	cbz	x0, LBB0_10
; %bb.8:
	mov	x2, x19
	mov	x19, x0
	ldr	x1, [sp]
	bl	_memcpy
	b	LBB0_11
LBB0_9:
Lloh13:
	adrp	x8, _no_profile@GOTPAGE
Lloh14:
	ldr	x8, [x8, _no_profile@GOTPAGEOFF]
Lloh15:
	ldr	x19, [x8]
	b	LBB0_11
LBB0_10:
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_png_error
	mov	x19, #0
LBB0_11:
	mov	x2, #0
	add	x0, sp, #24
	add	x1, sp, #16
LBB0_12:
	bl	_png_destroy_read_struct
	mov	x0, x19
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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_PNG_LIBPNG_VER_STRING,4,2      ; @PNG_LIBPNG_VER_STRING
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"iccfrompng: version library mismatch?\n"

l_.str.1:                               ; @.str.1
	.asciz	"OOM allocating info structure"

	.comm	_PNG_INFO_iCCP,4,2              ; @PNG_INFO_iCCP
l_.str.2:                               ; @.str.2
	.asciz	"OOM allocating profile buffer"

	.comm	_no_profile,8,3                 ; @no_profile
	.no_dead_strip	_extract
.subsections_via_symbols
