	.file	"extr_insert.c_sqlite3TableAffinity.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	sqlite3TableAffinity
	.type	sqlite3TableAffinity, @function
sqlite3TableAffinity:
.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, edx
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	r12, QWORD PTR [rsi]
	test	r12, r12
	je	.L20
.L2:
	mov	edi, 1
	call	assert@PLT
	mov	rdi, r12
	call	sqlite3Strlen30NN@PLT
	mov	ecx, eax
	test	eax, eax
	je	.L1
	test	r13d, r13d
	je	.L9
	sub	rsp, 8
	.cfi_def_cfa_offset 56
	mov	esi, DWORD PTR OP_Affinity[rip]
	mov	edx, r13d
	mov	r9, r12
	push	rax
	.cfi_def_cfa_offset 64
	xor	r8d, r8d
	mov	rdi, rbp
	call	sqlite3VdbeAddOp4@PLT
	pop	rax
	.cfi_def_cfa_offset 56
	pop	rdx
	.cfi_def_cfa_offset 48
.L1:
	pop	rbx
	.cfi_remember_state
	.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
.L20:
	.cfi_restore_state
	mov	rbx, rsi
	call	sqlite3VdbeDb@PLT
	xor	edi, edi
	mov	r14, rax
	mov	eax, DWORD PTR 8[rbx]
	lea	esi, 1[rax]
	call	sqlite3DbMallocRaw@PLT
	mov	r12, rax
	test	rax, rax
	je	.L3
	mov	ecx, DWORD PTR 8[rbx]
	xor	eax, eax
	test	ecx, ecx
	jle	.L21
	.p2align 4,,10
	.p2align 3
.L4:
	mov	rdx, QWORD PTR 16[rbx]
	movzx	edx, BYTE PTR [rdx+rax]
	mov	BYTE PTR [r12+rax], dl
	lea	edx, 1[rax]
	add	rax, 1
	cmp	DWORD PTR 8[rbx], eax
	jg	.L4
	movsx	rdx, edx
	mov	rcx, r12
	lea	rax, [r12+rdx]
	.p2align 4,,10
	.p2align 3
.L7:
	mov	BYTE PTR [rax], 0
	cmp	rcx, rax
	je	.L6
	movzx	edx, BYTE PTR -1[rax]
	sub	rax, 1
	cmp	dl, BYTE PTR SQLITE_AFF_BLOB[rip]
	je	.L7
.L6:
	mov	QWORD PTR [rbx], r12
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L9:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rdx, r12
	mov	rdi, rbp
	mov	esi, -1
	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
	jmp	sqlite3VdbeChangeP4@PLT
	.p2align 4,,10
	.p2align 3
.L3:
	.cfi_restore_state
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rdi, r14
	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
	jmp	sqlite3OomFault@PLT
	.p2align 4,,10
	.p2align 3
.L21:
	.cfi_restore_state
	mov	BYTE PTR [r12], 0
	jmp	.L6
	.cfi_endproc
.LFE0:
	.size	sqlite3TableAffinity, .-sqlite3TableAffinity
	.comm	SQLITE_AFF_BLOB,1,1
	.comm	OP_Affinity,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_insert.c_sqlite3TableAffinity.c"
	.text
	.align	2
	.global	sqlite3TableAffinity
	.syntax unified
	.arm
	.fpu softvfp
	.type	sqlite3TableAffinity, %function
sqlite3TableAffinity:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	ldr	r4, [r1]
	mov	r6, r2
	cmp	r4, #0
	mov	r7, r0
	sub	sp, sp, #16
	beq	.L20
.L2:
	mov	r0, #1
	bl	assert
	mov	r0, r4
	bl	sqlite3Strlen30NN
	subs	r3, r0, #0
	beq	.L1
	cmp	r6, #0
	beq	.L9
	mov	ip, #0
	ldr	r1, .L22
	str	r3, [sp, #8]
	str	r4, [sp, #4]
	str	ip, [sp]
	mov	r2, r6
	mov	r0, r7
	ldr	r1, [r1]
	bl	sqlite3VdbeAddOp4
.L1:
	add	sp, sp, #16
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L20:
	mov	r5, r1
	bl	sqlite3VdbeDb
	ldr	r1, [r5, #4]
	mov	r8, r0
	add	r1, r1, #1
	mov	r0, r4
	bl	sqlite3DbMallocRaw
	subs	r4, r0, #0
	beq	.L3
	ldr	r3, [r5, #4]
	cmp	r3, #0
	movgt	r3, #0
	ble	.L21
.L4:
	ldr	r2, [r5, #8]
	ldrb	r2, [r2, r3]	@ zero_extendqisi2
	strb	r2, [r4, r3]
	ldr	r2, [r5, #4]
	add	r3, r3, #1
	cmp	r2, r3
	bgt	.L4
	mov	r0, #0
	ldr	ip, .L22+4
	add	r3, r4, r3
.L7:
	cmp	r3, r4
	strb	r0, [r3]
	beq	.L6
	ldrb	r2, [r3, #-1]!	@ zero_extendqisi2
	ldrb	r1, [ip]	@ zero_extendqisi2
	cmp	r1, r2
	beq	.L7
.L6:
	str	r4, [r5]
	b	.L2
.L9:
	mov	r2, r4
	mov	r0, r7
	mvn	r1, #0
	add	sp, sp, #16
	@ sp needed
	pop	{r4, r5, r6, r7, r8, lr}
	b	sqlite3VdbeChangeP4
.L3:
	mov	r0, r8
	add	sp, sp, #16
	@ sp needed
	pop	{r4, r5, r6, r7, r8, lr}
	b	sqlite3OomFault
.L21:
	mov	r3, #0
	strb	r3, [r4]
	b	.L6
.L23:
	.align	2
.L22:
	.word	OP_Affinity
	.word	SQLITE_AFF_BLOB
	.size	sqlite3TableAffinity, .-sqlite3TableAffinity
	.comm	SQLITE_AFF_BLOB,1,1
	.comm	OP_Affinity,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
