	.file	"extr_tjunittest.c_initBuf.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	initBuf
	.type	initBuf, @function
initBuf:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15d, edx
	movsx	rax, ecx
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12d, r8d
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	ebx, esi
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	rdx, QWORD PTR tjPixelSize[rip]
	mov	r13d, DWORD PTR [rdx+rax*4]
	mov	edx, esi
	imul	edx, r15d
	imul	edx, r13d
	cmp	DWORD PTR TJPF_GRAY[rip], ecx
	je	.L42
	cmp	DWORD PTR TJPF_CMYK[rip], ecx
	je	.L43
	mov	rcx, QWORD PTR tjRedOffset[rip]
	xor	esi, esi
	mov	r14d, DWORD PTR [rcx+rax*4]
	mov	rcx, QWORD PTR tjGreenOffset[rip]
	mov	r8d, DWORD PTR [rcx+rax*4]
	mov	rcx, QWORD PTR tjBlueOffset[rip]
	mov	r9d, DWORD PTR [rcx+rax*4]
	mov	DWORD PTR 12[rsp], r8d
	mov	DWORD PTR 8[rsp], r9d
	call	memset@PLT
	test	r15d, r15d
	jle	.L1
	lea	edi, -1[r15]
	mov	r9d, DWORD PTR 8[rsp]
	mov	r8d, DWORD PTR 12[rsp]
	xor	esi, esi
	imul	edi, ebx
	xor	r10d, r10d
	.p2align 4,,10
	.p2align 3
.L23:
	mov	r11d, esi
	xor	edx, edx
	sar	r11d, 3
	test	ebx, ebx
	jg	.L30
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L44:
	cmp	esi, 15
	jg	.L28
	imul	eax, r13d
	lea	ecx, [rax+r14]
	movsx	rcx, ecx
	mov	BYTE PTR 0[rbp+rcx], -1
	lea	ecx, [rax+r8]
	add	eax, r9d
	movsx	rcx, ecx
	cdqe
	mov	BYTE PTR 0[rbp+rcx], -1
	mov	BYTE PTR 0[rbp+rax], -1
.L28:
	add	edx, 1
	cmp	ebx, edx
	je	.L32
.L30:
	test	DWORD PTR TJFLAG_BOTTOMUP[rip], r12d
	lea	ecx, [rdx+r10]
	lea	eax, [rdx+rdi]
	cmove	eax, ecx
	mov	ecx, edx
	sar	ecx, 3
	add	ecx, r11d
	and	ecx, 1
	je	.L44
	imul	eax, r13d
	lea	ecx, [rax+r14]
	movsx	rcx, ecx
	mov	BYTE PTR 0[rbp+rcx], -1
	cmp	esi, 15
	jle	.L28
	add	eax, r8d
	add	edx, 1
	cdqe
	mov	BYTE PTR 0[rbp+rax], -1
	cmp	ebx, edx
	jne	.L30
.L32:
	add	esi, 1
	sub	edi, ebx
	add	r10d, ebx
	cmp	r15d, esi
	jne	.L23
.L1:
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
.L43:
	.cfi_restore_state
	mov	esi, 255
	call	memset@PLT
	test	r15d, r15d
	jle	.L1
	lea	esi, -1[r15]
	xor	edi, edi
	xor	ecx, ecx
	imul	esi, ebx
	.p2align 4,,10
	.p2align 3
.L13:
	mov	r8d, ecx
	xor	edx, edx
	sar	r8d, 3
	test	ebx, ebx
	jg	.L20
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L45:
	cmp	ecx, 15
	jle	.L18
	imul	eax, r13d
	cdqe
	mov	BYTE PTR 3[rbp+rax], 0
.L18:
	add	edx, 1
	cmp	ebx, edx
	je	.L22
.L20:
	test	DWORD PTR TJFLAG_BOTTOMUP[rip], r12d
	lea	r9d, [rdx+rsi]
	lea	eax, [rdx+rdi]
	cmovne	eax, r9d
	mov	r9d, edx
	sar	r9d, 3
	add	r9d, r8d
	and	r9d, 1
	je	.L45
	imul	eax, r13d
	cdqe
	mov	BYTE PTR 2[rbp+rax], 0
	cmp	ecx, 15
	jg	.L18
	add	edx, 1
	mov	BYTE PTR 1[rbp+rax], 0
	cmp	ebx, edx
	jne	.L20
	.p2align 4,,10
	.p2align 3
.L22:
	add	ecx, 1
	sub	esi, ebx
	add	edi, ebx
	cmp	r15d, ecx
	jne	.L13
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
.L42:
	.cfi_restore_state
	xor	esi, esi
	call	memset@PLT
	test	r15d, r15d
	jle	.L1
	lea	ecx, -1[r15]
	xor	esi, esi
	xor	r8d, r8d
	mov	r11d, 76
	imul	ecx, ebx
	mov	r10d, -30
	.p2align 4,,10
	.p2align 3
.L4:
	test	ebx, ebx
	jle	.L11
	mov	edi, r8d
	mov	r9d, r10d
	sar	edi, 3
	cmp	r8d, 15
	cmovle	r9d, r11d
	xor	eax, eax
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L46:
	cmp	r8d, 15
	setle	r13b
	add	eax, 1
	neg	r13d
	mov	BYTE PTR 0[rbp+rdx], r13b
	cmp	ebx, eax
	je	.L11
.L9:
	test	DWORD PTR TJFLAG_BOTTOMUP[rip], r12d
	lea	r13d, [rax+rcx]
	lea	edx, [rax+rsi]
	cmovne	edx, r13d
	mov	r13d, eax
	sar	r13d, 3
	add	r13d, edi
	movsx	rdx, edx
	and	r13d, 1
	je	.L46
	add	eax, 1
	mov	BYTE PTR 0[rbp+rdx], r9b
	cmp	ebx, eax
	jne	.L9
.L11:
	add	r8d, 1
	sub	ecx, ebx
	add	esi, ebx
	cmp	r15d, r8d
	jne	.L4
	add	rsp, 24
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	initBuf, .-initBuf
	.comm	tjRedOffset,8,8
	.comm	tjPixelSize,8,8
	.comm	tjGreenOffset,8,8
	.comm	tjBlueOffset,8,8
	.comm	TJPF_GRAY,4,4
	.comm	TJPF_CMYK,4,4
	.comm	TJFLAG_BOTTOMUP,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_tjunittest.c_initBuf.c"
	.text
	.align	2
	.global	initBuf
	.syntax unified
	.arm
	.fpu softvfp
	.type	initBuf, %function
initBuf:
	@ args = 4, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r4, r1
	ldr	ip, .L44
	sub	sp, sp, #20
	ldr	r1, .L44+4
	ldr	ip, [ip]
	str	r2, [sp, #12]
	mul	r2, r4, r2
	ldr	r1, [r1]
	ldr	r7, [ip, r3, lsl #2]
	cmp	r1, r3
	mov	r6, r0
	mul	r2, r7, r2
	ldr	r5, [sp, #56]
	beq	.L40
	ldr	r1, .L44+8
	ldr	r1, [r1]
	cmp	r1, r3
	beq	.L41
	ldr	lr, .L44+12
	ldr	ip, .L44+16
	ldr	r1, .L44+20
	ldr	r8, [lr]
	ldr	lr, [ip]
	ldr	ip, [r1]
	ldr	lr, [lr, r3, lsl #2]
	ldr	r8, [r8, r3, lsl #2]
	ldr	r3, [ip, r3, lsl #2]
	mov	r1, #0
	str	r3, [sp, #8]
	str	lr, [sp, #4]
	bl	memset
	ldr	r3, [sp, #12]
	cmp	r3, #0
	ble	.L1
	mov	fp, #0
	mvn	ip, #0
	mov	r0, fp
	sub	lr, r3, #1
	mul	lr, r4, lr
	ldr	r10, .L44+24
.L23:
	cmp	r4, #0
	movgt	r3, #0
	asrgt	r9, r0, #3
	bgt	.L30
	b	.L32
.L42:
	cmp	r0, #15
	bgt	.L28
	mla	r2, r7, r2, r6
	ldr	r1, [sp, #4]
	strb	ip, [r2, r8]
	strb	ip, [r2, r1]
	ldr	r1, [sp, #8]
	strb	ip, [r2, r1]
.L28:
	add	r3, r3, #1
	cmp	r4, r3
	beq	.L32
.L30:
	ldr	r1, [r10]
	add	r2, r3, lr
	tst	r5, r1
	add	r1, r9, r3, asr #3
	addeq	r2, r3, fp
	tst	r1, #1
	beq	.L42
	mla	r2, r7, r2, r6
	cmp	r0, #15
	ldrgt	r1, [sp, #4]
	add	r3, r3, #1
	strb	ip, [r2, r8]
	strbgt	ip, [r2, r1]
	cmp	r4, r3
	bne	.L30
.L32:
	ldr	r3, [sp, #12]
	add	r0, r0, #1
	cmp	r3, r0
	sub	lr, lr, r4
	add	fp, fp, r4
	bne	.L23
.L1:
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L41:
	mov	r1, #255
	bl	memset
	ldr	fp, [sp, #12]
	cmp	fp, #0
	ble	.L1
	mov	r9, #0
	mov	r0, r9
	mov	r10, r9
	sub	ip, fp, #1
	mul	ip, r4, ip
	ldr	r8, .L44+24
.L13:
	cmp	r4, #0
	movgt	r3, #0
	asrgt	lr, r0, #3
	bgt	.L20
	b	.L22
.L43:
	cmp	r0, #15
	mlagt	r2, r7, r2, r6
	strbgt	r1, [r2, #3]
.L18:
	add	r3, r3, #1
	cmp	r4, r3
	beq	.L22
.L20:
	ldr	r1, [r8]
	add	r2, r3, ip
	tst	r5, r1
	add	r1, lr, r3, asr #3
	addeq	r2, r3, r9
	ands	r1, r1, #1
	beq	.L43
	mla	r2, r7, r2, r6
	cmp	r0, #15
	add	r3, r3, #1
	strble	r10, [r2, #1]
	cmp	r4, r3
	strb	r10, [r2, #2]
	bne	.L20
.L22:
	add	r0, r0, #1
	cmp	fp, r0
	sub	ip, ip, r4
	add	r9, r9, r4
	bne	.L13
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L40:
	mov	r1, #0
	bl	memset
	ldr	r10, [sp, #12]
	cmp	r10, #0
	ble	.L1
	mov	r8, #0
	mov	lr, r8
	sub	r0, r10, #1
	mul	r0, r4, r0
	ldr	r7, .L44+24
.L4:
	cmp	r4, #0
	ble	.L11
	cmp	lr, #15
	movle	r9, #76
	movgt	r9, #226
	mov	r3, #0
	asr	ip, lr, #3
.L9:
	ldr	r1, [r7]
	add	r2, r3, r0
	tst	r5, r1
	add	r1, ip, r3, asr #3
	addeq	r2, r3, r8
	tst	r1, #1
	strbne	r9, [r6, r2]
	bne	.L8
	cmp	lr, #15
	movgt	r1, #0
	mvnle	r1, #0
	strb	r1, [r6, r2]
.L8:
	add	r3, r3, #1
	cmp	r4, r3
	bne	.L9
.L11:
	add	lr, lr, #1
	cmp	r10, lr
	sub	r0, r0, r4
	add	r8, r8, r4
	bne	.L4
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L45:
	.align	2
.L44:
	.word	tjPixelSize
	.word	TJPF_GRAY
	.word	TJPF_CMYK
	.word	tjRedOffset
	.word	tjGreenOffset
	.word	tjBlueOffset
	.word	TJFLAG_BOTTOMUP
	.size	initBuf, .-initBuf
	.comm	tjRedOffset,4,4
	.comm	tjPixelSize,4,4
	.comm	tjGreenOffset,4,4
	.comm	tjBlueOffset,4,4
	.comm	TJPF_GRAY,4,4
	.comm	TJPF_CMYK,4,4
	.comm	TJFLAG_BOTTOMUP,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
