	.file	"extr_util.c_ToBase64.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	ToBase64
	.type	ToBase64, @function
ToBase64:
.LFB0:
	.cfi_startproc
	endbr64
	add	rdx, rsi
	cmp	rsi, rdx
	jnb	.L13
	push	rbx
	.cfi_def_cfa_offset 16
	.cfi_offset 3, -16
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L20:
	movzx	r8d, BYTE PTR 1[rsi]
	lea	r9, 2[rsi]
	mov	r10d, r8d
	sal	r8d, 2
	shr	r10d, 4
	and	r8d, 60
	cmp	rdx, r9
	jbe	.L18
	movzx	r9d, BYTE PTR 2[rsi]
	add	rsi, 3
	mov	r11d, r9d
	shr	r9d, 6
	or	r8d, r9d
	and	r11d, 63
.L3:
	mov	rbx, QWORD PTR B64EncodeTable[rip]
	mov	r9d, eax
	sal	eax, 4
	add	rdi, 4
	shr	r9d, 2
	and	eax, 48
	movzx	r9d, BYTE PTR [rbx+r9]
	or	eax, r10d
	mov	BYTE PTR -4[rdi], r9b
	mov	r9, QWORD PTR B64EncodeTable[rip]
	movzx	eax, BYTE PTR [r9+rax]
	mov	BYTE PTR -3[rdi], al
	mov	rax, QWORD PTR B64EncodeTable[rip]
	movzx	eax, BYTE PTR [rax+r8]
	mov	BYTE PTR -2[rdi], al
	mov	rax, QWORD PTR B64EncodeTable[rip]
	movzx	eax, BYTE PTR [rax+r11]
	mov	BYTE PTR -1[rdi], al
	cmp	rsi, rdx
	jnb	.L19
.L5:
	lea	r8, 1[rsi]
	movzx	eax, BYTE PTR [rsi]
	cmp	rdx, r8
	ja	.L20
	mov	rsi, r8
	xor	r11d, r11d
	xor	r8d, r8d
	xor	r10d, r10d
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L19:
	test	ecx, ecx
	je	.L1
	mov	BYTE PTR [rdi], 0
.L1:
	pop	rbx
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore 3
	test	ecx, ecx
	je	.L15
	mov	BYTE PTR [rdi], 0
	ret
.L15:
	ret
.L18:
	.cfi_def_cfa_offset 16
	.cfi_offset 3, -16
	mov	rsi, r9
	xor	r11d, r11d
	jmp	.L3
	.cfi_endproc
.LFE0:
	.size	ToBase64, .-ToBase64
	.comm	B64EncodeTable,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_util.c_ToBase64.c"
	.text
	.align	2
	.global	ToBase64
	.syntax unified
	.arm
	.fpu softvfp
	.type	ToBase64, %function
ToBase64:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	add	r2, r1, r2
	cmp	r1, r2
	bcs	.L13
	push	{r4, r5, r6, r7, r8, lr}
	add	ip, r0, #4
	ldr	r4, .L21
	b	.L4
.L20:
	ldrb	r0, [r1, #1]	@ zero_extendqisi2
	cmp	r2, lr
	lsl	r5, r0, #2
	and	r5, r5, #60
	lsr	r6, r0, #4
	bls	.L7
	ldrb	lr, [r1, #2]	@ zero_extendqisi2
	add	r1, r1, #3
	orr	r5, r5, lr, lsr #6
	and	lr, lr, #63
.L3:
	ldr	r8, [r4]
	lsl	r0, r7, #4
	ldrb	r7, [r8, r7, lsr #2]	@ zero_extendqisi2
	and	r0, r0, #48
	strb	r7, [ip, #-4]
	ldr	r7, [r4]
	orr	r0, r0, r6
	ldrb	r0, [r7, r0]	@ zero_extendqisi2
	cmp	r1, r2
	strb	r0, [ip, #-3]
	ldr	r6, [r4]
	mov	r0, ip
	ldrb	r5, [r6, r5]	@ zero_extendqisi2
	add	ip, ip, #4
	strb	r5, [ip, #-6]
	ldr	r5, [r4]
	ldrb	lr, [r5, lr]	@ zero_extendqisi2
	strb	lr, [ip, #-5]
	bcs	.L19
.L4:
	mov	r0, r1
	ldrb	r7, [r0], #1	@ zero_extendqisi2
	add	lr, r1, #2
	cmp	r2, r0
	bhi	.L20
	mov	lr, #0
	mov	r1, r0
	mov	r5, lr
	mov	r6, lr
	b	.L3
.L19:
	cmp	r3, #0
	movne	r3, #0
	strbne	r3, [r0]
	pop	{r4, r5, r6, r7, r8, pc}
.L13:
	cmp	r3, #0
	movne	r3, #0
	strbne	r3, [r0]
	bx	lr
.L7:
	mov	r1, lr
	mov	lr, #0
	b	.L3
.L22:
	.align	2
.L21:
	.word	B64EncodeTable
	.size	ToBase64, .-ToBase64
	.comm	B64EncodeTable,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
