// File: /workspace/github_cpp_makefile_star2_O3/stetre[P]moonvulkan/src/cmd.c
// Function: CmdWaitEvents
static int CmdWaitEvents(lua_State *L)
    {
    if(lua_type(L, 2) == LUA_TTABLE)
        return CmdWaitEvents2(L);
    return CmdWaitEvents1(L);
    return 0;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
movl $0x2, %esi
callq 0x1a0f0
cmpl $0x5, %eax
jne 0x1d077
leaq 0x6f917(%rip), %rcx     # 0x8c909
leaq 0x28(%rsp), %r14
movq %rbx, %rdi
movl $0x1, %esi
movq %r14, %rdx
callq 0x1a4e0
movq %rax, %r12
movq (%r14), %rax
movq 0x50(%rax), %rax
cmpq $0x0, 0x680(%rax)
je 0x1d159
leaq 0x6f985(%rip), %r9      # 0x8c9ab
leaq 0x1c(%rsp), %rdx
leaq 0xc(%rsp), %r15
movq %rbx, %rdi
movl $0x2, %esi
movq %r15, %rcx
xorl %r8d, %r8d
callq 0x19140
movq %rax, %r14
movl (%r15), %edi
testl %edi, %edi
je 0x1d2ec
testq %r14, %r14
je 0x1d065
movq %rbx, %rdi
movq %r14, %rsi
callq 0x182d0
movl 0xc(%rsp), %edi
callq 0x19930
movq %rbx, %rdi
movl $0x2, %esi
jmp 0x1d14f
xorl %ebp, %ebp
movl %ebp, 0x10(%rsp)
movl %ebp, 0x14(%rsp)
movl %ebp, 0x18(%rsp)
leaq 0x6f87d(%rip), %rcx     # 0x8c909
leaq 0x28(%rsp), %rdx
movq %rbx, %rdi
movl $0x1, %esi
callq 0x1a4e0
movq %rax, %r13
movq %rbx, %rdi
movl $0x2, %esi
callq 0x18f60
movq %rax, %r15
movq %rbx, %rdi
movl $0x3, %esi
callq 0x18f60
movq %rax, %r12
leaq 0x6f8e3(%rip), %r9      # 0x8c9ab
leaq 0x1c(%rsp), %rdx
leaq 0xc(%rsp), %r14
movq %rbx, %rdi
movl $0x4, %esi
movq %r14, %rcx
xorl %r8d, %r8d
callq 0x19140
cmpl %ebp, (%r14)
je 0x1d17d
movq %rbx, %rdi
movq %rax, %rsi
callq 0x182d0
movl $0x18, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movl $0x38, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movl $0x48, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movl 0xc(%rsp), %edi
callq 0x19930
movq %rbx, %rdi
movl $0x4, %esi
movq %rax, %rdx
callq 0x18410
jmp 0x1d16a
leaq 0x6f85c(%rip), %rsi     # 0x8c9bc
movq %rbx, %rdi
xorl %eax, %eax
callq 0x19ba0
movl %eax, %ebp
movl %ebp, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, 0x20(%rsp)
movq %r13, 0x40(%rsp)
leaq 0x10(%rsp), %rdx
leaq 0xc(%rsp), %r14
movq %rbx, %rdi
movl $0x5, %esi
movq %r14, %rcx
callq 0x1a350
movq %rax, %rbp
cmpl $0x0, (%r14)
js 0x1d34a
movq %rbp, 0x38(%rsp)
je 0x1d1c2
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x18150
leaq 0x14(%rsp), %rdx
leaq 0xc(%rsp), %r14
movq %rbx, %rdi
movl $0x6, %esi
movq %r14, %rcx
callq 0x18e20
movq %rax, %rbp
cmpl $0x0, (%r14)
js 0x1d3bb
movq %r15, %r13
movq %rbp, 0x30(%rsp)
je 0x1d200
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x18150
leaq 0x18(%rsp), %rdx
leaq 0xc(%rsp), %r14
movq %rbx, %rdi
movl $0x7, %esi
movq %r14, %rcx
callq 0x19240
cmpl $0x0, (%r14)
movq 0x38(%rsp), %rbp
js 0x1d47d
movq %r12, %r15
movq %rax, %r14
je 0x1d23e
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x18150
movq 0x28(%rsp), %rax
movq 0x50(%rax), %rax
movl 0x1c(%rsp), %esi
movl 0x10(%rsp), %r9d
movl 0x14(%rsp), %r10d
movl 0x18(%rsp), %r11d
subq $0x8, %rsp
movq 0x48(%rsp), %rdi
movq 0x28(%rsp), %r12
movq %r12, %rdx
movl %r13d, %ecx
movl %r15d, %r8d
movq %r14, %r15
pushq %r14
pushq %r11
movq 0x48(%rsp), %r14
pushq %r14
pushq %r10
pushq %rbp
callq *0x3d0(%rax)
addq $0x30, %rsp
movq %rbx, %rdi
movq %r12, %rsi
callq 0x182d0
movl 0x10(%rsp), %ecx
movl $0x18, %edx
movq %rbx, %rdi
movq %rbp, %rsi
movl $0x1, %r8d
callq 0x197d0
movl 0x14(%rsp), %ecx
movl $0x38, %edx
movq %rbx, %rdi
movq %r14, %rsi
movl $0x1, %r8d
callq 0x197d0
movl 0x18(%rsp), %ecx
movl $0x48, %edx
movq %rbx, %rdi
movq %r15, %rsi
movl $0x1, %r8d
callq 0x197d0
xorl %ebp, %ebp
jmp 0x1d16c
leaq 0xc(%rsp), %r13
movq %rbx, %rdi
movl $0x3, %esi
movq %r13, %rdx
callq 0x1a5e0
movq %rax, %r15
cmpl $0x0, (%r13)
je 0x1d431
testq %r14, %r14
je 0x1d31f
movq %rbx, %rdi
movq %r14, %rsi
callq 0x182d0
testq %r15, %r15
je 0x1d334
movq %rbx, %rdi
movq %r15, %rsi
movl $0x1, %edx
callq 0x19160
movl 0xc(%rsp), %edi
callq 0x19930
movq %rbx, %rdi
movl $0x3, %esi
jmp 0x1d14f
movq %rbx, %rdi
movq 0x20(%rsp), %rsi
callq 0x182d0
movl 0x10(%rsp), %ecx
movl $0x18, %edx
movq %rbx, %rdi
movq %rbp, %rsi
movl $0x1, %r8d
callq 0x197d0
movl $0x38, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movl $0x48, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x18680
movq %rbx, %rdi
movl $0x5, %esi
jmp 0x1d14f
movq %rbx, %rdi
movq 0x20(%rsp), %rsi
callq 0x182d0
movl 0x10(%rsp), %ecx
movl $0x18, %edx
movq %rbx, %rdi
movq 0x38(%rsp), %rsi
movl $0x1, %r8d
callq 0x197d0
movl 0x14(%rsp), %ecx
movl $0x38, %edx
movq %rbx, %rdi
movq %rbp, %rsi
movl $0x1, %r8d
callq 0x197d0
movl $0x48, %edx
movq %rbx, %rdi
xorl %esi, %esi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x197d0
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x18680
movq %rbx, %rdi
movl $0x6, %esi
jmp 0x1d14f
movq 0x28(%rsp), %rax
movq 0x50(%rax), %rax
movl 0x1c(%rsp), %esi
movq %r12, %rdi
movq %r14, %rdx
movq %r15, %rcx
callq *0x680(%rax)
testq %r14, %r14
je 0x1d45d
movq %rbx, %rdi
movq %r14, %rsi
callq 0x182d0
xorl %ebp, %ebp
testq %r15, %r15
je 0x1d16c
movq %rbx, %rdi
movq %r15, %rsi
movl $0x1, %edx
callq 0x19160
jmp 0x1d16c
movq %rbx, %rdi
movq 0x20(%rsp), %rsi
movq %rax, %r14
callq 0x182d0
movl 0x10(%rsp), %ecx
movl $0x18, %edx
movq %rbx, %rdi
movq %rbp, %rsi
movl $0x1, %r8d
callq 0x197d0
movl 0x14(%rsp), %ecx
movl $0x38, %edx
movq %rbx, %rdi
movq 0x30(%rsp), %rsi
movl $0x1, %r8d
callq 0x197d0
movl 0x18(%rsp), %ecx
movl $0x48, %edx
movq %rbx, %rdi
movq %r14, %rsi
movl $0x1, %r8d
callq 0x197d0
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %edx, %edx
callq 0x18680
movq %rbx, %rdi
movl $0x7, %esi
jmp 0x1d14f