	.file	"extr_makepng.c_insert_iCCP.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"%s: file too long (%lu) for an ICC profile\n"
	.align 8
.LC1:
	.string	"--insert iCCP \"%s\": unrecognized\n"
	.align 8
.LC2:
	.string	"  use '<' to read a file: \"<filename\"\n"
	.align 8
.LC3:
	.string	"makepng: --insert iCCP %s: profile length made a multiple of 4\n"
	.align 8
.LC4:
	.string	"--insert iCCP %s: profile length field wrong:\n"
	.align 8
.LC5:
	.string	"  actual %lu, recorded value %lu (corrected)\n"
	.text
	.p2align 4
	.type	insert_iCCP, @function
insert_iCCP:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13d, esi
	mov	esi, 2
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12d, edi
	mov	edi, edx
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rcx
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	sub	rsp, 16
	.cfi_def_cfa_offset 64
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	QWORD PTR [rsp], 0
	call	check_param_count@PLT
	mov	rdx, QWORD PTR 8[rbp]
	mov	eax, DWORD PTR [rdx]
	cmp	eax, 57
	jle	.L27
	cmp	eax, 60
	jne	.L25
	mov	rsi, rsp
	lea	rdi, 4[rdx]
	call	load_file@PLT
	mov	ebx, eax
	cmp	eax, -4
	ja	.L28
	mov	rdi, QWORD PTR [rsp]
	test	al, 3
	jne	.L6
	test	rdi, rdi
	je	.L1
.L12:
	cmp	ebx, 3
	jle	.L14
	call	png_get_uint_32@PLT
	mov	r14d, eax
	cmp	eax, ebx
	jne	.L29
	mov	r8, QWORD PTR [rsp]
	test	r8, r8
	je	.L1
.L17:
	mov	ecx, DWORD PTR PNG_COMPRESSION_TYPE_BASE[rip]
	mov	rdx, QWORD PTR 0[rbp]
	mov	edi, r12d
	mov	r9d, ebx
	mov	esi, r13d
	call	png_set_iCCP@PLT
	mov	rdi, QWORD PTR [rsp]
	test	rdi, rdi
	je	.L1
.L14:
	call	free@PLT
.L1:
	mov	rax, QWORD PTR 8[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L30
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L27:
	.cfi_restore_state
	cmp	eax, 47
	jg	.L31
.L25:
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC1[rip]
	xor	eax, eax
	call	fprintf@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC2[rip]
	xor	eax, eax
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
	mov	rdi, QWORD PTR [rsp]
	test	rdi, rdi
	jne	.L14
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L28:
	movsx	rcx, eax
	mov	rax, QWORD PTR 8[rbp]
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	lea	rdx, 4[rax]
	xor	eax, eax
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L6:
	mov	edi, DWORD PTR stderr[rip]
	mov	rdx, QWORD PTR 8[rbp]
	lea	rsi, .LC3[rip]
	xor	eax, eax
	call	fprintf@PLT
	lea	eax, 1[rbx]
	mov	rdi, QWORD PTR [rsp]
	cdqe
	.p2align 4,,10
	.p2align 3
.L11:
	mov	QWORD PTR -8[rdi+rax*8], 0
	mov	ebx, eax
	add	rax, 1
	test	bl, 3
	jne	.L11
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L31:
	mov	rsi, rsp
	mov	rdi, rdx
	call	load_fake@PLT
	test	eax, eax
	jg	.L32
	mov	rdx, QWORD PTR 8[rbp]
	jmp	.L25
	.p2align 4,,10
	.p2align 3
.L32:
	and	eax, -4
	mov	rdi, QWORD PTR [rsp]
	mov	esi, eax
	mov	ebx, eax
	call	png_save_uint_32@PLT
	mov	rdi, QWORD PTR [rsp]
	test	rdi, rdi
	je	.L1
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L29:
	mov	rdx, QWORD PTR 8[rbp]
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	xor	eax, eax
	call	fprintf@PLT
	mov	edi, DWORD PTR stderr[rip]
	movsx	rcx, r14d
	xor	eax, eax
	movsx	rdx, ebx
	lea	rsi, .LC5[rip]
	call	fprintf@PLT
	mov	rdi, QWORD PTR [rsp]
	mov	esi, ebx
	call	png_save_uint_32@PLT
	mov	r8, QWORD PTR [rsp]
	test	r8, r8
	jne	.L17
	jmp	.L1
.L30:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	insert_iCCP, .-insert_iCCP
	.comm	stderr,4,4
	.comm	PNG_COMPRESSION_TYPE_BASE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_makepng.c_insert_iCCP.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"%s: file too long (%lu) for an ICC profile\012\000"
	.align	2
.LC1:
	.ascii	"--insert iCCP \"%s\": unrecognized\012\000"
	.align	2
.LC2:
	.ascii	"  use '<' to read a file: \"<filename\"\012\000"
	.align	2
.LC3:
	.ascii	"makepng: --insert iCCP %s: profile length made a mu"
	.ascii	"ltiple of 4\012\000"
	.align	2
.LC4:
	.ascii	"--insert iCCP %s: profile length field wrong:\012\000"
	.align	2
.LC5:
	.ascii	"  actual %lu, recorded value %lu (corrected)\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	insert_iCCP, %function
insert_iCCP:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, lr}
	mov	r5, r3
	mov	r3, #0
	mov	r6, r0
	mov	r0, r2
	ldr	r2, .L32
	sub	sp, sp, #20
	mov	r7, r1
	mov	r1, #2
	ldr	r2, [r2]
	str	r2, [sp, #12]
	mov	r2,#0
	str	r3, [sp, #8]
	bl	check_param_count
	ldr	r0, [r5, #4]
	ldr	r3, [r0]
	cmp	r3, #57
	ble	.L25
	cmp	r3, #60
	bne	.L4
	add	r0, r0, #4
	add	r1, sp, #8
	bl	load_file
	cmn	r0, #4
	mov	r4, r0
	bhi	.L26
	tst	r0, #3
	ldreq	r0, [sp, #8]
	bne	.L27
.L8:
	cmp	r0, #0
	beq	.L1
	cmp	r4, #3
	ble	.L13
	bl	png_get_uint_32
	cmp	r4, r0
	mov	r8, r0
	bne	.L28
	ldr	r3, [sp, #8]
	cmp	r3, #0
	beq	.L1
.L16:
	stm	sp, {r3, r4}
	ldr	ip, .L32+4
	mov	r1, r7
	mov	r0, r6
	ldr	r2, [r5]
	ldr	r3, [ip]
	bl	png_set_iCCP
	ldr	r0, [sp, #8]
	cmp	r0, #0
	beq	.L1
.L13:
	bl	free
.L1:
	ldr	r3, .L32
	ldr	r2, [r3]
	ldr	r3, [sp, #12]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L29
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, pc}
.L25:
	cmp	r3, #47
	bgt	.L30
.L4:
	mov	r2, r0
	ldr	r4, .L32+8
.L23:
	ldr	r1, .L32+12
	ldr	r0, [r4]
	bl	fprintf
	ldr	r1, .L32+16
	ldr	r0, [r4]
	bl	fprintf
	mov	r0, #1
	bl	exit
	ldr	r0, [sp, #8]
	cmp	r0, #0
	bne	.L13
	b	.L1
.L30:
	add	r1, sp, #8
	bl	load_fake
	cmp	r0, #0
	ldrle	r4, .L32+8
	ldrle	r2, [r5, #4]
	ble	.L23
.L31:
	bic	r4, r0, #3
	mov	r1, r4
	ldr	r0, [sp, #8]
	bl	png_save_uint_32
	ldr	r0, [sp, #8]
	b	.L8
.L28:
	ldr	r9, .L32+8
	ldr	r2, [r5, #4]
	ldr	r1, .L32+20
	ldr	r0, [r9]
	bl	fprintf
	mov	r3, r8
	mov	r2, r4
	ldr	r1, .L32+24
	ldr	r0, [r9]
	bl	fprintf
	mov	r1, r4
	ldr	r0, [sp, #8]
	bl	png_save_uint_32
	ldr	r3, [sp, #8]
	cmp	r3, #0
	bne	.L16
	b	.L1
.L26:
	ldr	r2, [r5, #4]
	ldr	r8, .L32+8
	mov	r3, r4
	ldr	r0, [r8]
	ldr	r1, .L32+28
	add	r2, r2, #4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L6:
	ldr	r2, [r5, #4]
	ldr	r0, [r8]
	ldr	r1, .L32+32
	bl	fprintf
	mov	r3, #0
	ldr	r0, [sp, #8]
	sub	r2, r4, #-1073741823
	add	r2, r0, r2, lsl #2
.L11:
	add	r4, r4, #1
	tst	r4, #3
	str	r3, [r2, #4]!
	bne	.L11
	b	.L8
.L27:
	ldr	r8, .L32+8
	b	.L6
.L29:
	bl	__stack_chk_fail
.L33:
	.align	2
.L32:
	.word	.LC6
	.word	PNG_COMPRESSION_TYPE_BASE
	.word	stderr
	.word	.LC1
	.word	.LC2
	.word	.LC4
	.word	.LC5
	.word	.LC0
	.word	.LC3
	.size	insert_iCCP, .-insert_iCCP
	.comm	stderr,4,4
	.comm	PNG_COMPRESSION_TYPE_BASE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
