	.file	"extr_minilua.c_correctstack.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	correctstack, @function
correctstack:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	mov	r14, rdi
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rsi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rax, QWORD PTR 40[rdi]
	mov	rbp, QWORD PTR [rdi]
	mov	r13, QWORD PTR 32[rdi]
	add	rax, rbp
	sub	rax, rsi
	mov	QWORD PTR 40[rdi], rax
	test	r13, r13
	je	.L2
	.p2align 4,,10
	.p2align 3
.L4:
	mov	rdi, r13
	call	gco2uv@PLT
	mov	rdi, r13
	mov	rbx, QWORD PTR [rax]
	call	gco2uv@PLT
	mov	r13, QWORD PTR 0[r13]
	sub	rbx, r12
	add	rbx, rbp
	mov	rbp, QWORD PTR [r14]
	mov	QWORD PTR [rax], rbx
	test	r13, r13
	jne	.L4
.L2:
	mov	rax, QWORD PTR 24[r14]
	mov	rcx, QWORD PTR 16[r14]
	cmp	rax, rcx
	ja	.L6
	.p2align 4,,10
	.p2align 3
.L5:
	mov	rdx, QWORD PTR 16[rax]
	add	rax, 24
	add	rdx, rbp
	sub	rdx, r12
	mov	QWORD PTR -8[rax], rdx
	mov	rdx, QWORD PTR -16[rax]
	add	rdx, rbp
	sub	rdx, r12
	mov	QWORD PTR -16[rax], rdx
	mov	rdx, QWORD PTR -24[rax]
	add	rdx, rbp
	sub	rdx, r12
	mov	QWORD PTR -24[rax], rdx
	cmp	rax, rcx
	jbe	.L5
.L6:
	mov	rbx, QWORD PTR 8[r14]
	add	rbx, rbp
	sub	rbx, r12
	mov	QWORD PTR 8[r14], rbx
	pop	rbx
	.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
	.cfi_endproc
.LFE0:
	.size	correctstack, .-correctstack
	.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_minilua.c_correctstack.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	correctstack, %function
correctstack:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r0, #20]
	push	{r4, r5, r6, r7, r8, lr}
	ldr	r4, [r0]
	ldr	r8, [r0, #16]
	sub	r3, r3, r1
	add	r3, r4, r3
	cmp	r8, #0
	mov	r6, r0
	mov	r5, r1
	str	r3, [r0, #20]
	beq	.L2
.L4:
	mov	r0, r8
	bl	gco2uv
	ldr	r7, [r0]
	mov	r0, r8
	bl	gco2uv
	ldr	r8, [r8]
	sub	r7, r7, r5
	add	r4, r4, r7
	cmp	r8, #0
	str	r4, [r0]
	ldr	r4, [r6]
	bne	.L4
.L2:
	ldr	r3, [r6, #12]
	ldr	r0, [r6, #8]
	cmp	r3, r0
	addls	r3, r3, #12
	bhi	.L7
.L6:
	ldmdb	r3, {r2, ip, lr}
	sub	lr, lr, r5
	sub	ip, ip, r5
	sub	r2, r2, r5
	add	lr, r4, lr
	add	ip, r4, ip
	add	r2, r4, r2
	cmp	r0, r3
	stmdb	r3, {r2, ip, lr}
	add	r3, r3, #12
	bcs	.L6
.L7:
	ldr	r1, [r6, #4]
	sub	r5, r1, r5
	add	r4, r4, r5
	str	r4, [r6, #4]
	pop	{r4, r5, r6, r7, r8, pc}
	.size	correctstack, .-correctstack
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
