	.file	"extr_lj_snap.c_snap_restoredata.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	snap_restoredata, @function
snap_restoredata:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15, r8
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14d, ecx
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13, rdi
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 56
	.cfi_def_cfa_offset 112
	mov	QWORD PTR 24[rsp], rsi
	mov	r12d, DWORD PTR 112[rsp]
	mov	DWORD PTR 12[rsp], edx
	mov	QWORD PTR 16[rsp], r9
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L9:
	mov	edi, ebp
	call	regsp_spill@PLT
	mov	rdi, rax
	call	ra_hasspill@PLT
	test	rax, rax
	jne	.L41
	mov	edi, ebp
	call	regsp_reg@PLT
	mov	rdi, rax
	mov	rbp, rax
	call	ra_noreg@PLT
	test	rax, rax
	je	.L12
	xor	edi, edi
	cmp	r12d, 8
	je	.L42
.L13:
	call	lua_assert@PLT
	mov	r15, QWORD PTR 16[rbx]
	mov	r12d, 4
.L14:
	lea	rbx, [r15+r15*2]
	mov	rdi, r15
	sal	rbx, 4
	add	rbx, QWORD PTR 0[r13]
	mov	ebp, DWORD PTR 40[rbx]
	call	irref_isk@PLT
	test	rax, rax
	jne	.L43
	mov	edi, r14d
	mov	rsi, r15
	call	bloomtest@PLT
	mov	edi, eax
	call	LJ_UNLIKELY@PLT
	test	rax, rax
	je	.L9
	mov	esi, DWORD PTR 12[rsp]
	mov	ecx, ebp
	mov	rdx, r15
	mov	rdi, r13
	call	snap_renameref@PLT
	mov	ebp, eax
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L42:
	mov	rax, QWORD PTR IR_CONV[rip]
	cmp	QWORD PTR [rbx], rax
	jne	.L13
	xor	edi, edi
	mov	rax, QWORD PTR IRCONV_NUM_INT[rip]
	cmp	QWORD PTR 8[rbx], rax
	sete	dil
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L43:
	mov	rax, QWORD PTR [rbx]
	cmp	rax, QWORD PTR IR_KNUM[rip]
	je	.L3
	cmp	rax, QWORD PTR IR_KINT64[rip]
	je	.L3
	lea	rbp, 32[rbx]
	cmp	r12d, 8
	jne	.L8
.L11:
	mov	edi, 1
	lea	rbp, 32[rsp]
	call	lua_assert@PLT
.L25:
	mov	eax, DWORD PTR 0[rbp]
	mov	rcx, QWORD PTR 16[rsp]
	mov	DWORD PTR [rcx], eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L41:
	mov	rax, QWORD PTR 24[rsp]
	mov	edi, ebp
	mov	r13, QWORD PTR 16[rax]
	call	regsp_spill@PLT
	lea	rbp, 0[r13+rax*8]
	cmp	r12d, 8
	je	.L44
.L8:
	lea	eax, -1[r12]
	cmp	eax, 1
	setbe	dil
	cmp	r12d, 4
	sete	al
	or	edi, eax
	movzx	edi, dil
.L18:
	call	lua_assert@PLT
	cmp	r12d, 4
	jne	.L22
.L17:
	mov	rax, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR 16[rsp]
	mov	QWORD PTR [rcx], rax
.L1:
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L45
	add	rsp, 56
	.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
	.p2align 4,,10
	.p2align 3
.L3:
	.cfi_restore_state
	lea	rbp, 48[rbx]
.L5:
	lea	eax, -1[r12]
	cmp	eax, 1
	jbe	.L29
	cmp	r12d, 4
	je	.L29
.L24:
	xor	edi, edi
	cmp	r12d, 8
	sete	dil
	call	lua_assert@PLT
.L22:
	cmp	r12d, 8
	je	.L25
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR 16[rsp]
	mov	QWORD PTR [rdx], rax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L12:
	cmp	QWORD PTR RID_MAX_GPR[rip], rbp
	ja	.L15
	mov	rax, QWORD PTR 24[rsp]
	sub	rbp, QWORD PTR RID_MIN_FPR[rip]
	cmp	QWORD PTR LJ_BE[rip], 0
	mov	rax, QWORD PTR [rax]
	lea	rbp, [rax+rbp*4]
	je	.L5
.L39:
	cmp	r12d, 4
	je	.L46
	lea	eax, -1[r12]
	cmp	eax, 1
	ja	.L24
	mov	edi, 1
	call	lua_assert@PLT
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L15:
	mov	rax, QWORD PTR 24[rsp]
	sub	rbp, QWORD PTR RID_MIN_GPR[rip]
	cmp	QWORD PTR LJ_64[rip], 0
	mov	rax, QWORD PTR 8[rax]
	lea	rbp, [rax+rbp*4]
	je	.L5
	cmp	QWORD PTR LJ_BE[rip], 0
	je	.L5
	jmp	.L39
	.p2align 4,,10
	.p2align 3
.L29:
	mov	edi, 1
	jmp	.L18
.L44:
	mov	edi, DWORD PTR 24[rbx]
	call	irt_is64@PLT
	test	eax, eax
	je	.L11
	mov	edi, 1
	call	lua_assert@PLT
	jmp	.L25
.L46:
	mov	edi, 1
	add	rbp, 8
	call	lua_assert@PLT
	jmp	.L17
.L45:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	snap_restoredata, .-snap_restoredata
	.comm	RID_MIN_GPR,8,8
	.comm	RID_MIN_FPR,8,8
	.comm	RID_MAX_GPR,8,8
	.comm	LJ_BE,8,8
	.comm	LJ_64,8,8
	.comm	IR_KNUM,8,8
	.comm	IR_KINT64,8,8
	.comm	IR_CONV,8,8
	.comm	IRCONV_NUM_INT,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_lj_snap.c_snap_restoredata.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	snap_restoredata, %function
snap_restoredata:
	@ args = 12, pretend = 0, frame = 24
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r10, r3
	sub	sp, sp, #28
	ldr	r3, .L56
	str	r1, [sp, #12]
	str	r2, [sp, #4]
	ldr	r3, [r3]
	str	r3, [sp, #20]
	mov	r3,#0
	ldr	r3, [sp, #68]
	mov	r9, r0
	ldr	fp, [sp, #64]
	ldr	r8, [sp, #72]
	str	r3, [sp, #8]
	b	.L14
.L9:
	mov	r0, r4
	bl	regsp_spill
	bl	ra_hasspill
	subs	fp, r0, #0
	mov	r0, r4
	bne	.L50
	bl	regsp_reg
	mov	r4, r0
	bl	ra_noreg
	cmp	r0, #0
	beq	.L12
	cmp	r8, #8
	beq	.L51
.L13:
	mov	r8, #4
	mov	r0, fp
	bl	lua_assert
	ldr	fp, [r5, #8]
.L14:
	ldr	r6, [r9]
	add	r7, fp, fp, lsl #1
	mov	r0, fp
	add	r5, r6, r7, lsl #3
	ldr	r4, [r5, #20]
	bl	irref_isk
	cmp	r0, #0
	bne	.L52
	mov	r1, fp
	mov	r0, r10
	bl	bloomtest
	bl	LJ_UNLIKELY
	cmp	r0, #0
	beq	.L9
	mov	r3, r4
	mov	r2, fp
	mov	r0, r9
	ldr	r1, [sp, #4]
	bl	snap_renameref
	mov	r4, r0
	b	.L9
.L51:
	ldr	r3, .L56+4
	ldr	r1, [r6, r7, lsl #3]
	ldr	r2, [r3]
	cmp	r1, r2
	bne	.L13
	ldr	r2, .L56+8
	ldr	r3, [r5, #4]
	ldr	r0, [r2]
	sub	fp, r3, r0
	clz	fp, fp
	lsr	fp, fp, #5
	b	.L13
.L52:
	ldr	r2, .L56+12
	ldr	r3, [r5]
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L3
	ldr	r2, .L56+16
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L3
	cmp	r8, #8
	addne	r4, r5, #16
	bne	.L8
.L11:
	mov	r0, #1
	bl	lua_assert
	add	r4, sp, #16
	b	.L48
.L50:
	ldr	r3, [sp, #12]
	ldr	r4, [r3, #8]
	bl	regsp_spill
	cmp	r8, #8
	add	r4, r4, r0, lsl #2
	beq	.L53
.L8:
	sub	r0, r8, #1
	cmp	r8, #4
	cmpne	r0, #1
	movls	r0, #1
	movhi	r0, #0
.L18:
	bl	lua_assert
.L48:
	ldr	r3, [r4]
	ldr	r2, [sp, #8]
	str	r3, [r2]
	ldr	r3, .L56
	ldr	r2, [r3]
	ldr	r3, [sp, #20]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L54
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L12:
	ldr	r3, .L56+20
	ldr	r3, [r3]
	cmp	r3, r4
	bhi	.L15
	ldr	r3, .L56+24
	ldr	r2, .L56+28
	ldr	r1, [sp, #12]
	ldr	r3, [r3]
	ldr	r2, [r2]
	ldr	r0, [r1]
	sub	r4, r4, r3
	cmp	r2, #0
	add	r4, r0, r4, lsl #2
	beq	.L5
.L47:
	cmp	r8, #4
	beq	.L55
	sub	r3, r8, #1
	cmp	r3, #1
	bls	.L28
.L25:
	sub	r0, r8, #8
	clz	r0, r0
	lsr	r0, r0, #5
	bl	lua_assert
	b	.L48
.L15:
	ldr	r2, .L56+32
	ldr	r3, .L56+36
	ldr	r1, [sp, #12]
	ldr	r2, [r2]
	ldr	r3, [r3]
	ldr	r0, [r1, #4]
	sub	r4, r4, r2
	cmp	r3, #0
	add	r4, r0, r4, lsl #2
	beq	.L5
	ldr	r3, .L56+28
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L5
	b	.L47
.L3:
	add	r4, r5, #24
.L5:
	sub	r3, r8, #1
	cmp	r8, #4
	cmpne	r3, #1
	bhi	.L25
.L28:
	mov	r0, #1
	b	.L18
.L53:
	ldr	r0, [r5, #12]
	bl	irt_is64
	cmp	r0, #0
	beq	.L11
	b	.L28
.L55:
	mov	r0, #1
	add	r4, r4, #4
	bl	lua_assert
	b	.L48
.L54:
	bl	__stack_chk_fail
.L57:
	.align	2
.L56:
	.word	.LC0
	.word	IR_CONV
	.word	IRCONV_NUM_INT
	.word	IR_KNUM
	.word	IR_KINT64
	.word	RID_MAX_GPR
	.word	RID_MIN_FPR
	.word	LJ_BE
	.word	RID_MIN_GPR
	.word	LJ_64
	.size	snap_restoredata, .-snap_restoredata
	.comm	RID_MIN_GPR,4,4
	.comm	RID_MIN_FPR,4,4
	.comm	RID_MAX_GPR,4,4
	.comm	LJ_BE,4,4
	.comm	LJ_64,4,4
	.comm	IR_KNUM,4,4
	.comm	IR_KINT64,4,4
	.comm	IR_CONV,4,4
	.comm	IRCONV_NUM_INT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
