	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sqlite3StrAccumEnlarge
_sqlite3StrAccumEnlarge:                ## @sqlite3StrAccumEnlarge
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r12
	movslq	%esi, %rbx
	movq	(%rdi), %rax
	addq	%rbx, %rax
	xorl	%edi, %edi
	cmpq	8(%r12), %rax
	setge	%dil
	callq	_assert
	movq	16(%r12), %rax
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_SQLITE_TOOBIG@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_testcase
	movq	16(%r12), %rax
	movq	_SQLITE_NOMEM@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_testcase
	jmp	LBB0_21
LBB0_2:
	cmpq	$0, 24(%r12)
	je	LBB0_5
## %bb.3:
	movq	%r12, %rdi
	callq	_isMalloced
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	32(%r12), %rsi
	jmp	LBB0_7
LBB0_5:
	movq	_SQLITE_TOOBIG@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r12, %rdi
	callq	_setStrAccumError
	movl	(%r12), %r14d
	notl	%r14d
	addl	8(%r12), %r14d
	jmp	LBB0_22
LBB0_6:
	xorl	%esi, %esi
LBB0_7:
	movq	(%r12), %rax
	movq	24(%r12), %rcx
	leaq	(%rbx,%rax), %rdx
	incq	%rdx
	addq	%rax, %rbx
	addq	%rbx, %rax
	incq	%rax
	cmpq	%rcx, %rax
	cmovleq	%rax, %rdx
	cmpq	%rcx, %rdx
	jle	LBB0_9
## %bb.8:
	movq	%r12, %rdi
	callq	_sqlite3_str_reset
	movq	_SQLITE_TOOBIG@GOTPCREL(%rip), %rax
	jmp	LBB0_20
LBB0_9:
	movslq	%edx, %rax
	movq	%rax, 8(%r12)
	movq	48(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_11
## %bb.10:
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_sqlite3DbRealloc
	jmp	LBB0_12
LBB0_11:
	movq	%rsi, %rdi
	movl	%edx, %esi
	callq	_sqlite3_realloc64
LBB0_12:
	movq	%rax, %r15
	testq	%rax, %rax
	je	LBB0_19
## %bb.13:
	movl	$1, %edi
	cmpq	$0, 32(%r12)
	jne	LBB0_15
## %bb.14:
	xorl	%edi, %edi
	cmpq	$0, (%r12)
	sete	%dil
LBB0_15:
	callq	_assert
	movq	%r12, %rdi
	callq	_isMalloced
	testq	%rax, %rax
	jne	LBB0_18
## %bb.16:
	movq	(%r12), %rdx
	testq	%rdx, %rdx
	jle	LBB0_18
## %bb.17:
	movq	32(%r12), %rsi
	movq	%r15, %rdi
	callq	_memcpy
LBB0_18:
	movq	%r15, 32(%r12)
	movq	48(%r12), %rdi
	movq	%r15, %rsi
	callq	_sqlite3DbMallocSize
	cltq
	movq	%rax, 8(%r12)
	movq	_SQLITE_PRINTF_MALLOCED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 40(%r12)
	jmp	LBB0_22
LBB0_19:
	movq	%r12, %rdi
	callq	_sqlite3_str_reset
	movq	_SQLITE_NOMEM@GOTPCREL(%rip), %rax
LBB0_20:
	movq	(%rax), %rsi
	movq	%r12, %rdi
	callq	_setStrAccumError
LBB0_21:
	xorl	%r14d, %r14d
LBB0_22:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SQLITE_TOOBIG,8,3              ## @SQLITE_TOOBIG
	.comm	_SQLITE_NOMEM,8,3               ## @SQLITE_NOMEM
	.comm	_SQLITE_PRINTF_MALLOCED,4,2     ## @SQLITE_PRINTF_MALLOCED
	.no_dead_strip	_sqlite3StrAccumEnlarge
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sqlite3StrAccumEnlarge
_sqlite3StrAccumEnlarge:                ; @sqlite3StrAccumEnlarge
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x1
	mov	x19, x0
	ldp	x8, x9, [x0]
	add	x8, x8, w1, sxtw
	cmp	x8, x9
	cset	w0, ge
	bl	_assert
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_2
; %bb.1:
Lloh0:
	adrp	x9, _SQLITE_TOOBIG@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SQLITE_TOOBIG@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_testcase
	ldr	x8, [x19, #16]
Lloh3:
	adrp	x9, _SQLITE_NOMEM@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SQLITE_NOMEM@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_testcase
	mov	w20, #0
	b	LBB0_21
LBB0_2:
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_5
; %bb.3:
	mov	x0, x19
	bl	_isMalloced
	cbz	x0, LBB0_6
; %bb.4:
	ldr	x1, [x19, #32]
	b	LBB0_7
LBB0_5:
Lloh6:
	adrp	x8, _SQLITE_TOOBIG@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SQLITE_TOOBIG@GOTPAGEOFF]
Lloh8:
	ldr	x1, [x8]
	mov	x0, x19
	bl	_setStrAccumError
	ldr	w8, [x19, #8]
	ldr	w9, [x19]
	mvn	w9, w9
	add	w20, w8, w9
	b	LBB0_21
LBB0_6:
	mov	x1, #0
LBB0_7:
	ldr	x8, [x19]
	add	w9, w20, #1
	add	x9, x8, w9, sxtw
	ldr	x10, [x19, #24]
	add	x8, x9, x8
	cmp	x8, x10
	csel	x2, x9, x8, gt
	cmp	x2, x10
	b.le	LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_sqlite3_str_reset
Lloh9:
	adrp	x8, _SQLITE_TOOBIG@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SQLITE_TOOBIG@GOTPAGEOFF]
	b	LBB0_15
LBB0_9:
	sxtw	x8, w2
	str	x8, [x19, #8]
	ldr	x0, [x19, #48]
	cbz	x0, LBB0_13
; %bb.10:
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_sqlite3DbRealloc
	mov	x21, x0
	cbz	x0, LBB0_14
LBB0_11:
	ldr	x8, [x19, #32]
	cbz	x8, LBB0_16
; %bb.12:
	mov	w0, #1
	b	LBB0_17
LBB0_13:
	mov	x0, x1
	mov	x1, x2
	bl	_sqlite3_realloc64
	mov	x21, x0
	cbnz	x0, LBB0_11
LBB0_14:
	mov	x0, x19
	bl	_sqlite3_str_reset
Lloh11:
	adrp	x8, _SQLITE_NOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SQLITE_NOMEM@GOTPAGEOFF]
LBB0_15:
	ldr	x1, [x8]
	mov	x0, x19
	bl	_setStrAccumError
	mov	w20, #0
	b	LBB0_21
LBB0_16:
	ldr	x8, [x19]
	cmp	x8, #0
	cset	w0, eq
LBB0_17:
	bl	_assert
	mov	x0, x19
	bl	_isMalloced
	cbnz	x0, LBB0_20
; %bb.18:
	ldr	x2, [x19]
	cmp	x2, #1
	b.lt	LBB0_20
; %bb.19:
	ldr	x1, [x19, #32]
	mov	x0, x21
	bl	_memcpy
LBB0_20:
	str	x21, [x19, #32]
	ldr	x0, [x19, #48]
	mov	x1, x21
	bl	_sqlite3DbMallocSize
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	str	x8, [x19, #8]
Lloh13:
	adrp	x8, _SQLITE_PRINTF_MALLOCED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _SQLITE_PRINTF_MALLOCED@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	ldr	w9, [x19, #40]
	orr	w8, w9, w8
	str	w8, [x19, #40]
LBB0_21:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_SQLITE_TOOBIG,8,3              ; @SQLITE_TOOBIG
	.comm	_SQLITE_NOMEM,8,3               ; @SQLITE_NOMEM
	.comm	_SQLITE_PRINTF_MALLOCED,4,2     ; @SQLITE_PRINTF_MALLOCED
	.no_dead_strip	_sqlite3StrAccumEnlarge
.subsections_via_symbols
