LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/kobolt[P]curses-collection/playlist/play.c
// Function: play_execute
void play_execute(char *arg)
{
  struct sigaction sa;
  int fd0, fd1, fd2;

  if (play_program == NULL)
    return;

  if (play_pid > 0)
    return; /* Already running, cannot execute. */

  sa.sa_handler = play_finished;
  sigemptyset(&sa.sa_mask);
  sa.sa_flags = 0;
  sigaction(SIGCHLD, &sa, NULL);

  play_pid = fork();
  if (play_pid == 0) {
    /* Redirect standard I/O to prevent child program writing to the TTY. */
    close(0);
    close(1);
    close(2);
    fd0 = open("/dev/null", O_RDWR);
    fd1 = dup(0);
    fd2 = dup(0);

    execlp(play_program, play_program, arg, NULL);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, 0x26b1(%rip)      # 0x6238
jne 0x3b8e
jmp 0x3c55
cmpl $0x0, 0x26ab(%rip)      # 0x6240
jle 0x3b9c
jmp 0x3c55
leaq 0xbd(%rip), %rax        # 0x3c60
movq %rax, -0xa0(%rbp)
leaq -0xa0(%rbp), %rdi
addq $0x8, %rdi
callq 0x2160
movl $0x0, -0x18(%rbp)
movl $0x11, %edi
leaq -0xa0(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0x2090
callq 0x22d0
movl %eax, 0x265f(%rip)      # 0x6240
cmpl $0x0, 0x2658(%rip)      # 0x6240
jne 0x3c55
xorl %edi, %edi
callq 0x2120
movl $0x1, %edi
callq 0x2120
movl $0x2, %edi
callq 0x2120
leaq 0x5c5(%rip), %rdi       # 0x41d1
movl $0x2, %esi
movb $0x0, %al
callq 0x2210
movl %eax, -0xa4(%rbp)
xorl %edi, %edi
callq 0x2100
movl %eax, -0xa8(%rbp)
xorl %edi, %edi
callq 0x2100
movl %eax, -0xac(%rbp)
movq 0x25f9(%rip), %rdi      # 0x6238
movq 0x25f2(%rip), %rsi      # 0x6238
movq -0x8(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
movb $0x0, %al
callq 0x2290
addq $0xb0, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/kobolt[P]curses-collection/playlist/play.c
// Function: play_finished
static void play_finished(int signo)
{
  int status;

  waitpid(play_pid, &status, 0);
  play_pid = 0;

  if (play_finished_handler != NULL)
    (play_finished_handler)();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
movl 0x25cf(%rip), %edi      # 0x6240
leaq -0x8(%rbp), %rsi
xorl %edx, %edx
callq 0x2200
movl $0x0, 0x25ba(%rip)      # 0x6240
cmpq $0x0, 0x25a2(%rip)      # 0x6230
je 0x3c96
callq *0x259a(%rip)           # 0x6230
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/utils/extract/extract.c
// Function: main
int
main(int argc,char **argv)
    {
    int argIndex = 1;
    char *source = 0;

    argIndex = processOptions(argc,argv);

    if (argc-argIndex == 1)
        {
        source = argv[argIndex];
        }
    else
        {
        printf("usage: %s [OPTIONS] <input wav file>\n",argv[0]);
        exit(-1);
        }

    if (TimingData)
        {
        char buffer[512];
        snprintf(buffer,sizeof(buffer)-1,"%s%d_timings",Base,TakeNumber);
        Timings = OpenFile(buffer,"w");
        printf("note timings are stored in %s\n",buffer);
        }

    Note = StartingNote;
    processData(readWave(source));
    printf("%d notes extracted.\n",Note);

    if (TimingData) fclose(Timings);

    return 0;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x220, %rsp            # imm = 0x220
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x1, -0x14(%rbp)
movq $0x0, -0x20(%rbp)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x13b0
movl %eax, -0x14(%rbp)
movl -0x8(%rbp), %eax
subl -0x14(%rbp), %eax
cmpl $0x1, %eax
jne 0x12d4
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
jmp 0x12f3
movq -0x10(%rbp), %rax
movq (%rax), %rsi
leaq 0x2df3(%rip), %rdi      # 0x40d5
movb $0x0, %al
callq 0x10a0
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x1160
cmpl $0x0, 0x5de6(%rip)      # 0x70e0
je 0x1353
leaq -0x220(%rbp), %rdi
movq 0x5dde(%rip), %rcx      # 0x70e8
movl 0x5e07(%rip), %r8d      # 0x7118
movl $0x1ff, %esi            # imm = 0x1FF
leaq 0x2dde(%rip), %rdx      # 0x40fb
movb $0x0, %al
callq 0x10b0
leaq -0x220(%rbp), %rdi
leaq 0x2dd6(%rip), %rsi      # 0x4108
callq 0x1df0
movq %rax, 0x5de2(%rip)      # 0x7120
leaq -0x220(%rbp), %rsi
leaq 0x2dbe(%rip), %rdi      # 0x410a
movb $0x0, %al
callq 0x10a0
movl 0x5dcf(%rip), %eax      # 0x7128
movl %eax, 0x5dcd(%rip)      # 0x712c
movq -0x20(%rbp), %rdi
callq 0x2b20
movq %rax, %rdi
callq 0x1740
movl 0x5db6(%rip), %esi      # 0x712c
leaq 0x2dac(%rip), %rdi      # 0x4129
movb $0x0, %al
callq 0x10a0
cmpl $0x0, 0x5d55(%rip)      # 0x70e0
je 0x1399
movq 0x5d8c(%rip), %rdi      # 0x7120
callq 0x1080
xorl %eax, %eax
addq $0x220, %rsp            # imm = 0x220
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/utils/extract/extract.c
// Function: processData
static void
processData(WAVE *w)
    {
    int i;
    int *data = w->channels[0];
    int size = w->sampleCount;

    printf("wave read.\n");

    //displayWave(w);

    //convert Gap from seconds to samples
    Gap = Gap * w->SampleRate;

    //convert Threshold from decibels to amplitude
    convertThreshold(w);

    for (i = 0; i < size; ++i)
        {
        if (data[i] > Threshold)
            {
            i -= Prelude * w->SampleRate;
            if (i < 0) i = 0;
            fprintf(Timings,"%.3f\n",i * 1.0 / w->SampleRate);
            i = extractNote(data,size,i,w);
            }
        ++i;
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x78(%rax), %eax
movl %eax, -0x1c(%rbp)
leaq 0x29da(%rip), %rdi      # 0x4143
movb $0x0, %al
callq 0x10a0
movsd 0x5978(%rip), %xmm0     # 0x70f0
movq -0x8(%rbp), %rax
cvtsi2sdl 0x38(%rax), %xmm1
mulsd %xmm1, %xmm0
movsd %xmm0, 0x5963(%rip)     # 0x70f0
movq -0x8(%rbp), %rdi
callq 0x1880
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jge 0x186d
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
cvtsi2sdl (%rax,%rcx,4), %xmm0
ucomisd 0x593a(%rip), %xmm0     # 0x70f8
jbe 0x1856
movsd 0x5934(%rip), %xmm0     # 0x7100
movq -0x8(%rbp), %rax
cvtsi2sdl 0x38(%rax), %xmm2
cvtsi2sdl -0xc(%rbp), %xmm1
movq %xmm0, %rax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
xorq %rcx, %rax
movq %rax, %xmm0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, -0xc(%rbp)
cmpl $0x0, -0xc(%rbp)
jge 0x180d
movl $0x0, -0xc(%rbp)
movq 0x590c(%rip), %rdi      # 0x7120
cvtsi2sdl -0xc(%rbp), %xmm0
movsd 0x286f(%rip), %xmm1     # 0x4090
mulsd %xmm1, %xmm0
movq -0x8(%rbp), %rax
cvtsi2sdl 0x38(%rax), %xmm1
divsd %xmm1, %xmm0
leaq 0x2916(%rip), %rsi      # 0x414f
movb $0x1, %al
callq 0x10d0
movq -0x18(%rbp), %rdi
movl -0x1c(%rbp), %esi
movl -0xc(%rbp), %edx
movq -0x8(%rbp), %rcx
callq 0x19b0
movl %eax, -0xc(%rbp)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x179d
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/utils/extract/extract.c
// Function: convertThreshold
static void
convertThreshold(WAVE *w)
    {
    int i;
    double sum;

    sum = 0;
    if (Threshold == 0.0)
        {
        for (i = 0; i + SILENCE_OFFSET < w->sampleCount && i < SILENCE_RUN; ++i)
            {
            int amp = abs(w->channels[0][SILENCE_OFFSET+i]);
            //printf("sum %d is %f (%d)\n",i+SILENCE_OFFSET,sum,amp);
            sum += amp;
            }
        Threshold = 4 * sum / SILENCE_RUN;
        }
    else
        Threshold = (pow(2,w->BitsPerSample-1)-1) * pow(10,Threshold/20);

    //printf("Threshold is %f\n",Threshold);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x18(%rbp)
movsd 0x585c(%rip), %xmm0     # 0x70f8
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x193b
jp 0x193b
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %ecx
addl $0x64, %ecx
movq -0x8(%rbp), %rdx
xorl %eax, %eax
cmpl 0x78(%rdx), %ecx
movb %al, -0x1d(%rbp)
jge 0x18d7
cmpl $0x3e8, -0xc(%rbp)      # imm = 0x3E8
setl %al
movb %al, -0x1d(%rbp)
movb -0x1d(%rbp), %al
testb $0x1, %al
jne 0x18e0
jmp 0x1918
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rax
movl -0xc(%rbp), %ecx
addl $0x64, %ecx
movslq %ecx, %rcx
movl (%rax,%rcx,4), %eax
movl %eax, %ecx
negl %ecx
cmovnsl %ecx, %eax
movl %eax, -0x1c(%rbp)
cvtsi2sdl -0x1c(%rbp), %xmm0
addsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x18(%rbp)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x18b6
movsd 0x2798(%rip), %xmm0     # 0x40b8
mulsd -0x18(%rbp), %xmm0
movsd 0x2783(%rip), %xmm1     # 0x40b0
divsd %xmm1, %xmm0
movsd %xmm0, 0x57bf(%rip)     # 0x70f8
jmp 0x199c
movq -0x8(%rbp), %rax
movl 0x44(%rax), %eax
subl $0x1, %eax
cvtsi2sd %eax, %xmm1
movsd 0x2757(%rip), %xmm0     # 0x40a8
callq 0x1070
movsd 0x2732(%rip), %xmm1     # 0x4090
subsd %xmm1, %xmm0
movsd %xmm0, -0x28(%rbp)
movsd 0x5789(%rip), %xmm1     # 0x70f8
movsd 0x2729(%rip), %xmm0     # 0x40a0
divsd %xmm0, %xmm1
movsd 0x2715(%rip), %xmm0     # 0x4098
callq 0x1070
movaps %xmm0, %xmm1
movsd -0x28(%rbp), %xmm0
mulsd %xmm1, %xmm0
movsd %xmm0, 0x575c(%rip)     # 0x70f8
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/utils/extract/extract.c
// Function: extractNote
static int
extractNote(int *data,int size,int i,WAVE *w)
    {
    int j;
    int low;
    int *phrase;
    int length = 1000;

    phrase = New(sizeof(int) * length);

    j = 0;
    low = 0;
    while (i < size)
        {
        if (j == length)
            {
            length *= 2;
            phrase = ReNew(phrase,sizeof(int) * length);
            }
        phrase[j++] = data[i++];
        if (abs(phrase[j-1]) < Threshold)
            ++low;
        else
            low = 0;
        if (low > Gap) break;
        }

    writeNote(phrase,j,w);
    free(phrase);

    return i;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq %rcx, -0x18(%rbp)
movl $0x3e8, -0x2c(%rbp)     # imm = 0x3E8
movslq -0x2c(%rbp), %rax
shlq $0x2, %rax
movl %eax, %edi
callq 0x1ef0
movq %rax, -0x28(%rbp)
movl $0x0, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
movl -0x10(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x1a9c
movl -0x1c(%rbp), %eax
cmpl -0x2c(%rbp), %eax
jne 0x1a21
movl -0x2c(%rbp), %eax
shll %eax
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rdi
movslq -0x2c(%rbp), %rax
shlq $0x2, %rax
movl %eax, %esi
callq 0x2090
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movl -0x10(%rbp), %ecx
movl %ecx, %edx
addl $0x1, %edx
movl %edx, -0x10(%rbp)
movslq %ecx, %rcx
movl (%rax,%rcx,4), %edx
movq -0x28(%rbp), %rax
movl -0x1c(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0x1c(%rbp)
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movq -0x28(%rbp), %rax
movl -0x1c(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movl (%rax,%rcx,4), %eax
movl %eax, %ecx
negl %ecx
cmovnsl %ecx, %eax
cvtsi2sd %eax, %xmm1
movsd 0x568a(%rip), %xmm0     # 0x70f8
ucomisd %xmm1, %xmm0
jbe 0x1a7f
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x1a86
movl $0x0, -0x20(%rbp)
cvtsi2sdl -0x20(%rbp), %xmm0
ucomisd 0x565d(%rip), %xmm0     # 0x70f0
jbe 0x1a97
jmp 0x1a9c
jmp 0x19ee
movq -0x28(%rbp), %rdi
movl -0x1c(%rbp), %esi
movq -0x18(%rbp), %rdx
callq 0x1ac0
movq -0x28(%rbp), %rdi
callq 0x1030
movl -0x10(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: newWave
WAVE *
newWave()
    {
    int i;
    WAVE *w = (WAVE *) New(sizeof(WAVE));

    w->ID = 0;
    w->Format = 0;
    w->Subchunk1ID = 0;
    w->Subchunk2ID = 0;
    w->ChunkSize = 0;
    w->Subchunk1Size = 0;
    w->AudioFormat = 0;
    w->NumChannels = 0;
    w->SampleRate = 0;
    w->ByteRate = 0;
    w->BlockAlign = 0;
    w->BitsPerSample = 0;
    w->Subchunk2Size = 0;
    for (i = 0; i < MAX_CHANNELS; ++i)
        w->channels[i] = 0;

    /* derived values */

    w->sampleCount = 0;
    w->sampleWidth = 0;
    w->maxAmp = 0;

    w->inName = 0;
    w->outName = 0;

    w->frequency = 440.0;
    w->amplitude = 1.0;

    w->diminishFactor = 1.0;
    w->diminishBottom = 0.0;
    w->diminishStart = 0;

    return w;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl $0xd0, %edi
callq 0x1ef0
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq $0x0, (%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x10(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x18(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x20(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x30(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x34(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x38(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x3c(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x40(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x44(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x48(%rax)
movl $0x0, -0x4(%rbp)
cmpl $0x5, -0x4(%rbp)
jge 0x2294
movq -0x10(%rbp), %rax
movslq -0x4(%rbp), %rcx
movq $0x0, 0x50(%rax,%rcx,8)
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x2272
movq -0x10(%rbp), %rax
movl $0x0, 0x78(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x7c(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x80(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x90(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0xa0(%rax)
movq -0x10(%rbp), %rax
movsd 0x22a6(%rip), %xmm0     # 0x4588
movsd %xmm0, 0xa8(%rax)
movq -0x10(%rbp), %rax
movsd 0x1d9a(%rip), %xmm0     # 0x4090
movsd %xmm0, 0xb0(%rax)
movq -0x10(%rbp), %rax
movsd 0x1d86(%rip), %xmm0     # 0x4090
movsd %xmm0, 0xb8(%rax)
movq -0x10(%rbp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, 0xc0(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0xc8(%rax)
movq -0x10(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: freeWave
void
freeWave(WAVE *w)
    {
    int i;

    free(w->ID);
    free(w->Format);
    free(w->Subchunk1ID);
    free(w->Subchunk2ID);
    free(w->inName);
    free(w->outName);
    for (i = 0; i < w->NumChannels; ++i)
        freeIntArray(w->channels[i]);

    free(w);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x90(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0xa0(%rax), %rdi
callq 0x1030
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x34(%rcx), %eax
jge 0x23cf
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq 0x50(%rax,%rcx,8), %rdi
callq 0x23e0
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x23a6
movq -0x8(%rbp), %rdi
callq 0x1030
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: cloneWave
WAVE *
cloneWave(WAVE *v)
    {
    int i;
    WAVE *w = newWave();

    w->ID = v->ID;
    w->Format = v->Format;
    w->Subchunk1ID = v->Subchunk1ID;
    w->Subchunk2ID = v->Subchunk2ID;
    w->ChunkSize = v->ChunkSize;
    w->Subchunk1Size = v->Subchunk1Size;
    w->AudioFormat = v->AudioFormat;
    w->NumChannels = v->NumChannels;
    w->SampleRate = v->SampleRate;
    w->ByteRate = v->ByteRate;
    w->BlockAlign = v->BlockAlign;
    w->BitsPerSample = v->BitsPerSample;
    w->Subchunk2Size = v->Subchunk2Size;
    for (i = 0; i < MAX_CHANNELS; ++i)
        w->channels[i] = v->channels[i];
    w->sampleCount = v->sampleCount;
    w->sampleWidth = v->sampleWidth;
    w->maxAmp = v->maxAmp;

    return w;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
callq 0x21c0
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x28(%rax)
movq -0x8(%rbp), %rax
movl 0x30(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x30(%rax)
movq -0x8(%rbp), %rax
movl 0x34(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x34(%rax)
movq -0x8(%rbp), %rax
movl 0x38(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x38(%rax)
movq -0x8(%rbp), %rax
movl 0x3c(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x3c(%rax)
movq -0x8(%rbp), %rax
movl 0x40(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x40(%rax)
movq -0x8(%rbp), %rax
movl 0x44(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x44(%rax)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x48(%rax)
movl $0x0, -0xc(%rbp)
cmpl $0x5, -0xc(%rbp)
jge 0x2549
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq 0x50(%rax,%rcx,8), %rdx
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq %rdx, 0x50(%rax,%rcx,8)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x251e
movq -0x8(%rbp), %rax
movl 0x78(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x78(%rax)
movq -0x8(%rbp), %rax
movl 0x7c(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x7c(%rax)
movq -0x8(%rbp), %rax
movl 0x80(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x80(%rax)
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: displayWave
void
displayWave(WAVE *w)
    {
    printf("ID: %s\n",w->ID);
    printf("ChunkSize: %ld\n",w->ChunkSize);
    printf("Format: %s\n",w->Format);
    printf("Subchunk1ID: %s\n",w->Subchunk1ID);
    printf("Subchunk1Size: %ld\n",w->Subchunk1Size);
    printf("AudioFormat: %d\n",w->AudioFormat);
    printf("NumChannels: %d\n",w->NumChannels);
    printf("SampleRate: %d\n",w->SampleRate);
    printf("ByteRate: %d\n",w->ByteRate);
    printf("BlockAlign: %d\n",w->BlockAlign);
    printf("BitsPerSample: %d\n",w->BitsPerSample);
    printf("Subchunk2ID: %s\n",w->Subchunk2ID);
    printf("Subchunk2Size: %ld\n",w->Subchunk2Size);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rsi
leaq 0x2013(%rip), %rdi      # 0x45bd
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rsi
leaq 0x1fd8(%rip), %rdi      # 0x4598
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rsi
leaq 0x1fd2(%rip), %rdi      # 0x45a8
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rsi
leaq 0x1fc8(%rip), %rdi      # 0x45b4
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rsi
leaq 0x1fc3(%rip), %rdi      # 0x45c5
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x30(%rax), %esi
leaq 0x1fc2(%rip), %rdi      # 0x45d9
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x34(%rax), %esi
leaq 0x1fbe(%rip), %rdi      # 0x45ea
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x38(%rax), %esi
leaq 0x1fba(%rip), %rdi      # 0x45fb
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x3c(%rax), %esi
leaq 0x1fb5(%rip), %rdi      # 0x460b
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x40(%rax), %esi
leaq 0x1fae(%rip), %rdi      # 0x4619
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movl 0x44(%rax), %esi
leaq 0x1fa9(%rip), %rdi      # 0x4629
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rsi
leaq 0x1fa6(%rip), %rdi      # 0x463c
movb $0x0, %al
callq 0x10a0
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rsi
leaq 0x1fa1(%rip), %rdi      # 0x464d
movb $0x0, %al
callq 0x10a0
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: readByteString
static char *
readByteString(FILE *in,long count,int mode)
    {
    if (mode == ALLOCATE)
        {
        char *result = (char *) New(sizeof(char) * (count + 1));

        fread(result, sizeof(char), count, in);
        result[count] = '\0';
        return result;
        }
    else
        {
        fseek(in,count+1,SEEK_CUR);
        return 0;
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
cmpl $0x1, -0x1c(%rbp)
jne 0x29dc
movq -0x18(%rbp), %rax
addq $0x1, %rax
shlq $0x0, %rax
movl %eax, %edi
callq 0x1ef0
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x10(%rbp), %rcx
movl $0x1, %esi
callq 0x1050
movq -0x28(%rbp), %rax
movq -0x18(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x29fa
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
addq $0x1, %rsi
movl $0x1, %edx
callq 0x1110
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: isID
static int
isID(FILE *in,char *id)
    {
    char ch;
    int matching = 1;
    int count = 0;
    while (matching && *id)
        {
        fread(&ch,sizeof(char),1,in);
        if (ch != *id) matching = 0;
        //fprintf(stderr,"comparing %c (%d) with %c\n",ch,ch,*id);
        ++count;
        ++id;
        }
    skip(in,-count);
    //if (matching) 
    //    fprintf(stderr,"match!\n");
    //else
    //    fprintf(stderr,"no match.\n");
    return matching;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x1, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
xorl %eax, %eax
cmpl $0x0, -0x18(%rbp)
movb %al, -0x1d(%rbp)
je 0x2a89
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x1d(%rbp)
movb -0x1d(%rbp), %al
testb $0x1, %al
jne 0x2a92
jmp 0x2ad4
movq -0x8(%rbp), %rcx
leaq -0x11(%rbp), %rdi
movl $0x1, %edx
movq %rdx, %rsi
callq 0x1050
movsbl -0x11(%rbp), %eax
movq -0x10(%rbp), %rcx
movsbl (%rcx), %ecx
cmpl %ecx, %eax
je 0x2abd
movl $0x0, -0x18(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x2a6e
movq -0x8(%rbp), %rdi
xorl %eax, %eax
subl -0x1c(%rbp), %eax
movslq %eax, %rsi
callq 0x2af0
movl -0x18(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: readWave
WAVE *
readWave(const char *fileName)
    {
    WAVE *w;

    w = readWaveFP(OpenFile(fileName,"r"));
    w->inName = StringDup(fileName);

    fprintf(stderr,"file name is %s\n",w->inName);

    return w;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
leaq 0x1b3e(%rip), %rsi      # 0x4675
callq 0x1df0
movq %rax, %rdi
callq 0x2b90
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1eb0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x90(%rax)
movq 0x4492(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x90(%rax), %rdx
leaq 0x1afc(%rip), %rsi      # 0x4677
movb $0x0, %al
callq 0x10d0
movq -0x10(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: setWaveSize
void
setWaveSize(WAVE *w,int samples)
    {
    int bytes = samples * w->NumChannels * w->BitsPerSample / 8;

    w->ChunkSize = 36+bytes;
    w->Subchunk2Size = bytes;
    w->sampleCount = samples;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
imull 0x34(%rcx), %eax
movq -0x8(%rbp), %rcx
imull 0x44(%rcx), %eax
movl $0x8, %ecx
cltd
idivl %ecx
movl %eax, -0x10(%rbp)
movl -0x10(%rbp), %eax
addl $0x24, %eax
movslq %eax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x20(%rax)
movslq -0x10(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x48(%rax)
movl -0xc(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x78(%rax)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: readWaveMono
WAVE *
readWaveMono(const char *fileName)
    {
    WAVE *w;
    w = readWaveMonoFP(OpenFile(fileName,"r"));
    w->inName = StringDup(fileName);

    fprintf(stderr,"file name is %s\n",w->inName);

    return w;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
leaq 0x18ae(%rip), %rsi      # 0x4675
callq 0x1df0
movq %rax, %rdi
callq 0x2e20
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1eb0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x90(%rax)
movq 0x4202(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x90(%rax), %rdx
leaq 0x186c(%rip), %rsi      # 0x4677
movb $0x0, %al
callq 0x10d0
movq -0x10(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: writeWaveHeader
void
writeWaveHeader(FILE *out,int rate,int channels,int bps,int samples)
    {
    writeByteString(out,"RIFF",4);

    writeByteInt(out,36 + samples * channels * (bps / 8),4);

    writeByteString(out,"WAVE",4);

    writeByteString(out,"fmt ",4);

    writeByteInt(out,16,4); //PCM subchunk

    writeByteInt(out,1,2); //PCM (no compression)

    writeByteInt(out,channels,2);  //1 for mono, 2 for stereo

    writeByteInt(out,rate,4); //sample rate

    writeByteInt(out,rate * channels * (bps / 8),4); //byte rate

    writeByteInt(out,channels * (bps / 8),2); //block align

    writeByteInt(out,bps,2); //bits per sample

    writeByteString(out,"data",4);

    writeByteInt(out,samples * channels * (bps / 8),4); //subchunk 2 size

    fprintf(stderr,"header written\n");
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movl %r8d, -0x18(%rbp)
movq -0x8(%rbp), %rdi
leaq 0x16de(%rip), %rsi      # 0x4742
movl $0x4, %edx
callq 0x31b0
movq -0x8(%rbp), %rdi
movl -0x18(%rbp), %esi
imull -0x10(%rbp), %esi
movl -0x14(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
imull %eax, %esi
addl $0x24, %esi
movl $0x4, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
leaq 0x16a8(%rip), %rsi      # 0x4747
movl $0x4, %edx
callq 0x31b0
movq -0x8(%rbp), %rdi
leaq 0x15b2(%rip), %rsi      # 0x4666
movl $0x4, %edx
callq 0x31b0
movq -0x8(%rbp), %rdi
movl $0x10, %esi
movl $0x4, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
movl $0x2, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl -0x10(%rbp), %esi
movl $0x2, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl $0x4, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
imull -0x10(%rbp), %esi
movl -0x14(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
imull %eax, %esi
movl $0x4, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl -0x10(%rbp), %esi
movl -0x14(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
imull %eax, %esi
movl $0x2, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
movl -0x14(%rbp), %esi
movl $0x2, %edx
callq 0x31e0
movq -0x8(%rbp), %rdi
leaq 0x150c(%rip), %rsi      # 0x4670
movl $0x4, %edx
callq 0x31b0
movq -0x8(%rbp), %rdi
movl -0x18(%rbp), %esi
imull -0x10(%rbp), %esi
movl -0x14(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
imull %eax, %esi
movl $0x4, %edx
callq 0x31e0
movq 0x3e60(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
leaq 0x15aa(%rip), %rsi      # 0x474c
movb $0x0, %al
callq 0x10d0
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: newDoubleArray
double *
newDoubleArray(int size)
    {
    double *a = (double *) New(sizeof(double) * (size+1));

    fprintf(stderr,"newDoubleArray: allocating %d reals at location %p\n",size,a);

    a[0] = size + 0.01;
    return a + 1;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %eax
addl $0x1, %eax
cltq
shlq $0x3, %rax
movl %eax, %edi
callq 0x1ef0
movq %rax, -0x10(%rbp)
movq 0x3b0f(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0x4(%rbp), %edx
movq -0x10(%rbp), %rcx
leaq 0x1262(%rip), %rsi      # 0x475c
movb $0x0, %al
callq 0x10d0
cvtsi2sdl -0x4(%rbp), %xmm0
movsd 0x1082(%rip), %xmm1     # 0x4590
addsd %xmm1, %xmm0
movq -0x10(%rbp), %rax
movsd %xmm0, (%rax)
movq -0x10(%rbp), %rax
addq $0x8, %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: growIntArray
int *
growIntArray(int *a)
    {
    int i;
    int *b = newIntArray(LENGTH(a) * 2);

    for (i = 0; i < LENGTH(a); ++i)
        b[i] = a[i];

    return b;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl -0x4(%rax), %edi
shll %edi
callq 0x2d10
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl -0x4(%rcx), %eax
jge 0x3582
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x3555
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: growDoubleArray
double *
growDoubleArray(double *a)
    {
    int i;
    double *b = newDoubleArray(LENGTH(a) * 2);

    for (i = 0; i < LENGTH(a); ++i)
        b[i] = a[i];

    return b;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cvttsd2si -0x8(%rax), %edi
shll %edi
callq 0x34c0
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cvttsd2si -0x8(%rcx), %ecx
cmpl %ecx, %eax
jge 0x35ec
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x35b7
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: copyIntArray
int *
copyIntArray(int *a)
    {
    int i;
    int *b = newIntArray(LENGTH(a));

    for (i = 0; i < LENGTH(a); ++i)
        b[i] = a[i];

    return b;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl -0x4(%rax), %edi
callq 0x2d10
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl -0x4(%rcx), %eax
jge 0x3650
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x3623
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pipde[P]deos-songlib/lib/wave.c
// Function: copyDoubleArray
double *
copyDoubleArray(double *a)
    {
    int i;
    double *b = newDoubleArray((int) LENGTH(a));

    for (i = 0; i < (int) LENGTH(a); ++i)
        b[i] = a[i];

    return b;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cvttsd2si -0x8(%rax), %edi
callq 0x34c0
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cvttsd2si -0x8(%rcx), %ecx
cmpl %ecx, %eax
jge 0x36ba
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x3685
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/Tarsnap[P]libcperciva/tests/optional_mutex/normal/../main.c
// Function: main
int
main(int argc, char * argv[])
{
	int counter_expected;

	WARNP_INIT;
	(void)argc; /* UNUSED */

#ifdef NUM_THREADS
	counter_expected = NUM_TIMES * NUM_THREADS;
	if (test_pthread())
		goto err0;
#else
	counter_expected = NUM_TIMES;
	inc_dec_counter(NULL);
#endif

	/* Check the counter. */
	if (check_counter(counter_expected))
		goto err0;

	/* Success! */
	exit(0);

err0:
	/* Failure! */
	exit(1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
je 0x124c
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x1480
jmp 0x124e
movl $0x64, -0x14(%rbp)
xorl %eax, %eax
movl %eax, %edi
callq 0x1280
movl -0x14(%rbp), %edi
callq 0x1370
cmpl $0x0, %eax
je 0x126d
jmp 0x1274
xorl %edi, %edi
callq 0x10f0
movl $0x1, %edi
callq 0x10f0
nop
// File: /workspace/github_c_makefile_star2_O0/Tarsnap[P]libcperciva/tests/optional_mutex/normal/../main.c
// Function: inc_dec_counter
static void *
inc_dec_counter(void * cookie)
{
	int i;
	int rc;

	(void)cookie; /* UNUSED */

	for (i = 0; i < NUM_TIMES; i++) {
		/* Lock if we're using pthread. */
		if ((rc = optional_mutex_lock(&mutex)) != 0) {
			warn0("optional_mutex_lock: %s", strerror(rc));
			goto err0;
		}

		/* Increment, wait, decrement value. */
		value++;
		millisleep(10);
		value--;

		/* Increment overall counter. */
		counter++;

		/* Unlock if we're using pthread. */
		if ((rc = optional_mutex_unlock(&mutex)) != 0) {
			warn0("optional_mutex_unlock: %s", strerror(rc));
			goto err0;
		}
	}

	/* Success! */
	return (NULL);

err0:
	/* Failure! */
	pthread_exit(NULL);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
cmpl $0x64, -0xc(%rbp)
jge 0x135f
leaq 0x2e0c(%rip), %rdi      # 0x40b0
callq 0x19d0
movl %eax, -0x10(%rbp)
cmpl $0x0, %eax
je 0x12dc
jmp 0x12b3
movl -0x10(%rbp), %edi
callq 0x1110
movq %rax, %rsi
leaq 0xd3f(%rip), %rdi       # 0x2004
movb $0x0, %al
callq 0x1790
callq 0x1060
movl $0x0, (%rax)
jmp 0x1367
movl 0x2df6(%rip), %eax      # 0x40d8
addl $0x1, %eax
movl %eax, 0x2ded(%rip)      # 0x40d8
movl $0xa, %edi
callq 0x1430
movl 0x2ddd(%rip), %eax      # 0x40d8
addl $-0x1, %eax
movl %eax, 0x2dd4(%rip)      # 0x40d8
movl 0x2dd2(%rip), %eax      # 0x40dc
addl $0x1, %eax
movl %eax, 0x2dc9(%rip)      # 0x40dc
leaq 0x2d96(%rip), %rdi      # 0x40b0
callq 0x19e0
movl %eax, -0x10(%rbp)
cmpl $0x0, %eax
je 0x134f
jmp 0x1329
movl -0x10(%rbp), %edi
callq 0x1110
movq %rax, %rsi
leaq 0xce1(%rip), %rdi       # 0x201c
movb $0x0, %al
callq 0x1790
callq 0x1060
movl $0x0, (%rax)
jmp 0x1367
jmp 0x1351
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1293
xorl %eax, %eax
addq $0x10, %rsp
popq %rbp
retq
xorl %eax, %eax
movl %eax, %edi
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O0/Tarsnap[P]libcperciva/tests/optional_mutex/normal/../main.c
// Function: check_counter
static int
check_counter(int counter_expected)
{
	int rc, match;

	/* Lock if we're using pthread. */
	if ((rc = optional_mutex_lock(&mutex)) != 0) {
		warn0("optional_mutex_lock: %s", strerror(rc));
		goto err0;
	}

	/* Check the value and counter. */
	if ((value == 0) && (counter == counter_expected))
		match = 0;
	else
		match = 1;

	/* Unlock if we're using pthread. */
	if ((rc = optional_mutex_unlock(&mutex)) != 0) {
		warn0("optional_mutex_unlock: %s", strerror(rc));
		goto err0;
	}

	/* Success! */
	return (match);

err0:
	/* Failure! */
	return (-1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x8(%rbp)
leaq 0x2d2e(%rip), %rdi      # 0x40b0
callq 0x19d0
movl %eax, -0xc(%rbp)
cmpl $0x0, %eax
je 0x13b7
jmp 0x1391
movl -0xc(%rbp), %edi
callq 0x1110
movq %rax, %rsi
leaq 0xc61(%rip), %rdi       # 0x2004
movb $0x0, %al
callq 0x1790
callq 0x1060
movl $0x0, (%rax)
jmp 0x141f
cmpl $0x0, 0x2d1a(%rip)      # 0x40d8
jne 0x13d4
movl 0x2d16(%rip), %eax      # 0x40dc
cmpl -0x8(%rbp), %eax
jne 0x13d4
movl $0x0, -0x10(%rbp)
jmp 0x13db
movl $0x1, -0x10(%rbp)
leaq 0x2cce(%rip), %rdi      # 0x40b0
callq 0x19e0
movl %eax, -0xc(%rbp)
cmpl $0x0, %eax
je 0x1417
jmp 0x13f1
movl -0xc(%rbp), %edi
callq 0x1110
movq %rax, %rsi
leaq 0xc19(%rip), %rdi       # 0x201c
movb $0x0, %al
callq 0x1790
callq 0x1060
movl $0x0, (%rax)
jmp 0x141f
movl -0x10(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x1426
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: ctx_init
static void ctx_init(es_ctx_t* ctx, size_t heap_size)
{
  heap_init(&ctx->heap, heap_size);
  ctx->roots.top = 0;
  ctx->iport = es_void;
  ctx->oport = es_void;
  ctx->sp = ctx->stack;
  ctx->fp = 0;
  ctx->bytecode = es_make_bytecode(ctx);
  symtab_init(&ctx->symtab);
  es_symbol_intern(ctx, "define");
  es_symbol_intern(ctx, "if");
  es_symbol_intern(ctx, "begin");
  es_symbol_intern(ctx, "set!");
  es_symbol_intern(ctx, "lambda");
  es_symbol_intern(ctx, "quote");
  es_symbol_intern(ctx, "quasiquote");
  es_symbol_intern(ctx, "unquote");
  es_symbol_intern(ctx, "unquote-splicing");

  ctx_init_env(ctx);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x5d80
movq -0x8(%rbp), %rax
movl $0x0, 0x2040(%rax)
movq -0x8(%rbp), %rax
movq $0x5b, 0x42050(%rax)
movq -0x8(%rbp), %rax
movq $0x5b, 0x42058(%rax)
movq -0x8(%rbp), %rcx
addq $0x42090, %rcx          # imm = 0x42090
movq -0x8(%rbp), %rax
movq %rcx, 0x42070(%rax)
movq -0x8(%rbp), %rax
movl $0x0, 0x42078(%rax)
movq -0x8(%rbp), %rdi
callq 0x38e0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x42060(%rax)
movq -0x8(%rbp), %rdi
addq $0x2048, %rdi           # imm = 0x2048
callq 0x5e60
movq -0x8(%rbp), %rdi
leaq 0x8f9f(%rip), %rsi      # 0xa30e
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f96(%rip), %rsi      # 0xa315
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f89(%rip), %rsi      # 0xa318
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f7f(%rip), %rsi      # 0xa31e
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f74(%rip), %rsi      # 0xa323
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f70(%rip), %rsi      # 0xa32f
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f5b(%rip), %rsi      # 0xa32a
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f56(%rip), %rsi      # 0xa335
callq 0x2ea0
movq -0x8(%rbp), %rdi
leaq 0x8f4e(%rip), %rsi      # 0xa33d
callq 0x2ea0
movq -0x8(%rbp), %rdi
callq 0x5e90
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_type_of
es_type_t es_type_of(es_val_t val)
{
  switch(es_tag(val)) {
  case ES_OBJ_TAG:    return obj_type_of(val);
  case ES_VALUE_TAG:  return es_payload(es_type_t, val);
  case ES_BOOL_TAG:   return ES_BOOL_TYPE;
  case ES_FIXNUM_TAG: return ES_FIXNUM_TYPE;
  case ES_SYMBOL_TAG: return ES_SYMBOL_TYPE;
  case ES_CHAR_TAG:   return ES_CHAR_TYPE;
  default:            return ES_INVALID_TYPE;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
andl $0x7, %eax
movq %rax, -0x18(%rbp)
subq $0x5, %rax
ja 0x15cf
movq -0x18(%rbp), %rax
leaq 0x8a80(%rip), %rcx      # 0xa008
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rdi
callq 0x15e0
movl %eax, -0x4(%rbp)
jmp 0x15d6
movq -0x10(%rbp), %rax
sarl $0x3, %eax
movl %eax, -0x4(%rbp)
jmp 0x15d6
movl $0x1, -0x4(%rbp)
jmp 0x15d6
movl $0x2, -0x4(%rbp)
jmp 0x15d6
movl $0x3, -0x4(%rbp)
jmp 0x15d6
movl $0x4, -0x4(%rbp)
jmp 0x15d6
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_port_vprintf
es_val_t es_port_vprintf(es_ctx_t* ctx, es_val_t port, const char* fmt, va_list args)
{
  if (!fmt || *fmt == '\0') {
    return es_void;
  }

  es_port_t* p = es_port_val(port);
  char buf[1024];
  char* loc = strstr(fmt, "%@");

  if (loc) {
    strncpy(buf, fmt, loc - fmt);
    buf[loc - fmt] = '\0';
    if (*buf != '\0') {
      vfprintf(p->stream, buf, args);
    }
    es_val_t val = va_arg(args, es_val_t);
    es_port_write(ctx, port, val);
    es_port_vprintf(ctx, port, loc + 2, args);
    return es_void;
  } else {
    vfprintf(p->stream, fmt, args);
    return es_void;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x460, %rsp            # imm = 0x460
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x16ce
movq -0x20(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0x16db
movq $0x5b, -0x8(%rbp)
jmp 0x1824
movq -0x18(%rbp), %rdi
callq 0x24f0
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rdi
leaq 0x8e93(%rip), %rsi      # 0xa586
callq 0x1170
movq %rax, -0x438(%rbp)
cmpq $0x0, -0x438(%rbp)
je 0x1807
leaq -0x430(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x438(%rbp), %rdx
movq -0x20(%rbp), %rax
subq %rax, %rdx
callq 0x1040
movq -0x438(%rbp), %rax
movq -0x20(%rbp), %rcx
subq %rcx, %rax
movb $0x0, -0x430(%rbp,%rax)
movsbl -0x430(%rbp), %eax
cmpl $0x0, %eax
je 0x1765
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rdi
leaq -0x430(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0x1120
movq -0x28(%rbp), %rax
movq %rax, -0x450(%rbp)
movl (%rax), %eax
movl %eax, -0x444(%rbp)
cmpl $0x28, %eax
ja 0x179f
movq -0x450(%rbp), %rcx
movl -0x444(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x458(%rbp)
jmp 0x17bc
movq -0x450(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x458(%rbp)
movq -0x458(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x440(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x440(%rbp), %rdx
callq 0x1870
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x438(%rbp), %rdx
addq $0x2, %rdx
movq -0x28(%rbp), %rcx
callq 0x16a0
movq $0x5b, -0x8(%rbp)
jmp 0x1824
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0x1120
movq $0x5b, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x460, %rsp            # imm = 0x460
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_make_char_cstr
es_val_t es_make_char_cstr(char* buf)
{
  if (strcmp("space", buf) == 0) {
    return es_make_char(' ');
  } else if (strcmp("newline", buf) == 0) {
    return es_make_char('\n');
  } else if (strcmp("tab", buf) == 0) {
    return es_make_char('\t');
  } else {
    return es_make_char(*buf);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rsi
leaq 0x8a96(%rip), %rdi      # 0xa55d
callq 0x10d0
cmpl $0x0, %eax
jne 0x1ae1
movl $0x20, %edi
callq 0x1a70
movq %rax, -0x8(%rbp)
jmp 0x1b3b
movq -0x10(%rbp), %rsi
leaq 0x8a79(%rip), %rdi      # 0xa565
callq 0x10d0
cmpl $0x0, %eax
jne 0x1b06
movl $0xa, %edi
callq 0x1a70
movq %rax, -0x8(%rbp)
jmp 0x1b3b
movq -0x10(%rbp), %rsi
leaq 0x8a5e(%rip), %rdi      # 0xa56f
callq 0x10d0
cmpl $0x0, %eax
jne 0x1b2b
movl $0x9, %edi
callq 0x1a70
movq %rax, -0x8(%rbp)
jmp 0x1b3b
movq -0x10(%rbp), %rax
movsbl (%rax), %edi
callq 0x1a70
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_alloc
static void* es_alloc(es_ctx_t* ctx, es_type_t type, size_t size)
{
  void* mem = heap_alloc(&ctx->heap, size);

  if (!mem) {
    es_gc(ctx);
    mem = heap_alloc(&ctx->heap, size);
    if (!mem) {
      exit(1);
    }
  }

  obj_init(es_obj_to_val(mem), type);
  return mem;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x70e0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x1c28
movq -0x8(%rbp), %rdi
callq 0x3d60
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x70e0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x1c26
movl $0x1, %edi
callq 0x1150
jmp 0x1c28
movq -0x20(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x7150
movq -0x20(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_make_pair
es_val_t es_make_pair(es_ctx_t* ctx, es_val_t head, es_val_t tail)
{
  es_pair_t* pair;
  gc_root2(ctx, head, tail);
  pair = es_alloc(ctx, ES_PAIR_TYPE, sizeof(es_pair_t));
  pair->head = head;
  pair->tail = tail;
  gc_unroot(ctx, 2);
  return es_obj_to_val(pair);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq -0x8(%rbp), %rdx
movl 0x2040(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0x2040(%rdx)
movslq %ecx, %rcx
leaq -0x10(%rbp), %rdx
movq %rdx, 0x40(%rax,%rcx,8)
movq -0x8(%rbp), %rax
movq -0x8(%rbp), %rdx
movl 0x2040(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0x2040(%rdx)
movslq %ecx, %rcx
leaq -0x18(%rbp), %rdx
movq %rdx, 0x40(%rax,%rcx,8)
movq -0x8(%rbp), %rdi
movl $0x6, %esi
movl $0x20, %edx
callq 0x1bd0
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rbp), %rax
movl 0x2040(%rax), %ecx
subl $0x2, %ecx
movl %ecx, 0x2040(%rax)
movq -0x20(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pedro-onate[P]eva/eva.c
// Function: es_make_port
es_val_t es_make_port(es_ctx_t* ctx, FILE* stream)
{
  es_port_t* port = es_alloc(ctx, ES_PORT_TYPE, sizeof(es_port_t));
  port->stream = stream;
  port->eof    = 0;
  port->top    = 0;
  port->tail   = 0;
  port->cur    = 0;
  port->nbytes = 0;
  port->linum  = 0;
  port->colnum = 0;
  port->size   = 65536;
  port->buf    = malloc(port->size);
  return es_obj_to_val(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movl $0xc, %esi
movl $0x1848, %edx           # imm = 0x1848
callq 0x1bd0
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x2c(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x40(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x28(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x24(%rax)
movq -0x18(%rbp), %rax
movq $0x0, 0x30(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x38(%rax)
movq -0x18(%rbp), %rax
movl $0x0, 0x3c(%rax)
movq -0x18(%rbp), %rax
movl $0x10000, 0x20(%rax)    # imm = 0x10000
movq -0x18(%rbp), %rax
movslq 0x20(%rax), %rdi
callq 0x10f0
movq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nop