	.file	"extr_palette.c_generate_halftone8_palette.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"expected 17, got %u\n"
.LC1:
	.string	"expected 16, got %u\n"
	.text
	.p2align 4
	.type	generate_halftone8_palette, @function
generate_halftone8_palette:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rdx
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	rbx, rdi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	test	rdx, rdx
	je	.L2
	xor	edi, edi
	cmp	esi, 17
	mov	edx, esi
	sete	dil
	lea	rsi, .LC0[rip]
	call	ok@PLT
.L3:
	mov	rcx, rbx
	xor	edx, edx
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, edx
	and	eax, 1
	cmp	eax, 1
	sbb	eax, eax
	and	al, 1
	sub	eax, 16776961
	test	dl, 2
	je	.L21
	or	ah, -1
.L21:
	mov	DWORD PTR [rcx], eax
	test	dl, 4
	je	.L7
	or	DWORD PTR [rcx], 16711680
.L7:
	add	edx, 1
	add	rcx, 4
	cmp	edx, 8
	jne	.L8
	xor	eax, eax
	mov	edx, 12632256
	lea	rcx, halftone.1931[rip]
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L23:
	mov	edx, DWORD PTR [rcx+rax]
.L10:
	or	edx, -16777216
	mov	DWORD PTR 32[rbx+rax], edx
	add	rax, 4
	cmp	rax, 32
	jne	.L23
	test	rbp, rbp
	je	.L1
	mov	DWORD PTR 64[rbx], 0
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	xor	edi, edi
	cmp	esi, 16
	mov	edx, esi
	sete	dil
	lea	rsi, .LC1[rip]
	call	ok@PLT
	jmp	.L3
	.cfi_endproc
.LFE0:
	.size	generate_halftone8_palette, .-generate_halftone8_palette
	.section	.rodata
	.align 32
	.type	halftone.1931, @object
	.size	halftone.1931, 32
halftone.1931:
	.long	12632256
	.long	8421504
	.long	8388608
	.long	32768
	.long	128
	.long	8421376
	.long	8388736
	.long	32896
	.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_palette.c_generate_halftone8_palette.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"expected 17, got %u\012\000"
	.align	2
.LC1:
	.ascii	"expected 16, got %u\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	generate_halftone8_palette, %function
generate_halftone8_palette:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	subs	r5, r2, #0
	mov	r2, r1
	mov	r4, r0
	subne	r0, r1, #17
	subeq	r0, r2, #16
	clzne	r0, r0
	clzeq	r0, r0
	ldrne	r1, .L25
	ldreq	r1, .L25+4
	lsrne	r0, r0, #5
	lsreq	r0, r0, #5
	bl	ok
	mov	r3, #0
	ldr	r0, .L25+8
	sub	r1, r4, #4
.L8:
	tst	r3, #1
	movne	ip, r0
	moveq	ip, #-16777216
	tst	r3, #2
	add	r1, r1, #4
	orrne	ip, ip, #65280
	str	ip, [r1]
	tst	r3, #4
	ldrne	r2, [r1]
	add	r3, r3, #1
	orrne	r2, r2, #16711680
	strne	r2, [r1]
	cmp	r3, #8
	bne	.L8
	ldr	r2, .L25+12
	ldr	r3, .L25+16
	add	r1, r4, #28
	add	r0, r4, #60
	b	.L10
.L24:
	ldr	r3, [r2, #4]!
.L10:
	orr	r3, r3, #-16777216
	str	r3, [r1, #4]!
	cmp	r1, r0
	bne	.L24
	cmp	r5, #0
	movne	r3, #0
	strne	r3, [r4, #64]
	pop	{r4, r5, r6, pc}
.L26:
	.align	2
.L25:
	.word	.LC0
	.word	.LC1
	.word	-16776961
	.word	.LANCHOR0
	.word	12632256
	.size	generate_halftone8_palette, .-generate_halftone8_palette
	.section	.rodata
	.align	2
	.set	.LANCHOR0,. + 0
	.type	halftone.4215, %object
	.size	halftone.4215, 32
halftone.4215:
	.word	12632256
	.word	8421504
	.word	8388608
	.word	32768
	.word	128
	.word	8421376
	.word	8388736
	.word	32896
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
