LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: stetre[P]moonvulkan/src/display_mode.c
// Function: GetDisplayPlaneCapabilities1
static int GetDisplayPlaneCapabilities1(lua_State *L, VkDisplayModeKHR display_mode, ud_t *ud)
    {
    int err;
    VkResult ec;
    VkDisplayPlaneCapabilitiesKHR* capabilities;
    VkPhysicalDevice physical_device = (VkPhysicalDevice)(uintptr_t)ud->parent_ud->parent_ud->handle;
    uint32_t planeIndex = luaL_checkinteger(L, 2);
#define CLEANUP zfreeVkDisplayPlaneCapabilitiesKHR(L, capabilities, 1)
    capabilities = znewVkDisplayPlaneCapabilitiesKHR(L, &err);
    if(err) { CLEANUP; return lua_error(L); }
    ec = ud->idt->GetDisplayPlaneCapabilitiesKHR(physical_device, display_mode, planeIndex, capabilities);
    if(ec) { CLEANUP; CheckError(L, ec); }
    zpushVkDisplayPlaneCapabilitiesKHR(L, capabilities);
    CLEANUP;
#undef CLEANUP
    return 1;
    }

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq %rdx, 0x28(%rsp)
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq (%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x38(%rsp), %rdi
movl $0x2, %esi
callq 0x19190
movl %eax, 0xc(%rsp)
movq 0x38(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0x44, %edx
leaq 0x24(%rsp), %rcx
callq 0x19ee0
movq %rax, 0x18(%rsp)
cmpl $0x0, 0x24(%rsp)
je 0x2ef6b
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl $0x1, %edx
xorl %eax, %eax
movl %eax, %ecx
callq 0x19710
movq 0x38(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x44(%rsp)
jmp 0x2f00d
movq 0x28(%rsp), %rax
movq 0x48(%rax), %rax
movq 0xc0(%rax), %rax
movq 0x10(%rsp), %rdi
movq 0x30(%rsp), %rsi
movl 0xc(%rsp), %edx
movq 0x18(%rsp), %rcx
callq *%rax
movl %eax, 0x20(%rsp)
cmpl $0x0, 0x20(%rsp)
je 0x2efde
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl $0x1, %edx
xorl %eax, %eax
movl %eax, %ecx
callq 0x19710
cmpl $0x0, 0x20(%rsp)
je 0x2efda
movq 0x38(%rsp), %rdi
movl 0x20(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x38(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x44(%rsp)
jmp 0x2f00d
jmp 0x2efdc
jmp 0x2efde
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x1a2a0
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl $0x1, %edx
xorl %eax, %eax
movl %eax, %ecx
callq 0x19710
movl $0x1, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: enums_free
static void enums_free(lua_State *L, rec_t* rec)
    {
    if(code_search(rec->domain, rec->code) == rec)
        code_remove(rec);
    if(str_search(rec->domain, rec->str) == rec)
        str_remove(rec);
    Free(L, rec->str);
    Free(L, rec);   
    }

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x8(%rsp), %rax
movl 0x40(%rax), %edi
movq 0x8(%rsp), %rax
movl 0x44(%rax), %esi
callq 0x2f320
cmpq 0x8(%rsp), %rax
jne 0x2f0c4
movq 0x8(%rsp), %rdi
callq 0x3c8e0
movq 0x8(%rsp), %rax
movl 0x40(%rax), %edi
movq 0x8(%rsp), %rax
movq 0x48(%rax), %rsi
callq 0x2f1c0
cmpq 0x8(%rsp), %rax
jne 0x2f0eb
movq 0x8(%rsp), %rdi
callq 0x3c900
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rax
movq 0x48(%rax), %rsi
callq 0x18300
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rsi
callq 0x18300
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: moonvulkan_enums_test
uint32_t enums_test(lua_State *L, uint32_t domain, int arg, int *err)
    {
    rec_t *rec;
    const char *s = luaL_optstring(L, arg, NULL);

    if(!s)
        { *err = ERR_NOTPRESENT; return 0; }

    rec = str_search(domain, s);
    if(!rec)
        { *err = ERR_VALUE; return 0; }
    
    *err = ERR_SUCCESS;
    return rec->code;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl %edx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
xorl %eax, %eax
movl %eax, %ecx
movq %rcx, %rdx
callq 0x18900
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
jne 0x2f16d
movq 0x18(%rsp), %rax
movl $0x1, (%rax)
movl $0x0, 0x34(%rsp)
jmp 0x2f1b4
movl 0x24(%rsp), %edi
movq 0x8(%rsp), %rsi
callq 0x2f1c0
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x2f19d
movq 0x18(%rsp), %rax
movl $0xfffffffd, (%rax)     # imm = 0xFFFFFFFD
movl $0x0, 0x34(%rsp)
jmp 0x2f1b4
movq 0x18(%rsp), %rax
movl $0x0, (%rax)
movq 0x10(%rsp), %rax
movl 0x44(%rax), %eax
movl %eax, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopl (%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: moonvulkan_enums_check
uint32_t enums_check(lua_State *L, uint32_t domain, int arg)
    {
    rec_t *rec;
    const char *s = luaL_checkstring(L, arg);

    rec = str_search(domain, s);
    if(!rec)
        return luaL_argerror(L, arg, badvalue(L, s));
    
    return rec->code;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl %edx, 0x20(%rsp)
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
xorl %eax, %eax
movl %eax, %edx
callq 0x18df0
movq %rax, 0x10(%rsp)
movl 0x24(%rsp), %edi
movq 0x10(%rsp), %rsi
callq 0x2f1c0
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
jne 0x2f282
movq 0x28(%rsp), %rax
movq %rax, (%rsp)
movl 0x20(%rsp), %eax
movl %eax, 0xc(%rsp)
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rdx
leaq 0xa276b(%rip), %rsi     # 0xd19d0
movb $0x0, %al
callq 0x18f50
movq (%rsp), %rdi
movl 0xc(%rsp), %esi
movq %rax, %rdx
callq 0x18460
movl %eax, 0x34(%rsp)
jmp 0x2f28e
movq 0x18(%rsp), %rax
movl 0x44(%rax), %eax
movl %eax, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw (%rax,%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: moonvulkan_enums_push
int enums_push(lua_State *L, uint32_t domain, uint32_t code)
    {
    rec_t *rec = code_search(domain, code);

    if(!rec)
        return unexpected(L);

    lua_pushstring(L, rec->str);
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movl %esi, 0x14(%rsp)
movl %edx, 0x10(%rsp)
movl 0x14(%rsp), %edi
movl 0x10(%rsp), %esi
callq 0x2f320
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
jne 0x2f2f0
movq 0x18(%rsp), %rdi
leaq 0xa12b0(%rip), %rsi     # 0xd0587
leaq 0xa2705(%rip), %rdx     # 0xd19e3
movl $0xca, %ecx
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x24(%rsp)
jmp 0x2f30b
movq 0x18(%rsp), %rdi
movq 0x8(%rsp), %rax
movq 0x48(%rax), %rsi
callq 0x1a420
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: moonvulkan_enums_values
int enums_values(lua_State *L, uint32_t domain)
    {
    int i;
    rec_t *rec;

    lua_newtable(L);
    i = 1;
    rec = code_first(domain, 0);
    while(rec)
        {
        if(rec->domain == domain)
            {
            lua_pushstring(L, rec->str);
            lua_rawseti(L, -2, i++);
            }
        rec = code_next(rec);
        }

    return 1;
    }

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x18830
movl $0x1, 0x8(%rsp)
movl 0xc(%rsp), %edi
xorl %esi, %esi
callq 0x2f060
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
je 0x2f3d6
movq (%rsp), %rax
movl 0x40(%rax), %eax
cmpl 0xc(%rsp), %eax
jne 0x2f3c7
movq 0x10(%rsp), %rdi
movq (%rsp), %rax
movq 0x48(%rax), %rsi
callq 0x1a420
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %eax
movl %eax, %ecx
addl $0x1, %ecx
movl %ecx, 0x8(%rsp)
movslq %eax, %rdx
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x191e0
movq (%rsp), %rdi
callq 0x2f3e0
movq %rax, (%rsp)
jmp 0x2f382
movl $0x1, %eax
addq $0x18, %rsp
retq
// File: stetre[P]moonvulkan/src/enums.c
// Function: moonvulkan_enums_checklist
uint32_t* enums_checklist(lua_State *L, uint32_t domain, int arg, uint32_t *count, int *err)
    {
    uint32_t* list;
    uint32_t i;

    *count = 0;
    *err = 0;
    if(lua_isnoneornil(L, arg))
        { *err = ERR_NOTPRESENT; return NULL; }
    if(lua_type(L, arg) != LUA_TTABLE)
        { *err = ERR_TABLE; return NULL; }

    *count = luaL_len(L, arg);
    if(*count == 0)
        { *err = ERR_NOTPRESENT; return NULL; }

    list = (uint32_t*)MallocNoErr(L, sizeof(uint32_t) * (*count));
    if(!list)
        { *count = 0; *err = ERR_MEMORY; return NULL; }

    for(i=0; i<*count; i++)
        {
        lua_rawgeti(L, arg, i+1);
        list[i] = enums_test(L, domain, -1, err);
        lua_pop(L, 1);
        if(*err)
            { Free(L, list); *count = 0; return NULL; }
        }
    return list;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl %edx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq %r8, 0x10(%rsp)
movq 0x18(%rsp), %rax
movl $0x0, (%rax)
movq 0x10(%rsp), %rax
movl $0x0, (%rax)
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
callq 0x1a240
cmpl $0x0, %eax
jg 0x2f44d
movq 0x10(%rsp), %rax
movl $0x1, (%rax)
movq $0x0, 0x30(%rsp)
jmp 0x2f5ad
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
callq 0x1a240
cmpl $0x5, %eax
je 0x2f479
movq 0x10(%rsp), %rax
movl $0xfffffffc, (%rax)     # imm = 0xFFFFFFFC
movq $0x0, 0x30(%rsp)
jmp 0x2f5ad
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
callq 0x1a270
movl %eax, %ecx
movq 0x18(%rsp), %rax
movl %ecx, (%rax)
movq 0x18(%rsp), %rax
cmpl $0x0, (%rax)
jne 0x2f4b3
movq 0x10(%rsp), %rax
movl $0x1, (%rax)
movq $0x0, 0x30(%rsp)
jmp 0x2f5ad
movq 0x28(%rsp), %rdi
movq 0x18(%rsp), %rax
movl (%rax), %eax
movl %eax, %esi
shlq $0x2, %rsi
callq 0x18050
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
jne 0x2f4fb
movq 0x18(%rsp), %rax
movl $0x0, (%rax)
movq 0x10(%rsp), %rax
movl $0xfffffffa, (%rax)     # imm = 0xFFFFFFFA
movq $0x0, 0x30(%rsp)
jmp 0x2f5ad
movl $0x0, 0x4(%rsp)
movl 0x4(%rsp), %eax
movq 0x18(%rsp), %rcx
cmpl (%rcx), %eax
jae 0x2f5a3
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, %eax
movl %eax, %edx
callq 0x189e0
movq 0x28(%rsp), %rdi
movl 0x24(%rsp), %esi
movq 0x10(%rsp), %rcx
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x18ba0
movl %eax, %edx
movq 0x8(%rsp), %rax
movl 0x4(%rsp), %ecx
movl %edx, (%rax,%rcx,4)
movq 0x28(%rsp), %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x18170
movq 0x10(%rsp), %rax
cmpl $0x0, (%rax)
je 0x2f591
movq 0x28(%rsp), %rdi
movq 0x8(%rsp), %rsi
callq 0x18300
movq 0x18(%rsp), %rax
movl $0x0, (%rax)
movq $0x0, 0x30(%rsp)
jmp 0x2f5ad
jmp 0x2f593
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4(%rsp)
jmp 0x2f503
movq 0x8(%rsp), %rax
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nopw (%rax,%rax)
// File: stetre[P]moonvulkan/src/enums.c
// Function: enums_new
static int enums_new(lua_State *L, uint32_t domain, uint32_t code, const char *str)
    {
    rec_t *rec;
    if((rec = (rec_t*)Malloc(L, sizeof(rec_t))) == NULL) return errmemory(L);

    memset(rec, 0, sizeof(rec_t));
    rec->domain = domain;
    rec->code = code;
    rec->str = Strdup(L, str);
    if(code_search(domain, code) || str_search(domain, str))
        { 
        Free(L, rec->str);
        Free(L, rec); 
        printf("enum domain:%u value:'%s'(%u)\n", domain, str, code);
        return unexpected(L); /* duplicate value */
        }
    code_insert(rec);
    str_insert(rec);
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl %edx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq 0x28(%rsp), %rdi
movl $0x50, %esi
callq 0x192c0
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
jne 0x3c69c
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0xfffffffa, %edi       # imm = 0xFFFFFFFA
callq 0x19a60
movq 0x8(%rsp), %rdi
movq %rax, %rsi
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x34(%rsp)
jmp 0x3c785
movq 0x10(%rsp), %rdi
xorl %esi, %esi
movl $0x50, %edx
callq 0x18bd0
movl 0x24(%rsp), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x40(%rax)
movl 0x20(%rsp), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x44(%rax)
movq 0x28(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x19120
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x48(%rax)
movl 0x24(%rsp), %edi
movl 0x20(%rsp), %esi
callq 0x2f320
cmpq $0x0, %rax
jne 0x3c707
movl 0x24(%rsp), %edi
movq 0x18(%rsp), %rsi
callq 0x2f1c0
cmpq $0x0, %rax
je 0x3c769
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rax
movq 0x48(%rax), %rsi
callq 0x18300
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x18300
movl 0x24(%rsp), %esi
movq 0x18(%rsp), %rdx
movl 0x20(%rsp), %ecx
leaq 0x9d366(%rip), %rdi     # 0xd9aa3
movb $0x0, %al
callq 0x189d0
movq 0x28(%rsp), %rdi
leaq 0x93e37(%rip), %rsi     # 0xd0587
leaq 0x9528c(%rip), %rdx     # 0xd19e3
movl $0x7c, %ecx
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x34(%rsp)
jmp 0x3c785
movq 0x10(%rsp), %rdi
callq 0x3ee40
movq 0x10(%rsp), %rdi
callq 0x3ee60
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nop
// File: stetre[P]moonvulkan/src/event.c
// Function: GetEventStatus
static int GetEventStatus(lua_State *L)
    {
    ud_t *ud;
    VkEvent event = checkevent(L, 1, &ud);
    VkDevice device = ud->device;
    VkResult ec = ud->ddt->GetEventStatus(device, event);
    switch(ec)
        {
        case VK_EVENT_SET: lua_pushboolean(L, 1); return 1;
        case VK_EVENT_RESET: lua_pushboolean(L, 0); return 1;
        default:
            CheckError(L, ec);
        }
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rdi
leaq 0x8f9e6(%rip), %rcx     # 0xcf9ab
movl $0x1, %esi
leaq 0x20(%rsp), %rdx
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
movq 0xd8(%rax), %rax
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq *%rax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %eax
movl %eax, 0x8(%rsp)
subl $0x3, %eax
je 0x40021
jmp 0x40016
movl 0x8(%rsp), %eax
subl $0x4, %eax
je 0x4003a
jmp 0x40050
movq 0x28(%rsp), %rdi
movl $0x1, %esi
callq 0x19480
movl $0x1, 0x34(%rsp)
jmp 0x40085
movq 0x28(%rsp), %rdi
xorl %esi, %esi
callq 0x19480
movl $0x1, 0x34(%rsp)
jmp 0x40085
jmp 0x40052
cmpl $0x0, 0xc(%rsp)
je 0x40079
movq 0x28(%rsp), %rdi
movl 0xc(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x28(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x34(%rsp)
jmp 0x40085
jmp 0x4007b
jmp 0x4007d
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nop
// File: stetre[P]moonvulkan/src/event.c
// Function: SetEvent_damnwindows
static int SetEvent_damnwindows (lua_State *L)
    {
    ud_t *ud;
    VkEvent event = checkevent(L, 1, &ud);
    VkDevice device = ud->device;
    VkResult ec = ud->ddt->SetEvent(device, event);
    CheckError(L, ec);
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movl $0x1, %esi
leaq 0x20(%rsp), %rdx
leaq 0x8f8fc(%rip), %rcx     # 0xcf9ab
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
movq 0xe0(%rax), %rax
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq *%rax
movl %eax, 0xc(%rsp)
cmpl $0x0, 0xc(%rsp)
je 0x4010e
movq 0x28(%rsp), %rdi
movl 0xc(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x28(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x34(%rsp)
jmp 0x40118
jmp 0x40110
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/event.c
// Function: ResetEvent_damnwindows
static int ResetEvent_damnwindows (lua_State *L)
    {
    ud_t *ud;
    VkEvent event = checkevent(L, 1, &ud);
    VkDevice device = ud->device;
    VkResult ec = ud->ddt->ResetEvent(device, event);
    CheckError(L, ec);
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movl $0x1, %esi
leaq 0x20(%rsp), %rdx
leaq 0x8f85c(%rip), %rcx     # 0xcf9ab
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
movq 0xe8(%rax), %rax
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq *%rax
movl %eax, 0xc(%rsp)
cmpl $0x0, 0xc(%rsp)
je 0x401ae
movq 0x28(%rsp), %rdi
movl 0xc(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x28(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x34(%rsp)
jmp 0x401b8
jmp 0x401b0
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/event.c
// Function: freeevent
static int freeevent(lua_State *L, ud_t *ud)
    {
    VkEvent event = (VkEvent)ud->handle;
    const VkAllocationCallbacks *allocator = ud->allocator;
    VkDevice device = ud->device;
    if(!freeuserdata(L, ud))
        return 0; /* double call */
    TRACE_DELETE(event, "event");
    UD(device)->ddt->DestroyEvent(device, event, allocator);
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x40(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x28(%rsp), %rdi
movq 0x20(%rsp), %rsi
callq 0x18dc0
cmpl $0x0, %eax
jne 0x40225
movl $0x0, 0x34(%rsp)
jmp 0x40276
jmp 0x40227
movq 0xbcd6a(%rip), %rax     # 0xfcf98
cmpl $0x0, (%rax)
je 0x40246
movq 0x18(%rsp), %rsi
leaq 0x998c6(%rip), %rdi     # 0xd9b05
movb $0x0, %al
callq 0x189d0
jmp 0x40248
movq 0x8(%rsp), %rdi
callq 0x19fd0
movq 0x50(%rax), %rax
movq 0xd0(%rax), %rax
movq 0x8(%rsp), %rdi
movq 0x18(%rsp), %rsi
movq 0x10(%rsp), %rdx
callq *%rax
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nop
// File: stetre[P]moonvulkan/src/fence.c
// Function: Create
static int Create(lua_State *L)
    {
    int err;
    ud_t *device_ud;
    VkResult ec;
    VkFence fence;
    VkFenceCreateInfo* info;
    VkDevice device = checkdevice(L, 1, &device_ud);
    const VkAllocationCallbacks *allocator = NULL;
#define CLEANUP zfreeVkFenceCreateInfo(L, info, 1)
    if(lua_istable(L, 2))
        {
        info = zcheckVkFenceCreateInfo(L, 2, &err);
        if(err) { CLEANUP; return argerror(L, 2); }
        allocator = optallocator(L, 3);
        }
    else
        {
        info = znewVkFenceCreateInfo(L, &err);
        if(err) { CLEANUP; return lua_error(L); }
        info->flags = optflags(L, 2, 0);
        }
    ec = device_ud->ddt->CreateFence(device, info, allocator, &fence);
    CLEANUP;
    CheckError(L, ec);
#undef CLEANUP
    return Created(L, fence, device, allocator);
    }

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
movq 0x48(%rsp), %rdi
movl $0x1, %esi
leaq 0x38(%rsp), %rdx
leaq 0x8eb6c(%rip), %rcx     # 0xcf03b
callq 0x1a640
movq %rax, 0x18(%rsp)
movq $0x0, 0x10(%rsp)
movq 0x48(%rsp), %rdi
movl $0x2, %esi
callq 0x1a240
cmpl $0x5, %eax
jne 0x4057c
movq 0x48(%rsp), %rdi
movl $0x2, %esi
leaq 0x44(%rsp), %rdx
callq 0x1a380
movq %rax, 0x20(%rsp)
cmpl $0x0, 0x44(%rsp)
je 0x40566
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x48(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x48(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movl %eax, %edx
callq 0x186d0
movq 0x8(%rsp), %rdi
movq %rax, %rdx
movl $0x2, %esi
callq 0x18460
movl %eax, 0x54(%rsp)
jmp 0x40669
movq 0x48(%rsp), %rdi
movl $0x3, %esi
callq 0x19260
movq %rax, 0x10(%rsp)
jmp 0x405e5
movq 0x48(%rsp), %rdi
movl $0x8, %esi
movl $0x18, %edx
leaq 0x44(%rsp), %rcx
callq 0x19ee0
movq %rax, 0x20(%rsp)
cmpl $0x0, 0x44(%rsp)
je 0x405c8
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x48(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x54(%rsp)
jmp 0x40669
movq 0x48(%rsp), %rdi
movl $0x2, %esi
xorl %eax, %eax
movl %eax, %edx
callq 0x19370
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x10(%rax)
movq 0x38(%rsp), %rax
movq 0x50(%rax), %rax
movq 0x90(%rax), %rax
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x28(%rsp), %rcx
callq *%rax
movl %eax, 0x34(%rsp)
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
cmpl $0x0, 0x34(%rsp)
je 0x4064a
movq 0x48(%rsp), %rdi
movl 0x34(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x48(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x54(%rsp)
jmp 0x40669
jmp 0x4064c
movq 0x48(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq 0x10(%rsp), %rcx
callq 0x40fc0
movl %eax, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: RegisterDeviceEvent
static int RegisterDeviceEvent(lua_State *L)
    {
    int err;
    ud_t *device_ud;
    VkResult ec;
    VkFence fence;
    VkDeviceEventInfoEXT* info;
    VkDevice device = checkdevice(L, 1, &device_ud);
    const VkAllocationCallbacks *allocator = optallocator(L, 3);
    CheckDevicePfn(L, device_ud, RegisterDeviceEventEXT);
#define CLEANUP zfreeVkDeviceEventInfoEXT(L, info, 1)
    info = zcheckVkDeviceEventInfoEXT(L, 2, &err);
    if(err) { CLEANUP; return argerror(L, 2); }
    ec = device_ud->ddt->RegisterDeviceEventEXT(device, info, allocator, &fence);
    CLEANUP;
    CheckError(L, ec);
#undef CLEANUP
    return Created(L, fence, device, allocator);
    }

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
movq 0x48(%rsp), %rdi
movl $0x1, %esi
leaq 0x38(%rsp), %rdx
leaq 0x8e99c(%rip), %rcx     # 0xcf03b
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x48(%rsp), %rdi
movl $0x3, %esi
callq 0x19260
movq %rax, 0x10(%rsp)
movq 0x38(%rsp), %rax
movq 0x50(%rax), %rax
cmpq $0x0, 0x2a0(%rax)
jne 0x406ec
movq 0x48(%rsp), %rdi
leaq 0x99501(%rip), %rsi     # 0xd9bdd
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x54(%rsp)
jmp 0x407de
jmp 0x406ee
movq 0x48(%rsp), %rdi
movl $0x2, %esi
leaq 0x44(%rsp), %rdx
callq 0x19c90
movq %rax, 0x20(%rsp)
cmpl $0x0, 0x44(%rsp)
je 0x4075a
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x48(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x48(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movl %eax, %edx
callq 0x186d0
movq 0x8(%rsp), %rdi
movq %rax, %rdx
movl $0x2, %esi
callq 0x18460
movl %eax, 0x54(%rsp)
jmp 0x407de
movq 0x38(%rsp), %rax
movq 0x50(%rax), %rax
movq 0x2a0(%rax), %rax
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x28(%rsp), %rcx
callq *%rax
movl %eax, 0x34(%rsp)
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
cmpl $0x0, 0x34(%rsp)
je 0x407bf
movq 0x48(%rsp), %rdi
movl 0x34(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x48(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x54(%rsp)
jmp 0x407de
jmp 0x407c1
movq 0x48(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq 0x10(%rsp), %rcx
callq 0x40fc0
movl %eax, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopw (%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: RegisterDisplayEvent
static int RegisterDisplayEvent(lua_State *L)
    {
    int err;
    ud_t *device_ud;
    VkResult ec;
    VkFence fence;
    VkDisplayEventInfoEXT* info;
    VkDevice device = checkdevice(L, 1, &device_ud);
    VkDisplayKHR display = checkdisplay(L, 2, NULL);
    const VkAllocationCallbacks *allocator = optallocator(L, 4);
    CheckDevicePfn(L, device_ud, RegisterDisplayEventEXT);
#define CLEANUP zfreeVkDisplayEventInfoEXT(L, info, 1)
    info = zcheckVkDisplayEventInfoEXT(L, 3, &err);
    if(err) { CLEANUP; return argerror(L, 3); }
    ec = device_ud->ddt->RegisterDisplayEventEXT(device, display, info, allocator, &fence);
    CLEANUP;
    CheckError(L, ec);
#undef CLEANUP
    return Created(L, fence, device, allocator);
    }

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
movq 0x48(%rsp), %rdi
movl $0x1, %esi
leaq 0x38(%rsp), %rdx
leaq 0x8e82c(%rip), %rcx     # 0xcf03b
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x48(%rsp), %rdi
movl $0x2, %esi
xorl %eax, %eax
movl %eax, %edx
leaq 0x90dd8(%rip), %rcx     # 0xd1606
callq 0x1a640
movq %rax, 0x10(%rsp)
movq 0x48(%rsp), %rdi
movl $0x4, %esi
callq 0x19260
movq %rax, 0x8(%rsp)
movq 0x38(%rsp), %rax
movq 0x50(%rax), %rax
cmpq $0x0, 0x2a8(%rax)
jne 0x4087b
movq 0x48(%rsp), %rdi
leaq 0x9939e(%rip), %rsi     # 0xd9c09
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x54(%rsp)
jmp 0x40970
jmp 0x4087d
movq 0x48(%rsp), %rdi
movl $0x3, %esi
leaq 0x44(%rsp), %rdx
callq 0x1a0f0
movq %rax, 0x20(%rsp)
cmpl $0x0, 0x44(%rsp)
je 0x408e7
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x48(%rsp), %rax
movq %rax, (%rsp)
movq 0x48(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movl %eax, %edx
callq 0x186d0
movq (%rsp), %rdi
movq %rax, %rdx
movl $0x3, %esi
callq 0x18460
movl %eax, 0x54(%rsp)
jmp 0x40970
movq 0x38(%rsp), %rax
movq 0x50(%rax), %rax
movq 0x2a8(%rax), %rax
movq 0x18(%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x20(%rsp), %rdx
movq 0x8(%rsp), %rcx
leaq 0x28(%rsp), %r8
callq *%rax
movl %eax, 0x34(%rsp)
movq 0x48(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
cmpl $0x0, 0x34(%rsp)
je 0x40951
movq 0x48(%rsp), %rdi
movl 0x34(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x48(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x54(%rsp)
jmp 0x40970
jmp 0x40953
movq 0x48(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq 0x8(%rsp), %rcx
callq 0x40fc0
movl %eax, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopl (%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: ResetFences
static int ResetFences(lua_State *L)
    {
    ud_t **ud;
    int err;
    uint32_t count;
    VkResult ec;
    VkDevice device;
    VkFence *fences = checkfencelist(L, 1, &count, &err, &ud);
    if(err) return argerrorc(L, 1, err);
    device = ud[0]->device;
    ec = UD(device)->ddt->ResetFences(device, count, fences);
    Free(L, fences);
    Free(L, ud);
    CheckError(L, ec);
    return 0;
    }

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq 0x38(%rsp), %rdi
movl $0x1, %esi
leaq 0x28(%rsp), %rdx
leaq 0x2c(%rsp), %rcx
leaq 0x30(%rsp), %r8
leaq 0x9057a(%rip), %r9      # 0xd0f63
callq 0x191f0
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x2c(%rsp)
je 0x40a28
movq 0x38(%rsp), %rax
movq %rax, 0x8(%rsp)
movl 0x2c(%rsp), %edi
callq 0x19a60
movq 0x8(%rsp), %rdi
movq %rax, %rdx
movl $0x1, %esi
callq 0x18460
movl %eax, 0x44(%rsp)
jmp 0x40ab1
movq 0x30(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
callq 0x19fd0
movq 0x50(%rax), %rax
movq 0xa0(%rax), %rax
movq 0x18(%rsp), %rdi
movl 0x28(%rsp), %esi
movq 0x10(%rsp), %rdx
callq *%rax
movl %eax, 0x24(%rsp)
movq 0x38(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x18300
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x18300
cmpl $0x0, 0x24(%rsp)
je 0x40aa7
movq 0x38(%rsp), %rdi
movl 0x24(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x38(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x44(%rsp)
jmp 0x40ab1
jmp 0x40aa9
movl $0x0, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw (%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: GetFenceStatus
static int GetFenceStatus(lua_State *L)
    {
    ud_t *ud;
    VkFence fence = checkfence(L, 1, &ud);
    VkDevice device = ud->device;
    VkResult ec = ud->ddt->GetFenceStatus(device, fence);
    switch(ec)
        {
        case VK_SUCCESS: lua_pushboolean(L, 1); return 1;
        case VK_NOT_READY: lua_pushboolean(L, 0); return 1;
        default:
            CheckError(L, ec);
        }
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rdi
leaq 0x9048e(%rip), %rcx     # 0xd0f63
movl $0x1, %esi
leaq 0x20(%rsp), %rdx
callq 0x1a640
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
movq 0xa8(%rax), %rax
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq *%rax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %eax
movl %eax, 0x8(%rsp)
testl %eax, %eax
je 0x40b30
jmp 0x40b25
movl 0x8(%rsp), %eax
subl $0x1, %eax
je 0x40b49
jmp 0x40b5f
movq 0x28(%rsp), %rdi
movl $0x1, %esi
callq 0x19480
movl $0x1, 0x34(%rsp)
jmp 0x40b94
movq 0x28(%rsp), %rdi
xorl %esi, %esi
callq 0x19480
movl $0x1, 0x34(%rsp)
jmp 0x40b94
jmp 0x40b61
cmpl $0x0, 0xc(%rsp)
je 0x40b88
movq 0x28(%rsp), %rdi
movl 0xc(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x28(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x34(%rsp)
jmp 0x40b94
jmp 0x40b8a
jmp 0x40b8c
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopl (%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: WaitForFences
static int WaitForFences(lua_State *L)
    {
    ud_t **ud;
    int err;
    uint32_t count;
    VkResult ec;
    VkBool32 waitall = checkboolean(L, 2);
    uint64_t timeout = checktimeout(L, 3);
    VkFence *fences = checkfencelist(L, 1, &count, &err, &ud);
    if(err) return argerrorc(L, 1, err);
    ec = ud[0]->ddt->WaitForFences(ud[0]->device, count, fences, waitall, timeout);
    Free(L, fences);
    Free(L, ud);
    switch(ec)
        {
        case VK_SUCCESS: lua_pushboolean(L, 1); return 1;
        case VK_TIMEOUT: lua_pushboolean(L, 0); return 1;
        default:
            CheckError(L, ec);
        }
    return 0;
    }

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq 0x38(%rsp), %rdi
movl $0x2, %esi
callq 0x187f0
movl %eax, 0x20(%rsp)
movq 0x38(%rsp), %rdi
movl $0x3, %esi
callq 0x19ca0
movq %rax, 0x18(%rsp)
movq 0x38(%rsp), %rdi
movl $0x1, %esi
leaq 0x28(%rsp), %rdx
leaq 0x2c(%rsp), %rcx
leaq 0x30(%rsp), %r8
leaq 0x90373(%rip), %r9      # 0xd0f63
callq 0x191f0
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x2c(%rsp)
je 0x40c2f
movq 0x38(%rsp), %rax
movq %rax, 0x8(%rsp)
movl 0x2c(%rsp), %edi
callq 0x19a60
movq 0x8(%rsp), %rdi
movq %rax, %rdx
movl $0x1, %esi
callq 0x18460
movl %eax, 0x44(%rsp)
jmp 0x40cf9
movq 0x30(%rsp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rdi
movq 0x50(%rax), %rax
movq 0xb0(%rax), %rax
movl 0x28(%rsp), %esi
movq 0x10(%rsp), %rdx
movl 0x20(%rsp), %ecx
movq 0x18(%rsp), %r8
callq *%rax
movl %eax, 0x24(%rsp)
movq 0x38(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x18300
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x18300
movl 0x24(%rsp), %eax
movl %eax, 0x4(%rsp)
testl %eax, %eax
je 0x40c95
jmp 0x40c8a
movl 0x4(%rsp), %eax
subl $0x2, %eax
je 0x40cae
jmp 0x40cc4
movq 0x38(%rsp), %rdi
movl $0x1, %esi
callq 0x19480
movl $0x1, 0x44(%rsp)
jmp 0x40cf9
movq 0x38(%rsp), %rdi
xorl %esi, %esi
callq 0x19480
movl $0x1, 0x44(%rsp)
jmp 0x40cf9
jmp 0x40cc6
cmpl $0x0, 0x24(%rsp)
je 0x40ced
movq 0x38(%rsp), %rdi
movl 0x24(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x38(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x44(%rsp)
jmp 0x40cf9
jmp 0x40cef
jmp 0x40cf1
movl $0x0, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: ImportFenceFd
static int ImportFenceFd(lua_State *L)
    {
    int err;
    VkResult ec;
    ud_t *ud;
    VkImportFenceFdInfoKHR* info;
    VkFence fence = checkfence(L, 1, &ud);
    CheckDevicePfn(L, ud, ImportFenceFdKHR);
#define CLEANUP zfreeVkImportFenceFdInfoKHR(L, info, 1)
    info = zcheckVkImportFenceFdInfoKHR(L, 2, &err);
    if(err) { CLEANUP; return argerror(L, 2); }
    info->fence = fence;
    ec = ud->ddt->ImportFenceFdKHR(ud->device, info);
    CLEANUP;
    CheckError(L, ec);
#undef CLEANUP
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movl $0x1, %esi
leaq 0x18(%rsp), %rdx
leaq 0x90234(%rip), %rcx     # 0xd0f63
callq 0x1a640
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rax
movq 0x50(%rax), %rax
cmpq $0x0, 0x498(%rax)
jne 0x40d68
movq 0x28(%rsp), %rdi
leaq 0x98ede(%rip), %rsi     # 0xd9c36
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x34(%rsp)
jmp 0x40e48
jmp 0x40d6a
movq 0x28(%rsp), %rdi
movl $0x2, %esi
leaq 0x24(%rsp), %rdx
callq 0x19dc0
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x24(%rsp)
je 0x40dd1
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x28(%rsp), %rax
movq %rax, (%rsp)
movq 0x28(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movl %eax, %edx
callq 0x186d0
movq (%rsp), %rdi
movq %rax, %rdx
movl $0x2, %esi
callq 0x18460
movl %eax, 0x34(%rsp)
jmp 0x40e48
movq 0x8(%rsp), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0x18(%rsp), %rax
movq 0x50(%rax), %rax
movq 0x498(%rax), %rax
movq 0x18(%rsp), %rcx
movq 0x20(%rcx), %rdi
movq 0x10(%rsp), %rsi
callq *%rax
movl %eax, 0x20(%rsp)
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
cmpl $0x0, 0x20(%rsp)
je 0x40e3e
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x28(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x34(%rsp)
jmp 0x40e48
jmp 0x40e40
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: GetFenceFd
static int GetFenceFd(lua_State *L)
    {
    int err, fd;
    VkResult ec;
    ud_t *ud;
    VkFenceGetFdInfoKHR* info;
    VkFence fence = checkfence(L, 1, &ud);
    CheckDevicePfn(L, ud, GetFenceFdKHR);
#define CLEANUP zfreeVkFenceGetFdInfoKHR(L, info, 1)
    info = zcheckVkFenceGetFdInfoKHR(L, 2, &err);
    if(err) { CLEANUP; return argerror(L, 2); }
    info->fence = fence;
    ec = ud->ddt->GetFenceFdKHR(ud->device, info, &fd);
    CLEANUP;
    CheckError(L, ec);
#undef CLEANUP
    lua_pushinteger(L, fd);
    return 1;
    }

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq 0x38(%rsp), %rdi
movl $0x1, %esi
leaq 0x20(%rsp), %rdx
leaq 0x900e4(%rip), %rcx     # 0xd0f63
callq 0x1a640
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
cmpq $0x0, 0x4a0(%rax)
jne 0x40eb8
movq 0x38(%rsp), %rdi
leaq 0x98db4(%rip), %rsi     # 0xd9c5c
movb $0x0, %al
callq 0x19ce0
movl %eax, 0x44(%rsp)
jmp 0x40fb1
jmp 0x40eba
movq 0x38(%rsp), %rdi
movl $0x2, %esi
leaq 0x34(%rsp), %rdx
callq 0x18240
movq %rax, 0x18(%rsp)
cmpl $0x0, 0x34(%rsp)
je 0x40f26
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
movq 0x38(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x38(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movl %eax, %edx
callq 0x186d0
movq 0x8(%rsp), %rdi
movq %rax, %rdx
movl $0x2, %esi
callq 0x18460
movl %eax, 0x44(%rsp)
jmp 0x40fb1
movq 0x10(%rsp), %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0x20(%rsp), %rax
movq 0x50(%rax), %rax
movq 0x4a0(%rax), %rax
movq 0x20(%rsp), %rcx
movq 0x20(%rcx), %rdi
movq 0x18(%rsp), %rsi
leaq 0x30(%rsp), %rdx
callq *%rax
movl %eax, 0x2c(%rsp)
movq 0x38(%rsp), %rdi
movq 0x18(%rsp), %rsi
movl $0x1, %edx
callq 0x19210
cmpl $0x0, 0x2c(%rsp)
je 0x40f98
movq 0x38(%rsp), %rdi
movl 0x2c(%rsp), %edx
xorl %esi, %esi
callq 0x18a00
movq 0x38(%rsp), %rdi
callq 0x19ad0
movl %eax, 0x44(%rsp)
jmp 0x40fb1
jmp 0x40f9a
movq 0x38(%rsp), %rdi
movslq 0x30(%rsp), %rsi
callq 0x18be0
movl $0x1, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw (%rax,%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: Created
static int Created(lua_State *L, VkFence fence, VkDevice device, const VkAllocationCallbacks *allocator)
    {
    ud_t *ud, *device_ud = UD(device);
    TRACE_CREATE(fence, "fence");
    ud = newuserdata_nondispatchable(L, fence, FENCE_MT);
    ud->parent_ud = device_ud;
    ud->device = device;
    ud->instance = device_ud->instance;
    ud->allocator = allocator;
    ud->destructor = freefence;
    ud->ddt = device_ud->ddt;
    return 1;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq 0x20(%rsp), %rdi
callq 0x19fd0
movq %rax, 0x8(%rsp)
movq 0xbbfaa(%rip), %rax     # 0xfcf98
cmpl $0x0, (%rax)
je 0x41006
movq 0x28(%rsp), %rsi
leaq 0x98bb0(%rip), %rdi     # 0xd9baf
movb $0x0, %al
callq 0x189d0
jmp 0x41008
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
leaq 0x8ff4a(%rip), %rdx     # 0xd0f63
xorl %ecx, %ecx
callq 0x18350
movq %rax, 0x10(%rsp)
movq 0x8(%rsp), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x10(%rax)
movq 0x20(%rsp), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x20(%rax)
movq 0x8(%rsp), %rax
movq 0x18(%rax), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x18(%rsp), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x40(%rax)
movq 0x10(%rsp), %rax
leaq 0x23(%rip), %rcx        # 0x41090
movq %rcx, 0x8(%rax)
movq 0x8(%rsp), %rax
movq 0x50(%rax), %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x50(%rax)
movl $0x1, %eax
addq $0x38, %rsp
retq
nopl (%rax)
// File: stetre[P]moonvulkan/src/fence.c
// Function: freefence
static int freefence(lua_State *L, ud_t *ud)
    {
    VkFence fence = (VkFence)ud->handle;
    const VkAllocationCallbacks *allocator = ud->allocator;
    VkDevice device = ud->device;
    if(!freeuserdata(L, ud))
        return 0; /* double call */
    TRACE_DELETE(fence, "fence");
    UD(device)->ddt->DestroyFence(device, fence, allocator);
    return 0;
    }

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq 0x40(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x20(%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x28(%rsp), %rdi
movq 0x20(%rsp), %rsi
callq 0x18dc0
cmpl $0x0, %eax
jne 0x410e5
movl $0x0, 0x34(%rsp)
jmp 0x41136
jmp 0x410e7
movq 0xbbeaa(%rip), %rax     # 0xfcf98
cmpl $0x0, (%rax)
je 0x41106
movq 0x18(%rsp), %rsi
leaq 0x98ac7(%rip), %rdi     # 0xd9bc6
movb $0x0, %al
callq 0x189d0
jmp 0x41108
movq 0x8(%rsp), %rdi
callq 0x19fd0
movq 0x50(%rax), %rax
movq 0x98(%rax), %rax
movq 0x8(%rsp), %rdi
movq 0x18(%rsp), %rsi
movq 0x10(%rsp), %rdx
callq *%rax
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nop
// File: stetre[P]moonvulkan/src/flags.c
// Function: StencilFaceFlags
static int StencilFaceFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushstencilfaceflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkstencilfaceflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44758
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x46b10
movl %eax, 0x24(%rsp)
jmp 0x44787
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x46bb0
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: CommandBufferResetFlags
static int CommandBufferResetFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcommandbufferresetflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcommandbufferresetflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x447d8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x46cd0
movl %eax, 0x24(%rsp)
jmp 0x44807
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x46d20
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: QueryControlFlags
static int QueryControlFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushquerycontrolflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkquerycontrolflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44858
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x46df0
movl %eax, 0x24(%rsp)
jmp 0x44887
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x46e40
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: CommandBufferUsageFlags
static int CommandBufferUsageFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcommandbufferusageflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcommandbufferusageflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x448d8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x46f10
movl %eax, 0x24(%rsp)
jmp 0x44907
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x46fb0
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: CommandPoolResetFlags
static int CommandPoolResetFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcommandpoolresetflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcommandpoolresetflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44958
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x470d0
movl %eax, 0x24(%rsp)
jmp 0x44987
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x47120
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: CommandPoolCreateFlags
static int CommandPoolCreateFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcommandpoolcreateflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcommandpoolcreateflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x449d8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x471f0
movl %eax, 0x24(%rsp)
jmp 0x44a07
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x47290
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: DependencyFlags
static int DependencyFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushdependencyflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkdependencyflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44a58
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x473b0
movl %eax, 0x24(%rsp)
jmp 0x44a87
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x47450
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: AccessFlags
static int AccessFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushaccessflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkaccessflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44ad9
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x47570
movl %eax, 0x24(%rsp)
jmp 0x44b07
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x47b50
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: AttachmentDescriptionFlags
static int AttachmentDescriptionFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushattachmentdescriptionflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkattachmentdescriptionflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44b58
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x48140
movl %eax, 0x24(%rsp)
jmp 0x44b87
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x48190
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: DescriptorPoolCreateFlags
static int DescriptorPoolCreateFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushdescriptorpoolcreateflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkdescriptorpoolcreateflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44bd8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x48260
movl %eax, 0x24(%rsp)
jmp 0x44c07
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x482b0
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: DescriptorSetLayoutCreateFlags
static int DescriptorSetLayoutCreateFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushdescriptorsetlayoutcreateflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkdescriptorsetlayoutcreateflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44c58
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x483b0
movl %eax, 0x24(%rsp)
jmp 0x44c87
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x48400
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: ColorComponentFlags
static int ColorComponentFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcolorcomponentflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcolorcomponentflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44cd8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x48500
movl %eax, 0x24(%rsp)
jmp 0x44d07
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x485d0
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: CullModeFlags
static int CullModeFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushcullmodeflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkcullmodeflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44d58
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x48720
movl %eax, 0x24(%rsp)
jmp 0x44d87
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x487a0
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: stetre[P]moonvulkan/src/flags.c
// Function: ShaderStageFlags
static int ShaderStageFlags(lua_State *L)
    {
    if(lua_type(L, 1) == LUA_TNUMBER)
        return pushshaderstageflags(L, luaL_checkinteger(L, 1));
    lua_pushinteger(L, checkshaderstageflags(L, 1));
    return 1;
    }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x1a240
cmpl $0x3, %eax
jne 0x44dd8
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x19190
movq 0x10(%rsp), %rdi
movl %eax, %esi
callq 0x488f0
movl %eax, 0x24(%rsp)
jmp 0x44e07
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x48b90
movq 0x8(%rsp), %rdi
movl %eax, %eax
movl %eax, %esi
callq 0x18be0
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq