	.file	"extr_lapi.c_getupvalref.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Lua function expected"
.LC1:
	.string	"invalid upvalue index"
	.text
	.p2align 4
	.type	getupvalref, @function
getupvalref:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13, rcx
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	movsx	rbx, edx
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	call	index2addr@PLT
	mov	edi, eax
	mov	r12d, eax
	call	ttisLclosure@PLT
	lea	rdx, .LC0[rip]
	mov	rdi, rbp
	mov	esi, eax
	call	api_check@PLT
	mov	edi, r12d
	call	clLvalue@PLT
	xor	esi, esi
	mov	r12, rax
	test	ebx, ebx
	jle	.L2
	mov	rax, QWORD PTR 8[rax]
	xor	esi, esi
	cmp	DWORD PTR [rax], ebx
	setge	sil
.L2:
	lea	rdx, .LC1[rip]
	mov	rdi, rbp
	call	api_check@PLT
	test	r13, r13
	je	.L3
	mov	QWORD PTR 0[r13], r12
.L3:
	mov	rax, QWORD PTR [r12]
	add	rsp, 8
	.cfi_def_cfa_offset 40
	lea	rax, -8[rax+rbx*8]
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	getupvalref, .-getupvalref
	.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_lapi.c_getupvalref.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Lua function expected\000"
	.align	2
.LC1:
	.ascii	"invalid upvalue index\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	getupvalref, %function
getupvalref:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r2
	mov	r7, r3
	mov	r6, r0
	bl	index2addr
	mov	r5, r0
	bl	ttisLclosure
	ldr	r2, .L10
	mov	r1, r0
	mov	r0, r6
	bl	api_check
	mov	r0, r5
	bl	clLvalue
	cmp	r4, #0
	mov	r5, r0
	movle	r1, #0
	ble	.L2
	ldr	r3, [r0, #4]
	ldr	r1, [r3]
	cmp	r1, r4
	movlt	r1, #0
	movge	r1, #1
.L2:
	mov	r0, r6
	ldr	r2, .L10+4
	bl	api_check
	ldr	r0, [r5]
	cmp	r7, #0
	sub	r4, r4, #-1073741823
	strne	r5, [r7]
	add	r0, r0, r4, lsl #2
	pop	{r4, r5, r6, r7, r8, pc}
.L11:
	.align	2
.L10:
	.word	.LC0
	.word	.LC1
	.size	getupvalref, .-getupvalref
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
