// File: /workspace/github_c_makefile_star2_O3/zenkj[P]luajit-arm64/src/host/minilua.c
// Function: io_readline
static int io_readline(lua_State*L){
FILE*f=*(FILE**)lua_touserdata(L,lua_upvalueindex(1));
int sucess;
if(f==NULL)
luaL_error(L,"file is already closed");
sucess=read_line(L,f);
if(ferror(f))
return luaL_error(L,"%s",strerror(errno));
if(sucess)return 1;
else{
if(lua_toboolean(L,lua_upvalueindex(2))){
lua_settop(L,0);
lua_pushvalue(L,lua_upvalueindex(1));
aux_close(L);
}
return 0;
}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x28(%rdi), %rax
movq 0x8(%rax), %rax
movq (%rax), %rax
leaq 0x28(%rax), %rcx
cmpb $0x0, 0xb(%rax)
leaq 0x3c26(%rip), %r15      # 0x15498
cmoveq %r15, %rcx
xorl %eax, %eax
cmpl $0x7, 0x8(%rcx)
movq (%rcx), %rcx
movl $0x28, %edx
cmovneq %rax, %rdx
movq (%rcx,%rdx), %r14
testq %r14, %r14
je 0x11a51
movq %rbx, %rdi
movq %r14, %rsi
callq 0x11a82
movl %eax, %ebp
movq %r14, %rdi
callq 0x3090
testl %eax, %eax
jne 0x11a62
movl $0x1, %eax
testl %ebp, %ebp
jne 0x11a46
movq 0x28(%rbx), %rax
movq 0x8(%rax), %rcx
movq (%rcx), %rax
leaq 0x38(%rax), %rdx
cmpb $0x2, 0xb(%rax)
cmovbq %r15, %rdx
movl 0x8(%rdx), %eax
testl %eax, %eax
je 0x11a46
cmpl $0x1, %eax
jne 0x118ef
cmpl $0x0, (%rdx)
je 0x11a44
movq 0x10(%rbx), %rdx
movq 0x18(%rbx), %rax
cmpq %rax, %rdx
jae 0x11a18
leaq 0x10(%rdx), %rdi
cmpq %rdi, %rax
cmovaq %rax, %rdi
movq %rdx, %rsi
notq %rsi
addq %rdi, %rsi
movq %rsi, %xmm0
shrq $0x4, %rsi
addq $0x4, %rsi
andq $-0x4, %rsi
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
psrlq $0x4, %xmm0
addq $0x38, %rdx
xorl %edi, %edi
movdqa 0x36d3(%rip), %xmm1     # 0x15010
movdqa 0x36db(%rip), %xmm2     # 0x15020
movdqa 0x36e3(%rip), %xmm3     # 0x15030
pxor %xmm3, %xmm0
pcmpeqd %xmm4, %xmm4
movq %rdi, %xmm5
pshufd $0x44, %xmm5, %xmm5     # xmm5 = xmm5[0,1,0,1]
movdqa %xmm5, %xmm6
por %xmm2, %xmm6
pxor %xmm3, %xmm6
movdqa %xmm6, %xmm7
pcmpgtd %xmm0, %xmm7
pcmpeqd %xmm0, %xmm6
pshufd $0xf5, %xmm6, %xmm8     # xmm8 = xmm6[1,1,3,3]
pand %xmm7, %xmm8
pshufd $0xf5, %xmm7, %xmm6     # xmm6 = xmm7[1,1,3,3]
por %xmm8, %xmm6
movd %xmm6, %r8d
notl %r8d
testb $0x1, %r8b
je 0x119a1
movl $0x0, -0x30(%rdx)
pxor %xmm4, %xmm6
pextrw $0x4, %xmm6, %r8d
testb $0x1, %r8b
je 0x119b8
movl $0x0, -0x20(%rdx)
por %xmm1, %xmm5
pxor %xmm3, %xmm5
movdqa %xmm5, %xmm6
pcmpgtd %xmm0, %xmm6
pcmpeqd %xmm0, %xmm5
pshufd $0xf5, %xmm5, %xmm7     # xmm7 = xmm5[1,1,3,3]
pand %xmm6, %xmm7
pshufd $0xf5, %xmm6, %xmm5     # xmm5 = xmm6[1,1,3,3]
por %xmm7, %xmm5
pxor %xmm4, %xmm5
pextrw $0x0, %xmm5, %r8d
testb $0x1, %r8b
je 0x119f5
movl $0x0, -0x10(%rdx)
pextrw $0x4, %xmm5, %r8d
testb $0x1, %r8b
je 0x11a07
movl $0x0, (%rdx)
addq $0x4, %rdi
addq $0x40, %rdx
cmpq %rdi, %rsi
jne 0x11955
movq %rax, 0x10(%rbx)
movq (%rcx), %rcx
leaq 0x28(%rcx), %rdx
cmpb $0x0, 0xb(%rcx)
cmoveq %r15, %rdx
movq (%rdx), %rcx
movq %rcx, (%rax)
movl 0x8(%rdx), %ecx
movl %ecx, 0x8(%rax)
addq $0x10, 0x10(%rbx)
movq %rbx, %rdi
callq 0x11611
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4590(%rip), %rsi      # 0x15fe8
movq %rbx, %rdi
xorl %eax, %eax
callq 0xa940
callq 0x3050
movl (%rax), %edi
callq 0x32c0
leaq 0x3bfa(%rip), %rsi      # 0x1566f
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0xa940