// File: /workspace/github_c_makefile_star2_O1/stetre[P]moongl/src/uniform.c
// Function: ProgramUniformv
static int ProgramUniformv(lua_State *L)
/* program_uniformv(program, location, count, type, val1 [, val2 ... val4]) */
    {
    GLuint program = luaL_checkinteger(L, 1);
    GLint location = luaL_checkinteger(L, 2);
    GLsizei count = luaL_checkinteger(L, 3);
    GLenum type = checkuniformtype(L, 4);
    if(count<=0)
        return luaL_error(L, "count should be positive");
#define arg_first 5
    switch(type)
        {
        case NONGL_BOOLEAN: return ProgramUniformv_b(L, program, location, count, arg_first);
        case GL_INT: return ProgramUniformv_i(L, program, location, count, arg_first);
        case GL_UNSIGNED_INT: return ProgramUniformv_ui(L, program, location, count, arg_first);
        case GL_FLOAT: return ProgramUniformv_f(L, program, location, count, arg_first);
        case GL_DOUBLE: return ProgramUniformv_d(L, program, location, count, arg_first);
        default:
            return luaL_error(L, UNEXPECTED_ERROR);
        }
    return 0;
#undef arg_first
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x1, %esi
callq 0x11af0
movq %rax, %r14
movq %rbx, %rdi
movl $0x2, %esi
callq 0x11af0
movq %rax, %r15
movq %rbx, %rdi
movl $0x3, %esi
callq 0x11af0
movq %rax, %r12
movq %rbx, %rdi
movl $0x34, %esi
movl $0x4, %edx
callq 0x11160
testl %r12d, %r12d
jle 0x3b49e
leal -0x1404(%rax), %ecx
cmpl $0x6, %ecx
ja 0x3b4aa
leaq 0x10649(%rip), %rax     # 0x4ba60
movslq (%rax,%rcx,4), %rcx
addq %rax, %rcx
jmpq *%rcx
movq %rbx, %rdi
movl $0x5, %esi
callq 0x3ba44
movl %eax, %ebp
cltd
idivl %r12d
testl %edx, %edx
jne 0x3b759
movl %eax, 0x4(%rsp)
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movslq %ebp, %rsi
shlq $0x2, %rsi
movq %rbx, %rdi
callq 0x11200
movq %rax, %r13
testl %ebp, %ebp
jle 0x3b526
movl %ebp, %r15d
xorl %ebp, %ebp
leaq 0x5(%rbp), %r14
movq %rbx, %rdi
movl %r14d, %esi
callq 0x115c0
testl %eax, %eax
je 0x3b792
movq %rbx, %rdi
movl %r14d, %esi
xorl %edx, %edx
callq 0x11040
movl %eax, (%r13,%rbp,4)
incq %rbp
cmpq %rbp, %r15
jne 0x3b468
jmp 0x3b526
leaq 0x10627(%rip), %rsi     # 0x4bacc
jmp 0x3b760
testl %eax, %eax
jne 0x3b543
movq %rbx, %rdi
movl $0x5, %esi
callq 0x3ba44
movl %eax, %ebp
cltd
idivl %r12d
testl %edx, %edx
jne 0x3b759
movl %eax, 0x4(%rsp)
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movslq %ebp, %rsi
shlq $0x2, %rsi
movq %rbx, %rdi
callq 0x11200
movq %rax, %r13
testl %ebp, %ebp
jle 0x3b526
movl %ebp, %r15d
xorl %ebp, %ebp
leaq 0x5(%rbp), %r14
movq %rbx, %rdi
movl %r14d, %esi
callq 0x11860
movq %rbx, %rdi
cmpl $0x1, %eax
jne 0x3b7ac
movl %r14d, %esi
callq 0x11710
movl %eax, (%r13,%rbp,4)
incq %rbp
cmpq %rbp, %r15
jne 0x3b4f6
movl 0x4(%rsp), %eax
decl %eax
cmpl $0x4, %eax
jae 0x3b74e
movl %eax, %eax
leaq 0x1a7f2(%rip), %rcx     # 0x55d30
jmp 0x3b723
leaq 0x3d3b(%rip), %rsi      # 0x3f285
leaq 0xefaa(%rip), %rdx      # 0x4a4fb
movq %rbx, %rdi
movl $0x111, %ecx            # imm = 0x111
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x11ae0
movq %rbx, %rdi
movl $0x5, %esi
callq 0x3ba44
movl %eax, %ebp
cltd
idivl %r12d
testl %edx, %edx
jne 0x3b759
movl %eax, 0x4(%rsp)
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movslq %ebp, %rsi
shlq $0x2, %rsi
movq %rbx, %rdi
callq 0x11200
movq %rax, %r13
testl %ebp, %ebp
jle 0x3b5e9
movl %ebp, %r15d
xorl %ebp, %ebp
leaq 0x5(%rbp), %r14
movq %rbx, %rdi
movl %r14d, %esi
callq 0x113a0
testl %eax, %eax
je 0x3b778
movq %rbx, %rdi
movl %r14d, %esi
xorl %edx, %edx
callq 0x11790
cvtsd2ss %xmm0, %xmm0
movss %xmm0, (%r13,%rbp,4)
incq %rbp
cmpq %rbp, %r15
jne 0x3b5b2
movl 0x4(%rsp), %eax
decl %eax
cmpl $0x4, %eax
jae 0x3b74e
movl %eax, %eax
leaq 0x1a76f(%rip), %rcx     # 0x55d70
jmp 0x3b723
movq %rbx, %rdi
movl $0x5, %esi
callq 0x3ba44
movl %eax, %ebp
cltd
idivl %r12d
testl %edx, %edx
jne 0x3b759
movl %eax, 0x4(%rsp)
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movslq %ebp, %rsi
shlq $0x3, %rsi
movq %rbx, %rdi
callq 0x11200
movq %rax, %r13
testl %ebp, %ebp
jle 0x3b67d
movl %ebp, %r15d
xorl %ebp, %ebp
leaq 0x5(%rbp), %r14
movq %rbx, %rdi
movl %r14d, %esi
callq 0x113a0
testl %eax, %eax
je 0x3b778
movq %rbx, %rdi
movl %r14d, %esi
xorl %edx, %edx
callq 0x11790
movsd %xmm0, (%r13,%rbp,8)
incq %rbp
cmpq %rbp, %r15
jne 0x3b64a
movl 0x4(%rsp), %eax
decl %eax
cmpl $0x4, %eax
jae 0x3b74e
movl %eax, %eax
leaq 0x1a6fb(%rip), %rcx     # 0x55d90
jmp 0x3b723
movq %rbx, %rdi
movl $0x5, %esi
callq 0x3ba44
movl %eax, %ebp
cltd
idivl %r12d
testl %edx, %edx
jne 0x3b759
movl %eax, 0x4(%rsp)
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
movslq %ebp, %rsi
shlq $0x2, %rsi
movq %rbx, %rdi
callq 0x11200
movq %rax, %r13
testl %ebp, %ebp
jle 0x3b70f
movl %ebp, %r15d
xorl %ebp, %ebp
leaq 0x5(%rbp), %r14
movq %rbx, %rdi
movl %r14d, %esi
callq 0x115c0
testl %eax, %eax
je 0x3b792
movq %rbx, %rdi
movl %r14d, %esi
xorl %edx, %edx
callq 0x11040
movl %eax, (%r13,%rbp,4)
incq %rbp
cmpq %rbp, %r15
jne 0x3b6de
movl 0x4(%rsp), %eax
decl %eax
cmpl $0x4, %eax
jae 0x3b74e
movl %eax, %eax
leaq 0x1a62d(%rip), %rcx     # 0x55d50
movq (%rcx,%rax,8), %rax
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rsi
movl %r12d, %edx
movq %r13, %rcx
callq *(%rax)
movq %rbx, %rdi
movq %r13, %rsi
callq 0x11370
movq %rbx, %rdi
callq 0x11880
jmp 0x3b7c1
movq %rbx, %rdi
movq %r13, %rsi
callq 0x11370
leaq 0x3e1e(%rip), %rsi      # 0x3f57e
movq %rbx, %rdi
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x11ae0
movq %rbx, %rdi
movq %r13, %rsi
callq 0x11370
addl $0x5, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x11a80
jmp 0x3b7c1
movq %rbx, %rdi
movq %r13, %rsi
callq 0x11370
addl $0x5, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x11af0
jmp 0x3b7c1
movq %r13, %rsi
callq 0x11370
addl $0x5, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x11510
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq