	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function transform_from_formats
_transform_from_formats:                ## @transform_from_formats
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -44(%rbp)                 ## 4-byte Spill
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	%rdi, %r15
	xorl	%esi, %esi
	movl	$120, %edx
	callq	_memset
	movq	%r14, 112(%r15)
	movq	%rbx, 104(%r15)
	movl	4(%r14), %r13d
	movl	4(%rbx), %r12d
	movq	_PNG_FORMAT_FLAG_LINEAR@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	andl	%r13d, %eax
	movl	$255, %eax
	movl	$65535, %ecx                    ## imm = 0xFFFF
	cmovel	%eax, %ecx
	movl	%ecx, (%r15)
	xorl	%eax, %eax
	movl	(%rbx), %ecx
	andl	%r12d, %ecx
	sete	%al
	movl	%eax, 4(%r15)
	movq	$0, 96(%r15)
	movq	_ACCUMULATE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	andl	(%r14), %eax
	setne	%cl
	movl	%ecx, 8(%r15)
	movl	%r13d, %edi
	callq	_get_pixel
	movq	%rax, 88(%r15)
	movl	%r12d, %edi
	callq	_get_pixel
	movl	-44(%rbp), %r9d                 ## 4-byte Reload
	movq	%rax, 80(%r15)
	movq	_BASE_FORMATS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_PNG_FORMAT_FLAG_COLORMAP@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movl	%r8d, %ecx
	orl	%esi, %ecx
	movl	%ecx, %edx
	andl	%r13d, %edx
	movl	%esi, %edi
	andl	%r13d, %edi
	andl	%r12d, %ecx
	andl	%r12d, %esi
	testl	%r9d, %r9d
	je	LBB0_3
## %bb.1:
	movq	%rbx, %r10
	movl	(%rbx), %ebx
	movl	%ebx, %eax
	orl	%r8d, %eax
	testl	%ecx, %eax
	jne	LBB0_25
## %bb.2:
	movq	_gpc_fn@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%edi, %rdi
	movq	(%rax,%rdi,8), %rdi
	orl	%esi, %ebx
	movslq	%ebx, %rbx
	movq	(%rdi,%rbx,8), %rdi
	movq	%rdi, 72(%r15)
	movq	(%rax,%rbx,8), %rax
	movslq	%esi, %rsi
	movq	(%rax,%rsi,8), %rax
	movq	%rax, 64(%r15)
	movq	_gpc_error_via_linear@GOTPCREL(%rip), %rax
LBB0_9:
	movq	(%rax), %rax
	movslq	%edx, %rdi
	movslq	%ecx, %rsi
	shlq	$3, %rsi
	jmp	LBB0_10
LBB0_3:
	movq	%rbx, %r10
	movl	%edx, %ebx
	notl	%ebx
	movl	%r8d, %eax
	andl	%r12d, %eax
	testl	%ebx, %eax
	je	LBB0_5
## %bb.4:
	movq	_gpc_fn@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%edi, %rdi
	movq	(%rax,%rdi,8), %rax
	movslq	%esi, %rsi
	movq	(%rax,%rsi,8), %rax
	shlq	$3, %rsi
	movq	%rax, 72(%r15)
	movq	$0, 64(%r15)
	movq	_gpc_error_to_colormap@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_10:
	addq	(%rax,%rdi,8), %rsi
	movq	(%rsi), %rsi
	movq	%rsi, 16(%r15)
	movq	$0, 56(%r15)
	movl	%ecx, %eax
	notl	%eax
	andl	%eax, %edx
	movq	_PNG_FORMAT_FLAG_ALPHA@GOTPCREL(%rip), %rax
	testl	%edx, (%rax)
	je	LBB0_23
## %bb.11:
	leaq	32(%r15), %rdx
	movq	%rdx, 56(%r15)
	movl	(%r10), %eax
	andl	%ecx, %eax
	orl	%r9d, %eax
	je	LBB0_15
## %bb.12:
	testl	%r12d, %r8d
	je	LBB0_14
## %bb.13:
	pxor	%xmm0, %xmm0
	movdqu	%xmm0, (%rdx)
	movq	$0, 16(%rdx)
	jmp	LBB0_24
LBB0_15:
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	testq	%rdx, %rdx
	je	LBB0_20
## %bb.16:
	movq	_PNG_FORMAT_FLAG_COLOR@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_18
## %bb.17:
	movq	(%rdx), %rax
	movl	%eax, 32(%r15)
	movq	8(%rdx), %rcx
	movl	%ecx, 36(%r15)
	movq	16(%rdx), %rdx
	movl	%edx, 40(%r15)
	movq	_sRGB_to_d@GOTPCREL(%rip), %rdi
	movq	(%rdi), %rdi
	movl	(%rdi,%rax,8), %eax
	movl	%eax, 44(%r15)
	movl	(%rdi,%rcx,8), %eax
	movl	%eax, 48(%r15)
	movl	(%rdi,%rdx,8), %eax
	movl	%eax, 52(%r15)
	jmp	LBB0_24
LBB0_14:
	movq	_BUFFER_INIT8@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, %ecx
	shll	$8, %ecx
	addl	%eax, %ecx
	movq	$0, 48(%r15)
	movd	%ecx, %xmm0
	pshufd	$64, %xmm0, %xmm0               ## xmm0 = xmm0[0,0,0,1]
	movdqu	%xmm0, 32(%r15)
	jmp	LBB0_24
LBB0_5:
	testl	%r13d, %eax
	jne	LBB0_6
## %bb.7:
	movq	_gpc_fn@GOTPCREL(%rip), %rbx
	jmp	LBB0_8
LBB0_20:
	testl	%r12d, %r8d
	je	LBB0_21
## %bb.22:
	movq	$0, 56(%r15)
LBB0_23:
	movl	$-1, 40(%r15)
	movq	$-1, 32(%r15)
LBB0_24:
	movl	(%rsi), %eax
	movq	24(%r15), %rcx
	movl	%eax, (%rcx)
	movl	4(%rsi), %eax
	movl	%eax, 4(%rcx)
	movl	8(%rsi), %eax
	movl	%eax, 8(%rcx)
	movl	12(%rsi), %eax
	movl	%eax, 12(%rcx)
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_gpc_fn_colormapped@GOTPCREL(%rip), %rbx
LBB0_8:
	movq	(%rbx), %rax
	movslq	%edi, %rdi
	movq	(%rax,%rdi,8), %rax
	movslq	%esi, %rsi
	movq	(%rax,%rsi,8), %rax
	movq	%rax, 72(%r15)
	movq	$0, 64(%r15)
	movq	_gpc_error@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_18:
	movq	8(%rdx), %rax
	jmp	LBB0_19
LBB0_21:
	movq	_BUFFER_INIT8@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
LBB0_19:
	movl	%eax, 40(%r15)
	movl	%eax, 36(%r15)
	movl	%eax, 32(%r15)
	movq	_sRGB_to_d@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rcx,%rax,8), %eax
	movl	%eax, 52(%r15)
	movl	%eax, 48(%r15)
	movl	%eax, 44(%r15)
	jmp	LBB0_24
LBB0_25:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_fprintf
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_PNG_FORMAT_FLAG_LINEAR,4,2     ## @PNG_FORMAT_FLAG_LINEAR
	.comm	_ACCUMULATE,4,2                 ## @ACCUMULATE
	.comm	_BASE_FORMATS,4,2               ## @BASE_FORMATS
	.comm	_PNG_FORMAT_FLAG_COLORMAP,4,2   ## @PNG_FORMAT_FLAG_COLORMAP
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"internal transform via linear error 0x%x->0x%x\n"

	.comm	_gpc_fn,8,3                     ## @gpc_fn
	.comm	_gpc_error_via_linear,8,3       ## @gpc_error_via_linear
	.comm	_gpc_error_to_colormap,8,3      ## @gpc_error_to_colormap
	.comm	_gpc_fn_colormapped,8,3         ## @gpc_fn_colormapped
	.comm	_gpc_error,8,3                  ## @gpc_error
	.comm	_PNG_FORMAT_FLAG_ALPHA,4,2      ## @PNG_FORMAT_FLAG_ALPHA
	.comm	_BUFFER_INIT8,4,2               ## @BUFFER_INIT8
	.comm	_PNG_FORMAT_FLAG_COLOR,4,2      ## @PNG_FORMAT_FLAG_COLOR
	.comm	_sRGB_to_d,8,3                  ## @sRGB_to_d
	.no_dead_strip	_transform_from_formats
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function transform_from_formats
_transform_from_formats:                ; @transform_from_formats
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x21, x4
	mov	x20, x3
	mov	x24, x2
	mov	x25, x1
	mov	x19, x0
	mov	w1, #0
	mov	w2, #120
	bl	_memset
	str	x25, [x19, #112]
	ldr	w23, [x25, #4]
Lloh0:
	adrp	x26, _PNG_FORMAT_FLAG_LINEAR@GOTPAGE
Lloh1:
	ldr	x26, [x26, _PNG_FORMAT_FLAG_LINEAR@GOTPAGEOFF]
	ldr	w8, [x26]
	tst	w8, w23
	mov	w8, #65535
	mov	w9, #255
	csel	w8, w9, w8, eq
	ldr	w22, [x24, #4]
	str	w8, [x19]
	ldr	w8, [x26]
	tst	w8, w22
	cset	w8, eq
	stp	xzr, x24, [x19, #96]
Lloh2:
	adrp	x9, _ACCUMULATE@GOTPAGE
Lloh3:
	ldr	x9, [x9, _ACCUMULATE@GOTPAGEOFF]
	ldr	w10, [x25]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w10
	cset	w9, ne
	stp	w8, w9, [x19, #4]
	mov	x0, x23
	bl	_get_pixel
	str	x0, [x19, #88]
	mov	x0, x22
	bl	_get_pixel
Lloh5:
	adrp	x8, _BASE_FORMATS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _BASE_FORMATS@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	adrp	x9, _PNG_FORMAT_FLAG_COLORMAP@GOTPAGE
Lloh9:
	ldr	x9, [x9, _PNG_FORMAT_FLAG_COLORMAP@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w11, w9, w8
	str	x0, [x19, #80]
	and	w2, w11, w23
	and	w10, w8, w23
	and	w3, w11, w22
	and	w8, w8, w22
	cbz	w21, LBB0_4
; %bb.1:
	ldr	w11, [x26]
	orr	w12, w11, w9
	tst	w12, w3
	b.ne	LBB0_22
; %bb.2:
Lloh11:
	adrp	x12, _gpc_fn@GOTPAGE
Lloh12:
	ldr	x12, [x12, _gpc_fn@GOTPAGEOFF]
Lloh13:
	ldr	x12, [x12]
	ldr	x10, [x12, w10, sxtw #3]
	orr	w11, w11, w8
	sbfiz	x11, x11, #3, #32
	ldr	x10, [x10, x11]
	str	x10, [x19, #72]
	ldr	x10, [x12, x11]
	ldr	x8, [x10, w8, sxtw #3]
	str	x8, [x19, #64]
Lloh14:
	adrp	x8, _gpc_error_via_linear@GOTPAGE
Lloh15:
	ldr	x8, [x8, _gpc_error_via_linear@GOTPAGEOFF]
LBB0_3:
	ldr	x8, [x8]
	ldr	x8, [x8, w2, sxtw #3]
	add	x8, x8, w3, sxtw #3
	b	LBB0_6
LBB0_4:
	and	w11, w9, w22
	bics	wzr, w11, w2
	b.eq	LBB0_14
; %bb.5:
Lloh16:
	adrp	x11, _gpc_fn@GOTPAGE
Lloh17:
	ldr	x11, [x11, _gpc_fn@GOTPAGEOFF]
Lloh18:
	ldr	x11, [x11]
	sbfiz	x10, x10, #3, #32
	ldr	x11, [x11, x10]
	sbfiz	x8, x8, #3, #32
	ldr	x11, [x11, x8]
	stp	xzr, x11, [x19, #64]
Lloh19:
	adrp	x11, _gpc_error_to_colormap@GOTPAGE
Lloh20:
	ldr	x11, [x11, _gpc_error_to_colormap@GOTPAGEOFF]
Lloh21:
	ldr	x11, [x11]
	ldr	x10, [x11, x10]
	add	x8, x10, x8
LBB0_6:
	ldr	x8, [x8]
	str	x8, [x19, #16]
	str	xzr, [x19, #56]
	bic	w10, w2, w3
Lloh22:
	adrp	x11, _PNG_FORMAT_FLAG_ALPHA@GOTPAGE
Lloh23:
	ldr	x11, [x11, _PNG_FORMAT_FLAG_ALPHA@GOTPAGEOFF]
Lloh24:
	ldr	w11, [x11]
	tst	w10, w11
	b.eq	LBB0_17
; %bb.7:
	add	x10, x19, #32
	str	x10, [x19, #56]
	ldr	w11, [x26]
	and	w11, w11, w3
	orr	w11, w11, w21
	cbz	w11, LBB0_10
; %bb.8:
	tst	w9, w22
	b.eq	LBB0_13
; %bb.9:
	stp	xzr, xzr, [x10]
	str	xzr, [x10, #16]
	b	LBB0_18
LBB0_10:
	cbz	x20, LBB0_15
; %bb.11:
Lloh25:
	adrp	x9, _PNG_FORMAT_FLAG_COLOR@GOTPAGE
Lloh26:
	ldr	x9, [x9, _PNG_FORMAT_FLAG_COLOR@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	tst	w9, w3
	b.eq	LBB0_19
; %bb.12:
	ldp	x9, x10, [x20]
	stp	w9, w10, [x19, #32]
Lloh28:
	adrp	x11, _sRGB_to_d@GOTPAGE
Lloh29:
	ldr	x11, [x11, _sRGB_to_d@GOTPAGEOFF]
	ldr	x12, [x20, #16]
Lloh30:
	ldr	x11, [x11]
	ldr	x9, [x11, x9, lsl #3]
	stp	w12, w9, [x19, #40]
	ldr	x9, [x11, x10, lsl #3]
	ldr	x10, [x11, x12, lsl #3]
	stp	w9, w10, [x19, #48]
	b	LBB0_18
LBB0_13:
Lloh31:
	adrp	x9, _BUFFER_INIT8@GOTPAGE
Lloh32:
	ldr	x9, [x9, _BUFFER_INIT8@GOTPAGEOFF]
Lloh33:
	ldr	w9, [x9]
	add	w9, w9, w9, lsl #8
	stp	w9, w9, [x19, #32]
	str	xzr, [x19, #48]
	stp	w9, wzr, [x19, #40]
	b	LBB0_18
LBB0_14:
Lloh34:
	adrp	x12, _gpc_fn@GOTPAGE
Lloh35:
	ldr	x12, [x12, _gpc_fn@GOTPAGEOFF]
Lloh36:
	adrp	x13, _gpc_fn_colormapped@GOTPAGE
Lloh37:
	ldr	x13, [x13, _gpc_fn_colormapped@GOTPAGEOFF]
	tst	w11, w23
	csel	x11, x12, x13, eq
	ldr	x11, [x11]
	ldr	x10, [x11, w10, sxtw #3]
	ldr	x8, [x10, w8, sxtw #3]
	stp	xzr, x8, [x19, #64]
Lloh38:
	adrp	x8, _gpc_error@GOTPAGE
Lloh39:
	ldr	x8, [x8, _gpc_error@GOTPAGEOFF]
	b	LBB0_3
LBB0_15:
	tst	w9, w22
	b.eq	LBB0_20
; %bb.16:
	str	xzr, [x19, #56]
LBB0_17:
	mov	w9, #-1
	str	w9, [x19, #40]
	movi.2d	v0, #0xffffffffffffffff
	str	d0, [x19, #32]
LBB0_18:
	ldr	w9, [x8]
	ldr	x10, [x19, #24]
	str	w9, [x10]
	ldr	w9, [x8, #4]
	str	w9, [x10, #4]
	ldr	w9, [x8, #8]
	str	w9, [x10, #8]
	ldr	w8, [x8, #12]
	str	w8, [x10, #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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_19:
	ldr	x9, [x20, #8]
	b	LBB0_21
LBB0_20:
Lloh40:
	adrp	x9, _BUFFER_INIT8@GOTPAGE
Lloh41:
	ldr	x9, [x9, _BUFFER_INIT8@GOTPAGEOFF]
Lloh42:
	ldrsw	x9, [x9]
LBB0_21:
	stp	w9, w9, [x19, #32]
Lloh43:
	adrp	x10, _sRGB_to_d@GOTPAGE
Lloh44:
	ldr	x10, [x10, _sRGB_to_d@GOTPAGEOFF]
Lloh45:
	ldr	x10, [x10]
	ldr	x10, [x10, x9, lsl #3]
	stp	w10, w10, [x19, #48]
	stp	w9, w10, [x19, #40]
	b	LBB0_18
LBB0_22:
Lloh46:
	adrp	x8, _stderr@GOTPAGE
Lloh47:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh48:
	ldr	w0, [x8]
Lloh49:
	adrp	x1, l_.str@PAGE
Lloh50:
	add	x1, x1, l_.str@PAGEOFF
	bl	_fprintf
	mov	w0, #1
	bl	_exit
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpAdd	Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.cfi_endproc
                                        ; -- End function
	.comm	_PNG_FORMAT_FLAG_LINEAR,4,2     ; @PNG_FORMAT_FLAG_LINEAR
	.comm	_ACCUMULATE,4,2                 ; @ACCUMULATE
	.comm	_BASE_FORMATS,4,2               ; @BASE_FORMATS
	.comm	_PNG_FORMAT_FLAG_COLORMAP,4,2   ; @PNG_FORMAT_FLAG_COLORMAP
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"internal transform via linear error 0x%x->0x%x\n"

	.comm	_gpc_fn,8,3                     ; @gpc_fn
	.comm	_gpc_error_via_linear,8,3       ; @gpc_error_via_linear
	.comm	_gpc_error_to_colormap,8,3      ; @gpc_error_to_colormap
	.comm	_gpc_fn_colormapped,8,3         ; @gpc_fn_colormapped
	.comm	_gpc_error,8,3                  ; @gpc_error
	.comm	_PNG_FORMAT_FLAG_ALPHA,4,2      ; @PNG_FORMAT_FLAG_ALPHA
	.comm	_BUFFER_INIT8,4,2               ; @BUFFER_INIT8
	.comm	_PNG_FORMAT_FLAG_COLOR,4,2      ; @PNG_FORMAT_FLAG_COLOR
	.comm	_sRGB_to_d,8,3                  ; @sRGB_to_d
	.no_dead_strip	_transform_from_formats
.subsections_via_symbols
