	.file	"extr_pnmtologo.c_write_logo_gray256.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Image must be grayscale\n"
	.text
	.p2align 4
	.type	write_logo_gray256, @function
write_logo_gray256:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	lea	r13, .LC0[rip]
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	xor	r12d, r12d
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	esi, DWORD PTR logo_height[rip]
	test	esi, esi
	je	.L3
	.p2align 4,,10
	.p2align 3
.L2:
	mov	ecx, DWORD PTR logo_width[rip]
	mov	ebp, r12d
	xor	ebx, ebx
	sal	rbp, 3
	test	ecx, ecx
	jne	.L5
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L4:
	add	ebx, 1
	cmp	DWORD PTR logo_width[rip], ebx
	jbe	.L7
.L5:
	mov	rdx, QWORD PTR logo_data[rip]
	mov	eax, ebx
	mov	rdx, QWORD PTR [rdx+rbp]
	mov	edi, DWORD PTR [rdx+rax*4]
	call	is_gray@PLT
	test	eax, eax
	jne	.L4
	mov	rdi, r13
	add	ebx, 1
	call	die@PLT
	cmp	DWORD PTR logo_width[rip], ebx
	ja	.L5
.L7:
	add	r12d, 1
	cmp	DWORD PTR logo_height[rip], r12d
	ja	.L2
.L3:
	xor	eax, eax
	xor	r12d, r12d
	call	write_header@PLT
	mov	edx, DWORD PTR logo_height[rip]
	test	edx, edx
	je	.L9
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, DWORD PTR logo_width[rip]
	mov	ebp, r12d
	xor	ebx, ebx
	sal	rbp, 3
	test	eax, eax
	je	.L12
	.p2align 4,,10
	.p2align 3
.L10:
	mov	rax, QWORD PTR logo_data[rip]
	mov	edx, ebx
	add	ebx, 1
	mov	rax, QWORD PTR [rax+rbp]
	mov	edi, DWORD PTR [rax+rdx*4]
	call	write_hex@PLT
	cmp	DWORD PTR logo_width[rip], ebx
	ja	.L10
.L12:
	add	r12d, 1
	cmp	DWORD PTR logo_height[rip], r12d
	ja	.L8
.L9:
	add	rsp, 8
	.cfi_def_cfa_offset 40
	xor	eax, eax
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	write_footer@PLT
	.cfi_endproc
.LFE0:
	.size	write_logo_gray256, .-write_logo_gray256
	.comm	logo_width,4,4
	.comm	logo_height,4,4
	.comm	logo_data,8,8
	.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_pnmtologo.c_write_logo_gray256.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Image must be grayscale\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_logo_gray256, %function
write_logo_gray256:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r6, .L19
	ldr	r3, [r6]
	cmp	r3, #0
	beq	.L3
	mov	r9, #0
	ldr	r5, .L19+4
	ldr	r8, .L19+8
	ldr	r10, .L19+12
.L2:
	ldr	r3, [r5]
	cmp	r3, #0
	movne	r4, #0
	lslne	r7, r9, #2
	bne	.L5
	b	.L7
.L4:
	ldr	r3, [r5]
	cmp	r3, r4
	bls	.L7
.L5:
	ldr	r3, [r8]
	ldr	r3, [r3, r7]
	ldr	r0, [r3, r4, lsl #2]
	bl	is_gray
	cmp	r0, #0
	add	r4, r4, #1
	bne	.L4
	mov	r0, r10
	bl	die
	ldr	r3, [r5]
	cmp	r3, r4
	bhi	.L5
.L7:
	ldr	r3, [r6]
	add	r9, r9, #1
	cmp	r3, r9
	bhi	.L2
.L3:
	bl	write_header
	ldr	r3, [r6]
	cmp	r3, #0
	beq	.L9
	mov	r8, #0
	ldr	r5, .L19+4
	ldr	r9, .L19+8
.L8:
	ldr	r3, [r5]
	cmp	r3, #0
	movne	r4, #0
	lslne	r7, r8, #2
	beq	.L12
.L10:
	ldr	r3, [r9]
	ldr	r3, [r3, r7]
	ldr	r0, [r3, r4, lsl #2]
	bl	write_hex
	ldr	r3, [r5]
	add	r4, r4, #1
	cmp	r3, r4
	bhi	.L10
.L12:
	ldr	r3, [r6]
	add	r8, r8, #1
	cmp	r3, r8
	bhi	.L8
.L9:
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	b	write_footer
.L20:
	.align	2
.L19:
	.word	logo_height
	.word	logo_width
	.word	logo_data
	.word	.LC0
	.size	write_logo_gray256, .-write_logo_gray256
	.comm	logo_width,4,4
	.comm	logo_height,4,4
	.comm	logo_data,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
