LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: read_script
char * read_script(char * file)
{
	FILE * i;
	char * text;
	int cnt, l;

	text = malloc(SIZE);
	if (!text)
		return NULL;
	i = fopen(file, "r");
	if (!i)
		return NULL;
	for (l = 0;;) {
		text = realloc(text, l + SIZE);
		if (!text)
			return NULL;
		cnt = fread(&text[l], 1, SIZE, i);
		if (!cnt)
			break;
		l += cnt;
	}
	fclose(i);
	text = realloc(text, l + 1);
	if (!text)
		return NULL;
	text[l] = '\0';

	/* Check current System ARG_MAX limit. */
	if (l > 0.80 * (cnt = sysconf(_SC_ARG_MAX))) {
		fprintf(stderr, "%s: WARNING!!\n"
"   Scripts of length near to (or higher than) the current System limit on\n"
"   \"maximum size of arguments to EXEC\", could comprise its binary execution.\n"
"   In the current System the call sysconf(_SC_ARG_MAX) returns %d bytes\n"
"   and your script \"%s\" is %d bytes length.\n",
		my_name, cnt, file, l);
	}
	return text;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x1000, %edi           # imm = 0x1000
callq 0x4180
testq %rax, %rax
je 0x4e72
movq %rax, %r14
leaq 0x1978(%rip), %rsi      # 0x66fd
movq %rbx, %rdi
callq 0x41d0
testq %rax, %rax
je 0x4e72
movq %rax, %r12
movl $0x1000, %esi           # imm = 0x1000
movq %r14, %rdi
callq 0x41c0
xorl %r14d, %r14d
testq %rax, %rax
je 0x4e75
movq %rax, %r13
xorl %r15d, %r15d
movslq %r15d, %rbp
movq %r13, %rdi
addq %rbp, %rdi
movl $0x1, %esi
movl $0x1000, %edx           # imm = 0x1000
movq %r12, %rcx
callq 0x4070
testl %eax, %eax
je 0x4dfb
leal (%r15,%rax), %ebp
addl %r15d, %eax
addl $0x1000, %eax           # imm = 0x1000
movslq %eax, %rsi
movq %r13, %rdi
callq 0x41c0
movq %rax, %r13
movl %ebp, %r15d
testq %rax, %rax
jne 0x4db8
jmp 0x4e75
movq %r12, %rdi
callq 0x4090
leal 0x1(%r15), %eax
movslq %eax, %rsi
movq %r13, %rdi
callq 0x41c0
testq %rax, %rax
je 0x4e72
movq %rax, %r14
movb $0x0, (%rax,%rbp)
cvtsi2sd %r15d, %xmm0
movsd %xmm0, (%rsp)
xorl %edi, %edi
callq 0x41f0
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x11ca(%rip), %xmm0     # 0x6008
movsd (%rsp), %xmm1
ucomisd %xmm0, %xmm1
jbe 0x4e75
movq 0x61a8(%rip), %rcx      # 0xaff8
movq (%rcx), %rdi
leaq 0x156a(%rip), %rsi      # 0x63c4
leaq 0x1287(%rip), %rdx      # 0x60e8
movl %eax, %ecx
movq %rbx, %r8
movl %r15d, %r9d
xorl %eax, %eax
callq 0x4150
jmp 0x4e75
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: rand_mod
unsigned rand_mod(unsigned mod)
{
	/* Without skew */
	unsigned rnd, top = RAND_MAX;
	top -= top % mod;
	while (top <= (rnd = rand()))
		continue;
	/* Using high-order bits. */
	rnd = 1.0*mod*rnd/(1.0+top);
	return rnd;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edi, %ebp
movl $0x7fffffff, %r14d      # imm = 0x7FFFFFFF
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
xorl %edx, %edx
divl %edi
movl %edx, %ebx
xorl %edx, %r14d
callq 0x4260
cmpl %eax, %r14d
jbe 0x4ea1
movl %ebp, %ecx
cvtsi2sd %rcx, %xmm0
cvtsi2sd %eax, %xmm1
mulsd %xmm0, %xmm1
movl $0x80000000, %eax       # imm = 0x80000000
subl %ebx, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
divsd %xmm0, %xmm1
cvttsd2si %xmm1, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: noise
int noise(char * ptr, unsigned min, unsigned xtra, int str)
{
	if (xtra) xtra = rand_mod(xtra);
	xtra += min;
	for (min = 0; min < xtra; min++, ptr++)
		do
			*ptr = rand_chr();
		while (str && !isalnum((int)*ptr));
	if (str) *ptr = '\0';
	return xtra;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %ecx, %ebp
movl %esi, %r15d
movq %rdi, %rbx
testl %edx, %edx
je 0x4f1f
movl %edx, %edi
callq 0x4e87
movl %eax, %r14d
jmp 0x4f22
xorl %r14d, %r14d
addl %r15d, %r14d
je 0x4f76
xorl %r15d, %r15d
callq 0x4260
cmpl $0x7ffffeff, %eax       # imm = 0x7FFFFEFF
ja 0x4f2a
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x10cb(%rip), %xmm0     # 0x6010
divsd 0x10cb(%rip), %xmm0     # 0x6018
cvttsd2si %xmm0, %r12
movb %r12b, (%rbx)
testl %ebp, %ebp
je 0x4f6b
callq 0x4270
movq (%rax), %rax
movsbq %r12b, %rcx
testb $0x8, (%rax,%rcx,2)
je 0x4f2a
incl %r15d
incq %rbx
cmpl %r14d, %r15d
jne 0x4f2a
testl %ebp, %ebp
je 0x4f7d
movb $0x0, (%rbx)
movl %r14d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: prnt_bytes
void prnt_bytes(FILE * o, char * ptr, int m, int l, int n)
{
	int i;

	l += m;
	n += l;
	for (i = 0; i < n; i++) {
		if ((i & 0xf) == 0)
			fprintf(o, "\n\t\"");
		fprintf(o, "\\%03o", (unsigned char)((i>=m) && (i<l) ? ptr[i-m] : rand_chr()));
		if ((i & 0xf) == 0xf)
			fprintf(o, "\"");
	}
	if ((i & 0xf) != 0)
		fprintf(o, "\"");
	offset += n;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %r8d, %r15d
movq %rsi, 0x10(%rsp)
addl %edx, %ecx
addl %ecx, %r15d
jle 0x5070
movq %rdi, %r14
movslq %ecx, %rbp
movslq %edx, %rbx
movl %r15d, 0xc(%rsp)
movl %r15d, %r12d
xorl %r15d, %r15d
movl %r15d, %r13d
andl $0xf, %r13d
jne 0x4fe0
movl $0x3, %esi
movl $0x1, %edx
leaq 0x1506(%rip), %rdi      # 0x64de
movq %r14, %rcx
callq 0x4240
movq %r15, %rax
subq %rbx, %rax
setge %cl
cmpq %rbp, %r15
setl %dl
testb %dl, %cl
je 0x4ffd
movq 0x10(%rsp), %rcx
movb (%rcx,%rax), %al
jmp 0x5025
callq 0x4260
cmpl $0x7ffffeff, %eax       # imm = 0x7FFFFEFF
ja 0x4ffd
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0xff8(%rip), %xmm0      # 0x6010
divsd 0xff8(%rip), %xmm0      # 0x6018
cvttsd2si %xmm0, %rax
movzbl %al, %edx
movq %r14, %rdi
leaq 0x14b0(%rip), %rsi      # 0x64e2
xorl %eax, %eax
callq 0x4150
cmpl $0xf, %r13d
jne 0x504c
movl $0x22, %edi
movq %r14, %rsi
callq 0x4100
incq %r15
cmpq %r12, %r15
jne 0x4fbe
testb $0xf, %r15b
movl 0xc(%rsp), %r15d
je 0x5070
movl $0x22, %edi
movq %r14, %rsi
callq 0x4100
addl %r15d, 0x63d9(%rip)     # 0xb450
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: prnt_array
void prnt_array(FILE * o, void * ptr, char * name, int l, char * cast)
{
	int m = rand_mod(1+l/4);		/* Random amount of random pre  padding (offset) */
	int n = rand_mod(1+l/4);		/* Random amount of random post padding  (tail)  */
	int a = (offset+m)%l;
	if (cast && a) m += l - a;		/* Type alignement. */
	fprintf(o, "\n");
	fprintf(o, "#define      %s_z	%d", name, l);
	fprintf(o, "\n");
	fprintf(o, "#define      %s	(%s(&data[%d]))", name, cast?cast:"", offset+m);
	prnt_bytes(o, ptr, m, l, n);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r14
movl %ecx, %ebx
movq %rdx, 0x8(%rsp)
movq %rsi, 0x10(%rsp)
movq %rdi, %r15
leal 0x3(%rbx), %ebp
testl %ecx, %ecx
cmovnsl %ecx, %ebp
sarl $0x2, %ebp
incl %ebp
movl %ebp, %edi
callq 0x4e87
movl %eax, %r12d
movl %ebp, %edi
callq 0x4e87
movl %eax, 0x4(%rsp)
movl 0x6382(%rip), %eax      # 0xb450
addl %r12d, %eax
cltd
idivl %ebx
movl %edx, %r13d
movl %ebx, %eax
subl %edx, %eax
testl %edx, %edx
cmovnel %eax, %r13d
xorl %eax, %eax
testq %r14, %r14
cmovel %eax, %r13d
leaq 0x14d6(%rip), %rbp      # 0x65c7
cmovneq %r14, %rbp
addl %r12d, %r13d
movl $0xa, %edi
movq %r15, %rsi
callq 0x4100
movq %r15, %rdi
leaq 0x13d9(%rip), %rsi      # 0x64e8
movq 0x8(%rsp), %r14
movq %r14, %rdx
movl %ebx, %ecx
xorl %eax, %eax
callq 0x4150
movl $0xa, %edi
movq %r15, %rsi
callq 0x4100
movl 0x631c(%rip), %r8d      # 0xb450
addl %r13d, %r8d
leaq 0x13bf(%rip), %rsi      # 0x64fd
movq %r15, %rdi
movq %r14, %rdx
movq %rbp, %rcx
xorl %eax, %eax
callq 0x4150
movq %r15, %rdi
movq 0x10(%rsp), %rsi
movl %r13d, %edx
movl %ebx, %ecx
movl 0x4(%rsp), %r8d
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4f89
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: make
int make(void)
{
	char * cc, * cflags;
	char cmd[SIZE];

	cc = getenv("CC");
	if (!cc)
		cc = "cc";
	cflags = getenv("CFLAGS");
	if (!cflags)
		cflags = "";

if(!file2){
file2=(char*)realloc(file2,strlen(file)+3);
strcpy(file2,file);
file2=strcat(file2,".x");

}
	sprintf(cmd, "%s %s %s.x.c -o %s", cc, cflags, file, file2);
	if (verbose) fprintf(stderr, "%s: %s\n", my_name, cmd);
	if (system(cmd))
		return -1;
	sprintf(cmd, "strip %s", file2);
	if (verbose) fprintf(stderr, "%s: %s\n", my_name, cmd);
	if (system(cmd))
		fprintf(stderr, "%s: never mind\n", my_name);
	sprintf(cmd, "chmod ug=rwx,o=rx %s", file2);
	if (verbose) fprintf(stderr, "%s: %s\n", my_name, cmd);
	if (system(cmd))
		fprintf(stderr, "%s: remove read permission\n", my_name);

	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1008, %rsp           # imm = 0x1008
leaq 0xb72(%rip), %rdi       # 0x666a
callq 0x4030
testq %rax, %rax
leaq 0xb02(%rip), %rbx       # 0x6609
cmovneq %rax, %rbx
leaq 0xb5b(%rip), %rdi       # 0x666d
callq 0x4030
testq %rax, %rax
leaq 0xaa6(%rip), %r14       # 0x65c7
cmovneq %rax, %r14
cmpq $0x0, 0x5963(%rip)      # 0xb490
jne 0x5b78
movq 0x5962(%rip), %r15      # 0xb498
movq %r15, %rdi
callq 0x40b0
leaq 0x3(%rax), %rdi
callq 0x4180
movq %rax, %r12
movq %rax, 0x593f(%rip)      # 0xb490
movq %rax, %rdi
movq %r15, %rsi
callq 0x4060
movq %r12, %rdi
callq 0x40b0
movw $0x782e, (%r12,%rax)    # imm = 0x782E
movb $0x0, 0x2(%r12,%rax)
movq %r12, 0x5918(%rip)      # 0xb490
movq 0x5919(%rip), %r8       # 0xb498
movq 0x590a(%rip), %r9       # 0xb490
leaq 0xaea(%rip), %rsi       # 0x6677
movq %rsp, %rdi
movq %rbx, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x4220
cmpl $0x0, 0x588c(%rip)      # 0xb430
jne 0x5c30
movq %rsp, %rdi
callq 0x40c0
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testl %eax, %eax
jne 0x5c1f
movq 0x58ce(%rip), %rdx      # 0xb490
leaq 0xac9(%rip), %rsi       # 0x6692
movq %rsp, %rdi
xorl %eax, %eax
callq 0x4220
cmpl $0x0, 0x5856(%rip)      # 0xb430
jne 0x5c57
movq %rsp, %rdi
callq 0x40c0
testl %eax, %eax
jne 0x5c7e
movq 0x589d(%rip), %rdx      # 0xb490
leaq 0xab1(%rip), %rsi       # 0x66ab
xorl %ebx, %ebx
movq %rsp, %rdi
xorl %eax, %eax
callq 0x4220
cmpl $0x0, 0x5823(%rip)      # 0xb430
jne 0x5c88
movq %rsp, %rdi
callq 0x40c0
testl %eax, %eax
jne 0x5caf
movl %ebx, %eax
addq $0x1008, %rsp           # imm = 0x1008
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq 0x53c1(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0xa49(%rip), %rsi       # 0x668a
leaq 0x4a0(%rip), %rdx       # 0x60e8
movq %rsp, %rcx
xorl %eax, %eax
callq 0x4150
jmp 0x5baa
movq 0x539a(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0xa22(%rip), %rsi       # 0x668a
leaq 0x479(%rip), %rdx       # 0x60e8
movq %rsp, %rcx
xorl %eax, %eax
callq 0x4150
jmp 0x5bdc
callq 0x439e
jmp 0x5bec
movq 0x5369(%rip), %rax      # 0xaff8
movq (%rax), %rdi
leaq 0x9f1(%rip), %rsi       # 0x668a
leaq 0x448(%rip), %rdx       # 0x60e8
movq %rsp, %rcx
xorl %eax, %eax
callq 0x4150
jmp 0x5c0f
callq 0x43c3
jmp 0x5c1f
// File: /workspace/github_c_makefile_star2_O1/fuldaros[P]akb_sources/cc/akb_cc.c
// Function: main
int main(int argc, char * argv[])
{
	putenv("LANG=");
	do_all(argc, argv);
	/* Return on error */
	perror(argv[0]);
	exit(1);
	return 1;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x71c(%rip), %rdi       # 0x66dc
callq 0x4120
movl %ebp, %edi
movq %rbx, %rsi
callq 0x5cb9
movq (%rbx), %rdi
callq 0x41e0
movl $0x1, %edi
callq 0x4230
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/chunk.c
// Function: moonsndfile_freechunks
void freechunks(lua_State *L, chunknode_t *list)
/* free all cunks in ud->chunklist */
    {
    chunknode_t *pp, *p = list;
    while(p)
        {
        pp = p;
        p = p->next;
        freechunk(L, pp);
        }
    }

// Assembly:
testq %rsi, %rsi
je 0x48e2
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rsi), %r14
movq %rbx, %rdi
callq 0x4240
movq %r14, %rsi
testq %r14, %r14
jne 0x48c8
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/chunk.c
// Function: SetChunk
static int SetChunk(lua_State *L)
    {
    ud_t *ud;
    sndfile_t sndfile = checksndfile(L, 1, &ud);
    chunknode_t *chunknode = checkchunk(L, 2);
    
    CheckPfn(L, set_chunk, 1, 0, 26);
    if(sf.set_chunk(sndfile, &chunknode->chunk) != 0)
        {
        freechunk(L, chunknode);
        return sndfileerror(L, sndfile);
        }
    
    insertchunk(ud, chunknode); 
    /* The chunk will be released after file closure, as requested in sndfile.h:
     * ("The chunk_info->data pointer must be valid until the file is closed.")
     */
    return 0;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0x8793(%rip), %rcx      # 0xd097
leaq 0x8(%rsp), %rdx
movl $0x1, %esi
callq 0x4400
movq %rax, %r14
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4500
movq %rax, %r15
movq 0xe6b3(%rip), %rax      # 0x12fe0
movq 0x118(%rax), %rax
testq %rax, %rax
je 0x4961
movq %r15, %rsi
addq $0x8, %rsi
movq %r14, %rdi
callq *%rax
testl %eax, %eax
je 0x4989
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4240
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4340
jmp 0x49bb
movl $0x1, %edi
xorl %esi, %esi
movl $0x1a, %edx
callq 0x4440
testl %eax, %eax
je 0x499d
leaq 0x8763(%rip), %rsi      # 0xd0e0
movq %rbx, %rdi
xorl %eax, %eax
callq 0x46c0
jmp 0x49bb
movq 0x8(%rsp), %rax
movq 0x40(%rax), %rcx
movq %rcx, (%r15)
movq %r15, 0x40(%rax)
xorl %eax, %eax
jmp 0x49bb
leaq 0x8707(%rip), %rsi      # 0xd0ab
movq %rbx, %rdi
movl $0x1, %edx
xorl %ecx, %ecx
movl $0x1a, %r8d
xorl %eax, %eax
callq 0x46c0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_set_count
int command_set_count(lua_State *L, int command)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    sf_count_t frames = luaL_checkinteger(L, 2);    
    int res = sf.command(sndfile, command, &frames, sizeof(frames));
    lua_pushboolean(L, res == 0);
    return 1;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x8471(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4470
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
movq 0xe38f(%rip), %rax      # 0x12fe0
movq %r14, %rdi
movl %ebp, %esi
movl $0x8, %ecx
callq *0x40(%rax)
xorl %esi, %esi
testl %eax, %eax
sete %sil
movq %rbx, %rdi
callq 0x4550
movl $0x1, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_get_boolean
int command_get_boolean(lua_State *L, int command)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    int val = sf.command(sndfile, command, NULL, 0);
    lua_pushboolean(L, val);
    return 1;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
leaq 0x840b(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq 0xe341(%rip), %r8       # 0x12fe0
movq %rax, %rdi
movl %ebx, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq *0x40(%r8)
movq %r14, %rdi
movl %eax, %esi
callq 0x4550
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_set_boolean
int command_set_boolean(lua_State *L, int command)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    int val = checkboolean(L, 2);
    sf.command(sndfile, command, NULL, val);
    return 0;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
leaq 0x83c3(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r15
movq %r14, %rdi
movl $0x2, %esi
callq 0x44d0
movq 0xe2e9(%rip), %r8       # 0x12fe0
movq %r15, %rdi
movl %ebx, %esi
xorl %edx, %edx
movl %eax, %ecx
callq *0x40(%r8)
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_get_integer
int command_get_integer(lua_State *L, int command)
    {
    int val;
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    if(sf.command(sndfile, command, &val, sizeof(val)) != 0)
        return sndfileerror(L, sndfile);
    lua_pushinteger(L, val);
    return 1;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %r14
leaq 0x8378(%rip), %rcx      # 0xd097
movl $0x1, %ebx
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r15
movq 0xe2a6(%rip), %rax      # 0x12fe0
leaq 0x4(%rsp), %rdx
movq %r15, %rdi
movl %ebp, %esi
movl $0x4, %ecx
callq *0x40(%rax)
testl %eax, %eax
je 0x4d5f
movq %r14, %rdi
movq %r15, %rsi
callq 0x4340
movl %eax, %ebx
jmp 0x4d6c
movslq 0x4(%rsp), %rsi
movq %r14, %rdi
callq 0x4320
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_set_integer
int command_set_integer(lua_State *L, int command)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    int val = luaL_checkinteger(L, 2);
    if(sf.command(sndfile, command, &val, sizeof(val)) != SF_TRUE)
        return sndfileerror(L, sndfile);
    return 0;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x830b(%rip), %rcx      # 0xd097
xorl %r14d, %r14d
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r15
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4470
leaq 0x4(%rsp), %rdx
movl %eax, (%rdx)
movq 0xe227(%rip), %rax      # 0x12fe0
movq %r15, %rdi
movl %ebp, %esi
movl $0x4, %ecx
callq *0x40(%rax)
cmpl $0x1, %eax
je 0x4dd9
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4340
movl %eax, %r14d
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_get_double
int command_get_double(lua_State *L, int command)
    {
    double val;
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    if(sf.command(sndfile, command, &val, sizeof(val)) != 0)
        return sndfileerror(L, sndfile);
    lua_pushnumber(L, val);
    return 1;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %r14
leaq 0x829d(%rip), %rcx      # 0xd097
movl $0x1, %ebx
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r15
movq 0xe1cb(%rip), %rax      # 0x12fe0
movq %rsp, %rdx
movq %r15, %rdi
movl %ebp, %esi
movl $0x8, %ecx
callq *0x40(%rax)
testl %eax, %eax
je 0x4e38
movq %r14, %rdi
movq %r15, %rsi
callq 0x4340
movl %eax, %ebx
jmp 0x4e45
movsd (%rsp), %xmm0
movq %r14, %rdi
callq 0x4510
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_set_double
int command_set_double(lua_State *L, int command)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    double val = luaL_checknumber(L, 2);
    if(sf.command(sndfile, command, &val, sizeof(val)) != SF_TRUE)
        return sndfileerror(L, sndfile);
    return 0;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x8232(%rip), %rcx      # 0xd097
xorl %r14d, %r14d
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r15
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4260
movq %rsp, %rdx
movsd %xmm0, (%rdx)
movq 0xe14e(%rip), %rax      # 0x12fe0
movq %r15, %rdi
movl %ebp, %esi
movl $0x8, %ecx
callq *0x40(%rax)
cmpl $0x1, %eax
je 0x4eb2
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4340
movl %eax, %r14d
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: moonsndfile_command_get_double_all_channels
int command_get_double_all_channels(lua_State *L, int command, int success_retcode)
    {
    ud_t *ud;
    int i;
    sndfile_t sndfile = checksndfile(L, 1, &ud);
    size_t size = ud->sfinfo.channels * sizeof(double);
    double *val = (double*)Malloc(L, size);
    int res = sf.command(sndfile, command, val, size);
    if(res != success_retcode)
        return sndfileerror(L, sndfile);
    lua_newtable(L);
    for(i = 0; i < ud->sfinfo.channels; i++)
        {
        lua_pushnumber(L, val[i]);
        lua_rawseti(L, -2, i+1);
        }
    Free(L, val);
    return 1;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebp
movl %esi, %r12d
movq %rdi, %rbx
leaq 0x81bd(%rip), %rcx      # 0xd097
movq %rsp, %r14
movl $0x1, %esi
movq %r14, %rdx
callq 0x4400
movq %rax, %r15
movq (%r14), %rax
movslq 0x2c(%rax), %r13
shlq $0x3, %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x41e0
movq %rax, %r14
movq 0xe0d3(%rip), %rax      # 0x12fe0
movq %r15, %rdi
movl %r12d, %esi
movq %r14, %rdx
movl %r13d, %ecx
callq *0x40(%rax)
cmpl %ebp, %eax
jne 0x4f79
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
movq (%rsp), %rax
cmpl $0x0, 0x2c(%rax)
jle 0x4f67
xorl %r15d, %r15d
movsd (%r14,%r15,8), %xmm0
movq %rbx, %rdi
callq 0x4510
incq %r15
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
movq (%rsp), %rax
movslq 0x2c(%rax), %rax
cmpq %rax, %r15
jl 0x4f39
movq %rbx, %rdi
movq %r14, %rsi
callq 0x43a0
movl $0x1, %eax
jmp 0x4f84
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4340
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: GetChannelMapInfo
static int GetChannelMapInfo(lua_State *L)
    {
    ud_t *ud;
    int i;
    sndfile_t sndfile = checksndfile(L, 1, &ud);
    size_t size = ud->sfinfo.channels * sizeof(int);
    int *val = (int*)Malloc(L, size);
    int res = sf.command(sndfile, SFC_GET_CHANNEL_MAP_INFO, val, size);
    if(res == 0)
        return sndfileerror(L, sndfile);
    lua_newtable(L);
    for(i = 0; i < ud->sfinfo.channels; i++)
        {
        pushchannelmap(L, val[i]);
        lua_rawseti(L, -2, i+1);
        }
    Free(L, val);
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x809f(%rip), %rcx      # 0xd097
movq %rsp, %r14
movl $0x1, %esi
movq %r14, %rdx
callq 0x4400
movq %rax, %r15
movq (%r14), %rax
movslq 0x2c(%rax), %r12
shlq $0x2, %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x41e0
movq %rax, %r14
movq 0xdfb5(%rip), %rax      # 0x12fe0
movq %r15, %rdi
movl $0x1100, %esi           # imm = 0x1100
movq %r14, %rdx
movl %r12d, %ecx
callq *0x40(%rax)
testl %eax, %eax
je 0x509c
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
movq (%rsp), %rax
cmpl $0x0, 0x2c(%rax)
jle 0x508a
xorl %r15d, %r15d
movl (%r14,%r15,4), %edx
movq %rbx, %rdi
movl $0x7, %esi
callq 0x4120
incq %r15
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
movq (%rsp), %rax
movslq 0x2c(%rax), %rax
cmpq %rax, %r15
jl 0x5059
movq %rbx, %rdi
movq %r14, %rsi
callq 0x43a0
movl $0x1, %eax
jmp 0x50a7
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4340
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: SetChannelMapInfo
static int SetChannelMapInfo(lua_State *L)
    {
    ud_t *ud;
    size_t count, size;
    int err, res;
    sndfile_t sndfile = checksndfile(L, 1, &ud);
    int *list = checkchannelmaplist(L, 2, &count, &err);
    if(err)
        return luaL_argerror(L, 2, errstring(err));
    if(count != (size_t)ud->sfinfo.channels)
        {
        freechannelmaplist(L, list);
        return luaL_argerror(L, 2, errstring(ERR_LENGTH));
        }
    size = count * sizeof(int);
    res = sf.command(sndfile, SFC_SET_CHANNEL_MAP_INFO, list, size);
    freechannelmaplist(L, list);
    if(res == 0)
        return sndfileerror(L, sndfile);
    return 1;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x7fce(%rip), %rcx      # 0xd097
leaq 0x10(%rsp), %rdx
movl $0x1, %esi
callq 0x4400
movq %rax, %r14
leaq 0x8(%rsp), %rcx
leaq 0x1c(%rsp), %r12
movq %rbx, %rdi
movl $0x7, %esi
movl $0x2, %edx
movq %r12, %r8
callq 0x42f0
movl (%r12), %edi
testl %edi, %edi
jne 0x5163
movq %rax, %r15
movq 0x8(%rsp), %rcx
movq 0x10(%rsp), %rax
movslq 0x2c(%rax), %rax
cmpq %rax, %rcx
jne 0x5153
movq 0xdec1(%rip), %rax      # 0x12fe0
shll $0x2, %ecx
movq %r14, %rdi
movl $0x1101, %esi           # imm = 0x1101
movq %r15, %rdx
callq *0x40(%rax)
movl %eax, %ebp
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4160
movl $0x1, %eax
testl %ebp, %ebp
jne 0x5178
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4340
jmp 0x5178
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4160
movl $0xfffffff9, %edi       # imm = 0xFFFFFFF9
callq 0x4660
movq %rbx, %rdi
movl $0x2, %esi
movq %rax, %rdx
callq 0x4110
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: WavexSetAmbisonic
static int WavexSetAmbisonic(lua_State *L)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    int val = checkambisonic(L, 2);
    int res = sf.command(sndfile, SFC_WAVEX_SET_AMBISONIC, NULL, val);
    if(res == 0)
        return sndfileerror(L, sndfile);
    return 0;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x7f04(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
movq %rbx, %rdi
movl $0xb, %esi
movl $0x2, %edx
callq 0x4130
movq 0xde25(%rip), %r8       # 0x12fe0
movq %r14, %rdi
movl $0x1200, %esi           # imm = 0x1200
xorl %edx, %edx
movl %eax, %ecx
callq *0x40(%r8)
testl %eax, %eax
je 0x51d9
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rbx, %rdi
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x4340
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/command.c
// Function: WavexGetAmbisonic
static int WavexGetAmbisonic(lua_State *L)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    int val = sf.command(sndfile, SFC_WAVEX_GET_AMBISONIC, NULL, 0);
    if(val==0)
        return sndfileerror(L, sndfile);
    pushambisonic(L, val);
    return 1;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x7e9e(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
movq 0xddd1(%rip), %rax      # 0x12fe0
movq %r14, %rdi
movl $0x1201, %esi           # imm = 0x1201
xorl %edx, %edx
xorl %ecx, %ecx
callq *0x40(%rax)
movq %rbx, %rdi
testl %eax, %eax
je 0x523e
movl $0xb, %esi
movl %eax, %edx
callq 0x4120
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x4340
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/datahandling.c
// Function: Unpack
static int Unpack(lua_State *L)
    {
    size_t len;
    int type = checktype(L, 1);
    const void *data = luaL_checklstring(L, 2, &len);
    return Unpack_(L, type, data, len);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movl $0x65, %esi
movl $0x1, %edx
callq 0x4130
movl %eax, %r15d
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4380
decl %r15d
cmpl $0x3, %r15d
ja 0x5822
movq %rax, %r14
movq 0x8(%rsp), %r12
leaq 0x7c2f(%rip), %rax      # 0xd298
movslq (%rax,%r15,4), %rcx
addq %rax, %rcx
jmpq *%rcx
cmpq $0x2, %r12
setb %al
movl %r12d, %ecx
orb %al, %cl
testb $0x1, %cl
jne 0x57fc
shrq %r12
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
negq %r12
movl $0x1, %r15d
movswq -0x2(%r14,%r15,2), %rsi
movq %rbx, %rdi
callq 0x4320
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
leaq (%r12,%r15), %rax
incq %rax
incq %r15
cmpq $0x1, %rax
jne 0x56a1
jmp 0x57f8
cmpq $0x4, %r12
setb %al
testb $0x3, %r12b
setne %cl
orb %al, %cl
jne 0x57fc
shrq $0x2, %r12
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
negq %r12
movl $0x1, %r15d
xorps %xmm0, %xmm0
cvtss2sd -0x4(%r14,%r15,4), %xmm0
movq %rbx, %rdi
callq 0x4510
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
leaq (%r12,%r15), %rax
incq %rax
incq %r15
cmpq $0x1, %rax
jne 0x5705
jmp 0x57f8
cmpq $0x8, %r12
setb %al
testb $0x7, %r12b
setne %cl
orb %al, %cl
jne 0x57fc
shrq $0x3, %r12
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
negq %r12
movl $0x1, %r15d
movsd -0x8(%r14,%r15,8), %xmm0
movq %rbx, %rdi
callq 0x4510
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
leaq (%r12,%r15), %rax
incq %rax
incq %r15
cmpq $0x1, %rax
jne 0x576d
jmp 0x57f8
cmpq $0x4, %r12
setb %al
testb $0x3, %r12b
setne %cl
orb %al, %cl
jne 0x57fc
shrq $0x2, %r12
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
negq %r12
movl $0x1, %r15d
movslq -0x4(%r14,%r15,4), %rsi
movq %rbx, %rdi
callq 0x4320
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r15, %rdx
callq 0x4490
leaq (%r12,%r15), %rax
incq %rax
incq %r15
cmpq $0x1, %rax
jne 0x57cb
movb $0x1, %cl
jmp 0x5803
movl $0xfffffff9, %ebp       # imm = 0xFFFFFFF9
xorl %ecx, %ecx
movl $0x1, %eax
testb %cl, %cl
jne 0x583f
movl %ebp, %edi
callq 0x4660
movq %rbx, %rdi
movq %rax, %rsi
xorl %eax, %eax
callq 0x46c0
jmp 0x583f
leaq 0x7adb(%rip), %rsi      # 0xd304
leaq 0x7aee(%rip), %rdx      # 0xd31e
movq %rbx, %rdi
movl $0xe7, %ecx
xorl %eax, %eax
callq 0x46c0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/enums.c
// Function: moonsndfile_enums_checklist
int* enums_checklist(lua_State *L, uint32_t domain, int arg, size_t *count, int *err)
    {
    int* list;
    size_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 = (int*)MallocNoErr(L, sizeof(int) * (*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:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r14
movl %edx, %ebp
movl %esi, 0x14(%rsp)
movq %rdi, %r15
movq %rcx, 0x8(%rsp)
movq $0x0, (%rcx)
movl $0x0, (%r8)
movl %edx, %esi
callq 0x4730
testl %eax, %eax
jle 0x65b7
movq %r15, %rdi
movl %ebp, %esi
callq 0x4730
cmpl $0x5, %eax
jne 0x65c0
movq %r15, %rdi
movl %ebp, %esi
callq 0x4740
movq 0x8(%rsp), %rcx
movq %rax, (%rcx)
testq %rax, %rax
je 0x65b7
shlq $0x2, %rax
movq %r15, %rdi
movq %rax, %rsi
callq 0x4390
testq %rax, %rax
je 0x65dc
movq %rax, %r13
xorl %r12d, %r12d
movq 0x8(%rsp), %rax
cmpq (%rax), %r12
jae 0x65ca
leaq 0x1(%r12), %rbx
movq %r15, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x42a0
movq %r15, %rdi
movl 0x14(%rsp), %esi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movq %r14, %rcx
callq 0x4600
movl %eax, (%r13,%r12,4)
movq %r15, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x4080
cmpl $0x0, (%r14)
movq %rbx, %r12
je 0x6553
movq %r15, %rdi
movq %r13, %rsi
callq 0x43a0
movq 0x8(%rsp), %rax
movq $0x0, (%rax)
jmp 0x65c7
movl $0x1, (%r14)
jmp 0x65c7
movl $0xfffffffc, (%r14)     # imm = 0xFFFFFFFC
xorl %r13d, %r13d
movq %r13, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x8(%rsp), %rax
movq $0x0, (%rax)
movl $0xfffffffa, (%r14)     # imm = 0xFFFFFFFA
jmp 0x65c7
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/enums.c
// Function: Enum
static int Enum(lua_State *L)
/* { strings } = cl.enum('type') lists all the values for a given enum type */
    { 
    const char *s = luaL_checkstring(L, 1); 
#define CASE(xxx) if(strcmp(s, ""#xxx) == 0) return values##xxx(L)
    CASE(type);
    CASE(format);
    CASE(subformat);
    CASE(endianness);
    CASE(stringtype);
    CASE(whence);
    CASE(openmode);
    CASE(channelmap);
    CASE(ditherlevel);
    CASE(dithertype);
    CASE(loopmode);
    CASE(ambisonic);
    CASE(bitratemode);
#undef CASE
    return 0;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl $0x1, %ebp
movl $0x1, %esi
xorl %edx, %edx
callq 0x4380
movq %rax, %r14
leaq 0x5b9d(%rip), %rsi      # 0xe4de
movq %rax, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a60
leaq 0x54bc(%rip), %rsi      # 0xde14
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8aab
leaq 0x5ce4(%rip), %rsi      # 0xe653
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a67
leaq 0x5508(%rip), %rsi      # 0xde8e
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a6e
leaq 0x54fc(%rip), %rsi      # 0xde99
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a75
leaq 0x54f0(%rip), %rsi      # 0xdea4
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a7c
leaq 0x54e0(%rip), %rsi      # 0xdeab
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a83
leaq 0x54d2(%rip), %rsi      # 0xdeb4
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a8a
leaq 0x54c6(%rip), %rsi      # 0xdebf
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a91
leaq 0x54bb(%rip), %rsi      # 0xdecb
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a98
leaq 0x54b3(%rip), %rsi      # 0xded6
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8a9f
leaq 0x4817(%rip), %rsi      # 0xd24d
movq %r14, %rdi
callq 0x4430
testl %eax, %eax
je 0x8aa6
leaq 0x5496(%rip), %rsi      # 0xdedf
movq %r14, %rdi
callq 0x4430
movl %eax, %ecx
xorl %eax, %eax
testl %ecx, %ecx
jne 0x8aba
movl $0xc, %ebp
jmp 0x8aab
movl $0x65, %ebp
jmp 0x8aab
movl $0x2, %ebp
jmp 0x8aab
movl $0x3, %ebp
jmp 0x8aab
movl $0x4, %ebp
jmp 0x8aab
movl $0x5, %ebp
jmp 0x8aab
movl $0x6, %ebp
jmp 0x8aab
movl $0x7, %ebp
jmp 0x8aab
movl $0x8, %ebp
jmp 0x8aab
movl $0x9, %ebp
jmp 0x8aab
movl $0xa, %ebp
jmp 0x8aab
movl $0xb, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x4540
movl $0x1, %eax
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/format.c
// Function: FormatCheck
static int FormatCheck(lua_State *L)
/* boolean = sf.format_check(format, subformat) */
    {
    SF_INFO sfinfo;
    int format = checkformat(L, 1);
    int subformat = checksubformat(L, 2);
    
    memset(&sfinfo, 0, sizeof(sfinfo));
    sfinfo.channels = 1;
    sfinfo.format = (format & SF_FORMAT_TYPEMASK) | subformat;
    lua_pushboolean(L, sf.format_check(&sfinfo));
    return 1;
    }

// Assembly:
pushq %rbp
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movl $0x1, %esi
movl $0x1, %edx
callq 0x4130
movl %eax, %ebp
movq %rbx, %rdi
movl $0x2, %esi
movl $0x2, %edx
callq 0x4130
xorps %xmm0, %xmm0
movq %rsp, %rdi
movaps %xmm0, (%rdi)
movaps %xmm0, 0x10(%rdi)
movl $0x1, 0xc(%rdi)
andl $0xfff0000, %ebp        # imm = 0xFFF0000
orl %eax, %ebp
movl %ebp, 0x10(%rdi)
movq 0xa4c0(%rip), %rax      # 0x12fe0
callq *0x48(%rax)
movq %rbx, %rdi
movl %eax, %esi
callq 0x4550
movl $0x1, %eax
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/format.c
// Function: GetSimpleFormatList
static int GetSimpleFormatList(lua_State *L)
    {
    SF_FORMAT_INFO info;
    int i, count;
    sf.command(NULL, SFC_GET_SIMPLE_FORMAT_COUNT, &count, sizeof(count));
    lua_newtable(L);
    for(i = 0; i < count; i++) 
        {
        info.format = i;
        sf.command(NULL, SFC_GET_SIMPLE_FORMAT, &info, sizeof(info));
        pushsimpleformat(L, &info);
        lua_rawseti(L, -2, i+1);
        }
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq 0xa492(%rip), %r12      # 0x12fe0
leaq 0xc(%rsp), %r14
xorl %edi, %edi
movl $0x1020, %esi           # imm = 0x1020
movq %r14, %rdx
movl $0x4, %ecx
callq *0x40(%r12)
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
cmpl $0x0, (%r14)
jle 0x8bc2
xorl %r14d, %r14d
leaq 0x10(%rsp), %r15
movl %r14d, 0x10(%rsp)
xorl %edi, %edi
movl $0x1021, %esi           # imm = 0x1021
movq %r15, %rdx
movl $0x18, %ecx
callq *0x40(%r12)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x43e0
incq %r14
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r14, %rdx
callq 0x4490
movslq 0xc(%rsp), %rax
cmpq %rax, %r14
jl 0x8b81
movl $0x1, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/format.c
// Function: GetFormatList
static int GetFormatList(lua_State *L)
    {
    SF_FORMAT_INFO info;
    int i, count;
    sf.command(NULL, SFC_GET_FORMAT_MAJOR_COUNT, &count, sizeof(count));

    lua_newtable(L);
    memset(&info, 0, sizeof(info));
    for(i = 0; i < count; i++) 
        {
        info.format = i;
        sf.command(NULL, SFC_GET_FORMAT_MAJOR, &info, sizeof(info));
        sf.command(NULL, SFC_GET_FORMAT_INFO, &info, sizeof(info));
        pushformatinfo(L, &info);
        lua_rawseti(L, -2, i+1);
        }
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq 0xa3f8(%rip), %r12      # 0x12fe0
leaq 0xc(%rsp), %r14
xorl %edi, %edi
movl $0x1030, %esi           # imm = 0x1030
movq %r14, %rdx
movl $0x4, %ecx
callq *0x40(%r12)
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
cmpl $0x0, (%r14)
jle 0x8c81
xorl %r14d, %r14d
leaq 0x10(%rsp), %r15
movl %r14d, 0x10(%rsp)
xorl %edi, %edi
movl $0x1031, %esi           # imm = 0x1031
movq %r15, %rdx
movl $0x18, %ecx
callq *0x40(%r12)
xorl %edi, %edi
movl $0x1028, %esi           # imm = 0x1028
movq %r15, %rdx
movl $0x18, %ecx
callq *0x40(%r12)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x44e0
incq %r14
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movq %r14, %rdx
callq 0x4490
movslq 0xc(%rsp), %rax
cmpq %rax, %r14
jl 0x8c2c
movl $0x1, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/format.c
// Function: GetFormatInfo
static int GetFormatInfo(lua_State *L)
    {
    SF_FORMAT_INFO info;
    int format = checkformat(L, 1);
    memset(&info, 0, sizeof(info));
    info.format = format;
    sf.command(NULL, SFC_GET_FORMAT_INFO, &info, sizeof(info));
    pushformatinfo(L, &info);
    return 1;
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x1, %esi
movl $0x1, %edx
callq 0x4130
xorps %xmm0, %xmm0
movq %rsp, %r14
movaps %xmm0, (%r14)
movq $0x0, 0x10(%r14)
movl %eax, (%r14)
movq 0xa319(%rip), %rax      # 0x12fe0
xorl %edi, %edi
movl $0x1028, %esi           # imm = 0x1028
movq %r14, %rdx
movl $0x18, %ecx
callq *0x40(%rax)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x44e0
movl $0x1, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/format.c
// Function: GetSubFormatInfo
static int GetSubFormatInfo(lua_State *L)
    {
    SF_FORMAT_INFO info;
    int subformat = checksubformat(L, 1);
    memset(&info, 0, sizeof(info));
    info.format = subformat;
    sf.command(NULL, SFC_GET_FORMAT_INFO, &info, sizeof(info));
    pushsubformatinfo(L, &info);
    return 1;
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x2, %esi
movl $0x1, %edx
callq 0x4130
xorps %xmm0, %xmm0
movq %rsp, %r14
movaps %xmm0, (%r14)
movq $0x0, 0x10(%r14)
movl %eax, (%r14)
movq 0xa2ba(%rip), %rax      # 0x12fe0
xorl %edi, %edi
movl $0x1028, %esi           # imm = 0x1028
movq %r14, %rdx
movl $0x18, %ecx
callq *0x40(%rax)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4330
movl $0x1, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/main.c
// Function: luaopen_moonsndfile
int luaopen_moonsndfile(lua_State *L)
/* Lua calls this function to load the module */
    {
    moonsndfile_L = L;

    moonsndfile_utils_init(L);
    atexit(AtExit);

    lua_newtable(L); /* the cl table */

    /* add functions: */
    moonsndfile_open_getproc(L);
    moonsndfile_open_version(L);
    moonsndfile_open_enums(L);
    moonsndfile_open_tracing(L);
    moonsndfile_open_sndfile(L);
    moonsndfile_open_readwrite(L);
    moonsndfile_open_rawreadwrite(L);
    moonsndfile_open_datahandling(L);
    moonsndfile_open_command(L);
    moonsndfile_open_format(L);
    moonsndfile_open_chunk(L);

#if 0 //@@
    /* Add functions implemented in Lua */
    lua_pushvalue(L, -1); lua_setglobal(L, "moonsndfile");
    if(luaL_dostring(L, "require('moonsndfile.utils')") != 0) lua_error(L);
    lua_pushnil(L);  lua_setglobal(L, "moonsndfile");
#endif

    return 1;
    }

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq %rdi, 0xa11d(%rip)      # 0x13560
callq 0x45c0
leaq 0x70(%rip), %rdi        # 0x94bf
callq 0xc140
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4220
movq %rbx, %rdi
callq 0x44a0
movq %rbx, %rdi
callq 0x4410
movq %rbx, %rdi
callq 0x4070
movq %rbx, %rdi
callq 0x4050
movq %rbx, %rdi
callq 0x4750
movq %rbx, %rdi
callq 0x4360
movq %rbx, %rdi
callq 0x41f0
movq %rbx, %rdi
callq 0x4640
movq %rbx, %rdi
callq 0x41d0
movq %rbx, %rdi
callq 0x42e0
movq %rbx, %rdi
callq 0x4250
movl $0x1, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/main.c
// Function: AtExit
static void AtExit(void)
    {
    if(moonsndfile_L)
        {
        enums_free_all(moonsndfile_L);
        moonsndfile_atexit_getproc();
        moonsndfile_L = NULL;
        }
    }

// Assembly:
movq 0xa09a(%rip), %rdi      # 0x13560
testq %rdi, %rdi
je 0x94e5
pushq %rax
callq 0x4090
callq 0x40a0
movq $0x0, 0xa07f(%rip) # 0x13560
addq $0x8, %rsp
retq
nop
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/objects.c
// Function: moonsndfile_newuserdata
ud_t *newuserdata(lua_State *L, void *handle, const char *mt)
    {
    ud_t *ud;
    /* we use handle as search key */
    ud = (ud_t*)udata_new(L, sizeof(ud_t), (uint64_t)(uintptr_t)handle, mt);
    memset(ud, 0, sizeof(ud_t));
    ud->handle = handle;
    MarkValid(ud);
    return ud;
    }

// Assembly:
pushq %rbx
movq %rdx, %rcx
movq %rsi, %rbx
movl $0x50, %esi
movq %rbx, %rdx
callq 0x40c0
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movups %xmm0, 0x10(%rax)
movups %xmm0, 0x20(%rax)
movups %xmm0, 0x30(%rax)
movups %xmm0, 0x40(%rax)
movq %rbx, (%rax)
orb $0x1, 0x18(%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/objects.c
// Function: moonsndfile_freeuserdata
int freeuserdata(lua_State *L, ud_t *ud)
    {
    /* The 'Valid' mark prevents double calls when an object is explicitly destroyed, 
     * and subsequently deleted also by the GC (the ud sticks around until the GC
     * collects it, so we mark it as invalid when the object is explicitly destroyed
     * by the script, or implicitly destroyed because child of a destroyed object). */
    if(!IsValid(ud)) return 0;
    CancelValid(ud);
    if(ud->info) 
        Free(L, ud->info);
    udata_free(L, (uint64_t)(uintptr_t)ud->handle);
    return 1;
    }

// Assembly:
movl 0x18(%rsi), %ecx
xorl %eax, %eax
testb $0x1, %cl
je 0x955d
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
andl $-0x2, %ecx
movl %ecx, 0x18(%rsi)
movq 0x48(%rsi), %rsi
testq %rsi, %rsi
je 0x9546
movq %rbx, %rdi
callq 0x43a0
movq (%r14), %rsi
movq %rbx, %rdi
callq 0x46f0
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/rawreadwrite.c
// Function: ReadRaw
static int ReadRaw(lua_State *L)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    size_t bytes = luaL_checkinteger(L, 2);
    char *ptr = (char*)Malloc(L, bytes);
    sf_count_t nbytes = sf.read_raw(sndfile, ptr, bytes);
    lua_pushlstring(L, ptr, nbytes);
    Free(L, ptr);
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x38e3(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4470
movq %rax, %r15
movq %rbx, %rdi
movq %rax, %rsi
callq 0x41e0
movq %rax, %r12
movq 0x97f8(%rip), %rax      # 0x12fe0
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq *0x78(%rax)
movq %rbx, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x4650
movq %rbx, %rdi
movq %r12, %rsi
callq 0x43a0
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/rawreadwrite.c
// Function: WriteRaw
static int WriteRaw(lua_State *L)
    {
    size_t bytes;
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    const char *ptr = luaL_checklstring(L, 2, &bytes);
    sf_count_t nbytes = sf.write_raw(sndfile, ptr, bytes);
    lua_pushinteger(L, nbytes);
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0x3866(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
leaq 0x8(%rsp), %r15
movq %rbx, %rdi
movl $0x2, %esi
movq %r15, %rdx
callq 0x4380
movq 0x9784(%rip), %rcx      # 0x12fe0
movq (%r15), %rdx
movq %r14, %rdi
movq %rax, %rsi
callq *0x80(%rcx)
movq %rbx, %rdi
movq %rax, %rsi
callq 0x4320
movl $0x1, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/readwrite.c
// Function: Seek
static int Seek(lua_State *L)
    {
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    sf_count_t frames = luaL_checkinteger(L, 2);
    int whence = checkwhence(L, 3);
    sf_count_t offset = sf.seek(sndfile, frames, whence) ;
    if(offset == -1)
        return nil_sndfileerror(L, sndfile);
    lua_pushinteger(L, offset);
    return 1;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x37c3(%rip), %rcx      # 0xd097
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq %rax, %r14
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4470
movq %rax, %r15
movq %rbx, %rdi
movl $0x5, %esi
movl $0x3, %edx
callq 0x4130
movq 0x96d4(%rip), %rcx      # 0x12fe0
movq %r14, %rdi
movq %r15, %rsi
movl %eax, %edx
callq *0x50(%rcx)
movq %rbx, %rdi
cmpq $-0x1, %rax
je 0x9933
movq %rax, %rsi
callq 0x4320
movl $0x1, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %r14, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x4590
// File: /workspace/github_c_makefile_star2_O1/stetre[P]moonsndfile/src/readwrite.c
// Function: CurrentByterate
static int CurrentByterate(lua_State *L)
    {
    int val;
    sndfile_t sndfile = checksndfile(L, 1, NULL);
    if(!sf.current_byterate) //CheckPfn(L, current_byterate, 1,0,26);
        return 0;
    val = sf.current_byterate(sndfile);
    if(val == -1) 
        return 0; /* unknown */
    lua_pushinteger(L, val);
    return 1;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
leaq 0x3721(%rip), %rcx      # 0xd097
xorl %ebx, %ebx
movl $0x1, %esi
xorl %edx, %edx
callq 0x4400
movq 0x9655(%rip), %rcx      # 0x12fe0
movq 0x70(%rcx), %rcx
testq %rcx, %rcx
je 0x99ae
movq %rax, %rdi
callq *%rcx
cmpl $-0x1, %eax
je 0x99ae
movslq %eax, %rsi
movq %r14, %rdi
callq 0x4320
movl $0x1, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq