LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: rest
void
rest(double beats)
    {
    if (style == SWING && swingBeat == beats)
        {
        if (swingDown) beats = beats * 4 / 3;
        else beats = beats *2 / 3;
        swingDown = !swingDown;
        }

    forwards(beats);
    }

// Assembly:
cmpl $0x1, 0xa14a(%rip)      # 0xf544
jne 0x543b
movsd 0xa008(%rip), %xmm1     # 0xf410
ucomisd %xmm0, %xmm1
jne 0x5436
jp 0x5436
xorl %eax, %eax
cmpl $0x0, 0x9fff(%rip)      # 0xf418
sete %al
leaq 0x4edd(%rip), %rcx      # 0xa300
mulsd (%rcx,%rax,8), %xmm0
divsd 0x4e58(%rip), %xmm0     # 0xa288
movl %eax, 0x9fe2(%rip)      # 0xf418
jmp 0x543b
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: endCrescendo
void
endCrescendo()
    {
    int i = 0;
    double amp,delta;

    if (crescendoStart < 0 || crescendoStart == sustainedLocation)
        Fatal ("Rewound before crescendo");

    if (crescendoMode == EXPONENTIAL)
        delta = pow(crescendoFactor,1.0 / (sustainedLocation - crescendoStart));
    else
        delta = (crescendoFactor - 1.0) / (sustainedLocation - crescendoStart);

    amp = getAmplitude();

    for (i = crescendoStart; i < sustainedLocation; ++i)
        {
        output->data[0][i] *= amp;
        if (crescendoMode == EXPONENTIAL)
            amp *= delta;
        else
            amp += delta;
        }

    crescendoStart = -1;
    amplitude = getAmplitude() * crescendoFactor;
    crescendoFactor = 1;
    }

// Assembly:
pushq %rax
movl 0x9f5d(%rip), %eax      # 0xf4a0
testl %eax, %eax
js 0x554f
cmpl 0x19b1b(%rip), %eax     # 0x1f068
jne 0x555d
leaq 0x4f8a(%rip), %rdi      # 0xa4e0
xorl %eax, %eax
callq 0x6cc0
cmpl $0x1, 0x19b0c(%rip)     # 0x1f070
movsd 0x9f14(%rip), %xmm0     # 0xf480
jne 0x559d
movl 0x19af4(%rip), %eax     # 0x1f068
subl 0x9f26(%rip), %eax      # 0xf4a0
cvtsi2sd %eax, %xmm2
movsd 0x4cda(%rip), %xmm1     # 0xa260
divsd %xmm2, %xmm1
callq 0x20b0
movl 0x9f0b(%rip), %edx      # 0xf4a0
movl 0x19acd(%rip), %esi     # 0x1f068
jmp 0x55bd
addsd 0x4d0b(%rip), %xmm0     # 0xa2b0
movl 0x19abd(%rip), %esi     # 0x1f068
movl 0x9eef(%rip), %edx      # 0xf4a0
movl %esi, %eax
subl %edx, %eax
cvtsi2sd %eax, %xmm1
divsd %xmm1, %xmm0
movsd 0x9ea3(%rip), %xmm1     # 0xf468
cmpl %esi, %edx
jge 0x5611
movq 0x19730(%rip), %rax     # 0x1ed00
movq 0x18(%rax), %rax
movq (%rax), %rax
movl 0x19a93(%rip), %ecx     # 0x1f070
movslq %edx, %rdx
movslq %esi, %rsi
movapd %xmm1, %xmm2
xorps %xmm3, %xmm3
cvtsi2sdl (%rax,%rdx,4), %xmm3
mulsd %xmm2, %xmm3
cvttsd2si %xmm3, %edi
movl %edi, (%rax,%rdx,4)
cmpl $0x1, %ecx
je 0x5605
addsd %xmm0, %xmm2
jmp 0x5609
mulsd %xmm0, %xmm2
incq %rdx
cmpq %rdx, %rsi
jne 0x55e7
mulsd 0x9e67(%rip), %xmm1     # 0xf480
movl $0xffffffff, 0x9e7d(%rip) # imm = 0xFFFFFFFF
movsd %xmm1, 0x9e3d(%rip)     # 0xf468
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x9e44(%rip)      # 0xf480
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: interp1
int
interp1(int *data,int length,double t)
    {
    int lo = (int) t;
    int hi = lo + 1;
    double fraction;
    double result;

    if (lo >= length-1) return data[length-1];

    fraction = t - lo;

    result = data[lo] + fraction * (data[hi] - data[lo]);

    return (int) result;
    }

// Assembly:
cvttsd2si %xmm0, %eax
decl %esi
cmpl %eax, %esi
jle 0x57a4
cvtsi2sd %eax, %xmm1
subsd %xmm1, %xmm0
cltq
movl (%rdi,%rax,4), %ecx
xorps %xmm1, %xmm1
cvtsi2sd %ecx, %xmm1
movl 0x4(%rdi,%rax,4), %eax
subl %ecx, %eax
cvtsi2sd %eax, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm1, %xmm2
cvttsd2si %xmm2, %eax
retq
movslq %esi, %rax
movl (%rdi,%rax,4), %eax
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: interp3
int
interp3(int *data,int length,double t)
    {
    int x;
    double mu,mu2;
    int y0,y1,y2,y3;
    int a0,a1,a2,a3;

    if (t >= length) return data[length - 1];

    x = (int) t;
    mu = t - x;
    mu2 = mu * mu;

    y1 = data[x];
    if (x == 0)
        {
        y2 = data[x + 1];
        y3 = data[x + 2];
        y0 = y1 + y1 - y2;
        }
    else if (x == length - 2)
        {
        y0 = data[x - 1];
        y2 = data[x + 1];
        y3 = y2 + y2 - y1;
        }
    else if (x == length - 1)
        {
        y0 = data[x - 1];
        y2 = y1 + y1 - y0;
        y3 = y2 + y2 - y1;
        }
    else
        {
        y0 = data[x - 1];
        y2 = data[x + 1];
        y3 = data[x + 2];
        }
        
    a0 = y3 - y2 - y0 + y1;
    a1 = y0 - y1 - a0;
    a2 = y2 - y0;
    a3 = y1;

    return (int) (a0*mu*mu2+a1*mu2+a2*mu+a3);
    }

// Assembly:
cvtsi2sd %esi, %xmm1
ucomisd %xmm1, %xmm0
jae 0x57ec
cvttsd2si %xmm0, %ecx
cvttpd2dq %xmm0, %xmm1
cvtdq2pd %xmm1, %xmm1
subsd %xmm1, %xmm0
movapd %xmm0, %xmm1
mulsd %xmm0, %xmm1
movslq %ecx, %r8
movl (%rdi,%r8,4), %eax
testl %r8d, %r8d
je 0x57f4
leal -0x2(%rsi), %edx
cmpl %ecx, %edx
jne 0x5801
movl -0x4(%rdi,%r8,4), %edx
movl 0x4(%rdi,%r8,4), %ecx
jmp 0x5811
movslq %esi, %rax
movl -0x4(%rdi,%rax,4), %eax
retq
movl 0x4(%rdi), %ecx
movl 0x8(%rdi), %esi
leal (%rax,%rax), %edx
subl %ecx, %edx
jmp 0x5822
decl %esi
movl -0x4(%rdi,%r8,4), %edx
cmpl %ecx, %esi
jne 0x5818
leal (%rax,%rax), %ecx
subl %edx, %ecx
leal (%rcx,%rcx), %esi
subl %eax, %esi
jmp 0x5822
movl 0x4(%rdi,%r8,4), %ecx
movl 0x8(%rdi,%r8,4), %esi
addl %eax, %esi
subl %ecx, %esi
subl %edx, %esi
subl %edx, %ecx
cvtsi2sd %esi, %xmm2
subl %eax, %edx
subl %esi, %edx
mulsd %xmm0, %xmm2
cvtsi2sd %edx, %xmm3
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm2
xorps %xmm1, %xmm1
cvtsi2sd %ecx, %xmm1
addsd %xmm3, %xmm2
mulsd %xmm0, %xmm1
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
addsd %xmm2, %xmm1
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: setStyle
void
setStyle(char *mode,double info)
    {
    if (strcasecmp(mode,"SWING") == 0)
        {
        style = SWING;
        swingBeat = info;
        swingDown = 1;
        }
    else if (strcasecmp(mode,"PLAIN") == 0)
        style = PLAIN;
    else
        Fatal("Style %s not understood\n",mode);
    }

// Assembly:
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, 0x8(%rsp)
movq %rdi, %rbx
leaq 0x46cc(%rip), %rsi      # 0xa4fe
callq 0x2050
testl %eax, %eax
je 0x5e64
leaq 0x46c2(%rip), %rsi      # 0xa504
movq %rbx, %rdi
callq 0x2050
testl %eax, %eax
je 0x5e85
leaq 0x46b5(%rip), %rdi      # 0xa50a
movq %rbx, %rsi
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
jmp 0x6cc0
movl $0x1, %eax
movl %eax, 0x96d5(%rip)      # 0xf544
movsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x9593(%rip)     # 0xf410
movl %eax, 0x9595(%rip)      # 0xf418
jmp 0x5e8f
movl $0x0, 0x96b5(%rip)      # 0xf544
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: getSample
static RRA *
getSample(SAMPLE_SET *ss,bool random)
{
    if (!ss) return 0;
    
    // Get random sample if requested and if multiple available
    if (random && ss->count > 1) return ss->samples[rand()%(ss->count)];
    
    // Otherwise, if samples exist, use the first
    if (ss->count > 0) return ss->samples[0];

    // No samples found
    return 0;
}

// Assembly:
testq %rdi, %rdi
je 0x5fa6
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0x8(%rdi), %eax
cmpl $0x2, %eax
setge %cl
andb %sil, %cl
cmpb $0x1, %cl
jne 0x5fa9
movq (%rbx), %r14
callq 0x2300
cltd
idivl 0x8(%rbx)
movslq %edx, %rax
leaq (%r14,%rax,8), %rax
jmp 0x5fb0
xorl %eax, %eax
retq
testl %eax, %eax
jle 0x5fbb
movq (%rbx), %rax
movq (%rax), %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
xorl %eax, %eax
jmp 0x5fb3
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: resample
RRA *
resample(RRA *note,double factor)
    {
    int i;
    double t;
    RRA *h;

    //printf("in resample...\n");

    h = newRRA(note->sampleRate,note->bitsPerSample,1,note->samples);

    dDebug("dresample: samples in original note is %d\n",length);
    dDebug("dresample: factor is %f\n",factor);
    //printf("samples in original note is %d\n",note->samples);
    //printf("factor is %f\n",factor);

    i = 0;
    t = 0;
    while (t < note->samples)
        {
        if (i >= h->samples)
            {
            //printf("%d samples\n",h->samples);
            //printf("t is %f\n",t);
            growRRA(h);
            }

        h->data[0][i] = interp(note->data[0],note->samples,t);
        t += factor;
        ++i;
        }

    /* remove the excess capacity in the rra object */

    shrinkRRA(h,i);

    dDebug("leaving\n");

    return h;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, 0x8(%rsp)
movq %rdi, %r14
movl 0x4(%rdi), %edi
movl 0x8(%r14), %esi
movl 0xc(%r14), %ecx
movl $0x1, %edx
callq 0x6f2c
movq %rax, %rbx
movl 0xc(%r14), %esi
testl %esi, %esi
jle 0x611d
xorps %xmm0, %xmm0
xorl %r15d, %r15d
movslq 0xc(%rbx), %rax
cmpq %rax, %r15
movsd %xmm0, (%rsp)
jl 0x60d4
movq %rbx, %rdi
callq 0x7daa
movl 0xc(%r14), %esi
movq 0x18(%r14), %rax
movq (%rax), %rdi
movsd (%rsp), %xmm0
callq *0x18c0a(%rip)          # 0x1ecf0
movq 0x18(%rbx), %rcx
movq (%rcx), %rcx
movl %eax, (%rcx,%r15,4)
movsd (%rsp), %xmm0
addsd 0x8(%rsp), %xmm0
movsd %xmm0, (%rsp)
incq %r15
movl 0xc(%r14), %esi
xorps %xmm0, %xmm0
cvtsi2sd %esi, %xmm0
ucomisd (%rsp), %xmm0
movsd (%rsp), %xmm0
ja 0x60ba
jmp 0x6120
xorl %r15d, %r15d
movq %rbx, %rdi
movl %r15d, %esi
callq 0x7db4
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: measure
void
measure(const char *file,const char *function,const int line)
    {
    static int last = 0;

    if (file == 0)
        {
        last = location;
        //printf("location is %d\n",last);
        //printf("last is %f\n",samplesToBeats(last));
        //getchar();
        }
    else
        {
        int span = location - last;
        //printf("span is %d\n",span);
        printf("!%s: %s: %4d: %f measures (%f total)\n",
                file,function,line,samplesToMeasures(span),
                samplesToMeasures(location - spaces - measuredLocation)
		    + previousMeasures);
        }
    }

// Assembly:
movsd 0x18b48(%rip), %xmm1    # 0x1ed08
testq %rdi, %rdi
je 0x6256
movl %edx, %ecx
movq %rsi, %rdx
movq %rdi, %rsi
cvtsi2sdl 0x18ecb(%rip), %xmm0 # 0x1f0a4
movapd %xmm1, %xmm2
subsd %xmm0, %xmm2
cvttpd2dq %xmm2, %xmm0
cvtdq2pd %xmm0, %xmm0
xorps %xmm2, %xmm2
cvtsi2sdl 0x923c(%rip), %xmm2 # 0xf430
divsd %xmm2, %xmm0
movsd 0x4080(%rip), %xmm3     # 0xa280
divsd %xmm3, %xmm0
movsd 0x92a4(%rip), %xmm4     # 0xf4b0
mulsd %xmm4, %xmm0
cvtsi2sdl 0x9238(%rip), %xmm5 # 0xf450
subsd 0x18e38(%rip), %xmm1    # 0x1f058
cvtsi2sdl 0x18e54(%rip), %xmm6 # 0x1f07c
divsd %xmm5, %xmm0
subsd %xmm6, %xmm1
divsd %xmm2, %xmm1
divsd %xmm3, %xmm1
mulsd %xmm4, %xmm1
divsd %xmm5, %xmm1
addsd 0x18e38(%rip), %xmm1    # 0x1f080
leaq 0x42f9(%rip), %rdi      # 0xa548
movb $0x2, %al
jmp 0x20f0
cvttsd2si %xmm1, %eax
movl %eax, 0x18e44(%rip)     # 0x1f0a4
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: addComment
void
addComment(char *drumComment)
    {
    COMMENT *temp, *temp1;
    int commentSamples = getLocation();
    commentBuffer = (COMMENT *)New(sizeof(COMMENT));

    if(tail == NULL)
        {
        head = commentBuffer;
        tail = commentBuffer;
        commentBuffer->location = commentSamples;
        strcpy(commentBuffer->comment,drumComment);
        return;
        }

    if(commentSamples > tail->location) 
	{
	tail->next = commentBuffer;
	commentBuffer->location = commentSamples;
	strcpy(commentBuffer->comment,drumComment);
	//fprintf(stderr,"%s at %d \n",commentBuffer->comment, commentBuffer->location);
	commentBuffer->next = NULL;
	tail = commentBuffer;
	}
    else /* insert in between */
	{
	/* check from head to current
	 * tail, the most suitable
	 * location to place the comment */

	temp1 = (COMMENT *)New(sizeof(COMMENT));
	temp1->location = 0;

	temp = head;
	while(temp != tail)
	    {
	    if(temp->location > commentSamples)
		{
		temp1->next = temp->next;		
		temp->next = commentBuffer;
		commentBuffer->location = commentSamples;
		strcpy(commentBuffer->comment,drumComment);
		fprintf(stderr,"%s at %f \n",commentBuffer->comment, commentBuffer->location);
		commentBuffer->next = temp1->next;
		break;
		}
	    temp = temp->next;	    
	    }
	}
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cvttsd2si 0x18a5b(%rip), %ebp # 0x1ed08
movl $0x210, %edi            # imm = 0x210
callq 0x6ddf
movq %rax, %r14
movq %rax, 0x18de7(%rip)     # 0x1f0a8
movq 0x18de8(%rip), %rax     # 0x1f0b0
testq %rax, %rax
je 0x6306
cvtsi2sd %ebp, %xmm0
ucomisd (%rax), %xmm0
jbe 0x6336
movq %r14, 0x208(%rax)
movsd %xmm0, (%r14)
movq %r14, %rdi
addq $0x8, %rdi
movq %rbx, %rsi
callq 0x2080
movq $0x0, 0x208(%r14)
movq %r14, 0x18dac(%rip)     # 0x1f0b0
jmp 0x6380
movq %r14, 0x18dab(%rip)     # 0x1f0b8
movq %r14, 0x18d9c(%rip)     # 0x1f0b0
cvtsi2sd %ebp, %xmm0
movsd %xmm0, (%r14)
addq $0x8, %r14
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x2080
movl $0x210, %edi            # imm = 0x210
movsd %xmm0, (%rsp)
callq 0x6ddf
movsd (%rsp), %xmm1
movq %rax, %r14
movq $0x0, (%rax)
movq 0x18d55(%rip), %rax     # 0x1f0b0
movq 0x18d56(%rip), %rcx     # 0x1f0b8
cmpq %rax, %rcx
je 0x6380
movsd (%rcx), %xmm0
ucomisd %xmm1, %xmm0
movq 0x208(%rcx), %rdx
ja 0x638b
movq %rdx, %rcx
cmpq %rax, %rdx
jne 0x6367
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rdx, 0x208(%r14)
movq 0x18d0f(%rip), %r15     # 0x1f0a8
movq %r15, 0x208(%rcx)
movsd %xmm1, (%r15)
addq $0x8, %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2080
movq 0x8c3d(%rip), %rax      # 0xeff8
movq (%rax), %rdi
leaq 0x41a9(%rip), %rsi      # 0xa56e
movq %r15, %rdx
movsd (%rsp), %xmm0
movb $0x1, %al
callq 0x21d0
movq 0x208(%r14), %rax
movq 0x18cc6(%rip), %rcx     # 0x1f0a8
movq %rax, 0x208(%rcx)
jmp 0x6380
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: closeComments
void 
closeComments()    
    {
    COMMENT *temp;
    temp = head;

    while(temp)
	{
	head = temp->next;
	free(temp);
	temp = head;
	}
    }

// Assembly:
movq 0x18cc6(%rip), %rdi     # 0x1f0b8
testq %rdi, %rdi
je 0x6414
pushq %rbx
movq 0x208(%rdi), %rbx
movq %rbx, 0x18cb2(%rip)     # 0x1f0b8
callq 0x2040
movq %rbx, %rdi
testq %rbx, %rbx
jne 0x63f8
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/songlib.c
// Function: addSampleToSampleSet
static SAMPLE_SET *
addSampleToSampleSet(RRA *h, SAMPLE_SET *ss)
    {
    int i;
    RRA **oldSamples = ss->samples;
    ss->samples = (RRA **) New(sizeof(RRA *) * (ss->count+1));
    for (i=0;i<ss->count;++i)
        {
        ss->samples[i] = oldSamples[i];
        }
    ss->samples[ss->count] = h;
    ++(ss->count);
    return ss;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq (%rsi), %r15
movl 0x8(%rsi), %eax
leal 0x8(,%rax,8), %edi
callq 0x6ddf
movq %rax, (%rbx)
movslq 0x8(%rbx), %rcx
testq %rcx, %rcx
jle 0x68ce
xorl %eax, %eax
movq (%r15,%rax,8), %rdx
movq (%rbx), %rsi
movq %rdx, (%rsi,%rax,8)
incq %rax
cmpq %rax, %rcx
jne 0x68b8
movq (%rbx), %rax
movq %r14, (%rax,%rcx,8)
leal 0x1(%rcx), %eax
movl %eax, 0x8(%rbx)
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newDelay
delay *
newDelay(int delta)
    {
    int i;
    delay *d = New(sizeof(delay));
    d->index = 0;
    d->length = delta;
    d->store = New(sizeof(int) * delta);
    for (i = 0; i < delta; ++i) d->store[i] = 0;
    return d;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %r14d
movl $0x10, %edi
callq 0x6ddf
movq %rax, %rbx
movl $0x0, (%rax)
movl %r14d, 0x4(%rax)
leal (,%r14,4), %edi
callq 0x6ddf
movq %rax, 0x8(%rbx)
testl %r14d, %r14d
jle 0x8665
movl %r14d, %edx
shlq $0x2, %rdx
movq %rax, %rdi
xorl %esi, %esi
callq 0x2130
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newFOF
fof *
newFOF(double freq,int style)
    {
    double theta,gamma;
    fof *f;
    
    f = New(sizeof(fof));

    f->freq = freq;
    theta = 2 * M_PI * freq / SampleRate;
    if (style == LOWPASS)
        {
        gamma = 2 - cos(theta);
        f->b1 = pow(gamma * gamma - 1,0.5) - gamma;
        f->a0 = 1 + f->b1;
        }
    else
        {
        gamma = 2 + cos(theta);
        f->b1 = gamma - pow(gamma * gamma - 1,0.5);
        f->a0 = 1 - f->b1;
        }
    f->sdelay = newDelay(1);
    return f;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %edi, %ebp
movsd %xmm0, 0x8(%rsp)
movl $0x20, %edi
callq 0x6ddf
movq %rax, %rbx
movsd 0x8(%rsp), %xmm1
movsd %xmm1, (%rax)
mulsd 0x2068(%rip), %xmm1     # 0xa798
leaq 0x6cf9(%rip), %rax      # 0xf430
xorps %xmm0, %xmm0
cvtsi2sdl (%rax), %xmm0
divsd %xmm0, %xmm1
movapd %xmm1, %xmm0
callq 0x2170
testl %ebp, %ebp
je 0x878e
addsd 0x2439(%rip), %xmm0     # 0xab90
movsd %xmm0, 0x8(%rsp)
mulsd %xmm0, %xmm0
addsd 0x1b47(%rip), %xmm0     # 0xa2b0
movsd 0x1af7(%rip), %xmm1     # 0xa268
callq 0x20b0
movsd 0x8(%rsp), %xmm1
subsd %xmm0, %xmm1
movsd 0x1ad8(%rip), %xmm0     # 0xa260
subsd %xmm1, %xmm0
jmp 0x87d3
movsd 0x23fa(%rip), %xmm1     # 0xab90
subsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
movapd %xmm1, %xmm0
mulsd %xmm1, %xmm0
addsd 0x1b00(%rip), %xmm0     # 0xa2b0
movsd 0x1ab0(%rip), %xmm1     # 0xa268
callq 0x20b0
movapd %xmm0, %xmm1
subsd 0x8(%rsp), %xmm1
movsd 0x1a91(%rip), %xmm0     # 0xa260
addsd %xmm1, %xmm0
movsd %xmm1, 0x10(%rbx)
movsd %xmm0, 0x8(%rbx)
movl $0x10, %edi
callq 0x6ddf
movq %rax, %r14
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, (%r14)
movl $0x4, %edi
callq 0x6ddf
movq %rax, 0x8(%r14)
movl $0x0, (%rax)
movq %r14, 0x18(%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: getBiquad
int
getBiquad(biquad *f,int in)
    {
    double result;
    //printf("getting %d from ldelay\n",getVarDelay(f->ldelay,1));
    //printf("getting %d from ldelay\n",getVarDelay(f->ldelay,2));
    //printf("getting %d from rdelay\n",getVarDelay(f->rdelay,1));
    //printf("getting %d from rdelay\n",getVarDelay(f->rdelay,2));
    //result = f->a0 * in;
    //printf("result is %f\n",result);
    //printf("%f\n",f->a1 * getVarDelay(f->ldelay,1));
    //result += f->a1 * getVarDelay(f->ldelay,1);
    //printf("result is %f\n",result);
    //printf("%f\n",f->a2 * getVarDelay(f->ldelay,2));
    //result += f->a2 * getVarDelay(f->ldelay,2);
    //printf("result is %f\n",result);
    //printf("-%f\n",f->b1 * getVarDelay(f->rdelay,1));
    //result -= f->b1 * getVarDelay(f->rdelay,1);
    //printf("result is %f\n",result);
    //printf("-%f\n",f->b2 * getVarDelay(f->rdelay,2));
    //result -= f->b2 * getVarDelay(f->rdelay,2);
    //printf("result is %f\n",result);
    result = f->a0 * in
         + f->a1 * getVarDelay(f->ldelay,1)
         + f->a2 * getVarDelay(f->ldelay,2)
         - f->b1 * getVarDelay(f->rdelay,1)
         - f->b2 * getVarDelay(f->rdelay,2)
         ;
    //printf("result is %f\n",result);
    return (int) result;
    }

// Assembly:
cvtsi2sd %esi, %xmm1
movq 0x28(%rdi), %rax
movq 0x30(%rdi), %rcx
movq 0x8(%rax), %rsi
movl (%rax), %r8d
movl 0x4(%rax), %r9d
leal (%r9,%r8), %eax
decl %eax
cltd
idivl %r9d
movslq %edx, %r10
leal (%r9,%r8), %eax
addl $-0x2, %eax
cltd
idivl %r9d
movslq %edx, %rax
cvtsi2sdl (%rsi,%r10,4), %xmm2
mulsd 0x8(%rdi), %xmm2
mulsd (%rdi), %xmm1
cvtsi2sdl (%rsi,%rax,4), %xmm0
addsd %xmm2, %xmm1
mulsd 0x10(%rdi), %xmm0
addsd %xmm1, %xmm0
movq 0x8(%rcx), %rsi
movl (%rcx), %r8d
movl 0x4(%rcx), %ecx
leal (%rcx,%r8), %eax
decl %eax
cltd
idivl %ecx
movslq %edx, %r9
leal (%rcx,%r8), %eax
addl $-0x2, %eax
cltd
idivl %ecx
xorps %xmm1, %xmm1
cvtsi2sdl (%rsi,%r9,4), %xmm1
movslq %edx, %rax
mulsd 0x18(%rdi), %xmm1
subsd %xmm1, %xmm0
xorps %xmm1, %xmm1
cvtsi2sdl (%rsi,%rax,4), %xmm1
mulsd 0x20(%rdi), %xmm1
subsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: updateBiquad
int
updateBiquad(biquad *f,int in)
    {
    int out = getBiquad(f,in);
    //printf("in is %d\n",in);
    //printf("out is %d\n",out);
    //printf("pushing %d to ldelay\n",in);
    updateDelay(f->ldelay,in);
    //printf("pushing %d to rdelay\n",out);
    updateDelay(f->rdelay,out);
    //getchar();
    return out;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
callq 0x895c
movl %eax, %ecx
movq 0x28(%r14), %rsi
movslq (%rsi), %rax
movq 0x8(%rsi), %rdx
movl %ebx, (%rdx,%rax,4)
movl (%rsi), %eax
incl %eax
cltd
idivl 0x4(%rsi)
movl %edx, (%rsi)
movq 0x30(%r14), %rsi
movslq (%rsi), %rax
movq 0x8(%rsi), %rdx
movl %ecx, (%rdx,%rax,4)
movl (%rsi), %eax
incl %eax
cltd
idivl 0x4(%rsi)
movl %edx, (%rsi)
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newModBiquad
modbiquad *
newModBiquad(double a0,double a1,double a2,double b1,double b2,double wet,double dry)
    {
    modbiquad *f = New(sizeof(modbiquad));

    f->bq = newBiquad(a0,a1,a2,b1,b2);
    f->wet = wet;
    f->dry = dry;
    return f;
    }

// Assembly:
pushq %rbx
subq $0x40, %rsp
movsd %xmm6, 0x38(%rsp)
movsd %xmm5, 0x30(%rsp)
movsd %xmm4, 0x28(%rsp)
movsd %xmm3, 0x20(%rsp)
movsd %xmm2, 0x18(%rsp)
movsd %xmm1, 0x10(%rsp)
movsd %xmm0, 0x8(%rsp)
movl $0x18, %edi
callq 0x6ddf
movq %rax, %rbx
movsd 0x8(%rsp), %xmm0
movsd 0x10(%rsp), %xmm1
movsd 0x18(%rsp), %xmm2
movsd 0x20(%rsp), %xmm3
movsd 0x28(%rsp), %xmm4
callq 0x888c
movq %rax, 0x10(%rbx)
movsd 0x30(%rsp), %xmm0
movsd %xmm0, (%rbx)
movsd 0x38(%rsp), %xmm0
movsd %xmm0, 0x8(%rbx)
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: setModBiquad
int
setModBiquad(modbiquad *f,int in)
    {
    int out = getModBiquad(f,in);
    //printf("in is %d\n",in);
    //printf("out is %d\n",out);
    //printf("pushing %d to ldelay\n",in);
    updateBiquad(f->bq,in);
    //getchar();
    return out;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebx
cvtsi2sd %esi, %xmm0
movsd (%rdi), %xmm1
movsd %xmm1, 0x8(%rsp)
movq 0x10(%rdi), %r14
mulsd 0x8(%rdi), %xmm0
movsd %xmm0, (%rsp)
movq %r14, %rdi
callq 0x895c
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x8(%rsp), %xmm0
addsd (%rsp), %xmm0
cvttsd2si %xmm0, %ebp
movq %r14, %rdi
movl %ebx, %esi
callq 0x89fa
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newDDL
ddl *
newDDL(int length,double wet,double fb)
    {
    ddl *d = New(sizeof(ddl));
    d->fb = fb > 1? 1 : (fb < 0? 0: fb);
    d->wet = wet > 1? 1 : (wet < 0? 0: wet);
    d->dry = 1 - wet;
    d->length = length;
    d->sdelay = newDelay(length);
    return d;
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movsd %xmm1, 0x8(%rsp)
movsd %xmm0, 0x10(%rsp)
movl %edi, %ebx
movl $0x28, %edi
callq 0x6ddf
movq %rax, %r14
xorpd %xmm0, %xmm0
xorpd %xmm1, %xmm1
movsd 0x8(%rsp), %xmm4
maxsd %xmm4, %xmm1
movsd 0x16c1(%rip), %xmm2     # 0xa260
movapd %xmm2, %xmm3
cmpltsd %xmm4, %xmm3
movapd %xmm3, %xmm4
andnpd %xmm1, %xmm4
andpd %xmm2, %xmm3
orpd %xmm4, %xmm3
movlpd %xmm3, 0x10(%rax)
movsd 0x10(%rsp), %xmm3
maxsd %xmm3, %xmm0
movapd %xmm2, %xmm1
cmpltsd %xmm3, %xmm1
movapd %xmm3, %xmm4
movapd %xmm1, %xmm3
andnpd %xmm0, %xmm3
andpd %xmm2, %xmm1
orpd %xmm3, %xmm1
movlpd %xmm1, (%rax)
subsd %xmm4, %xmm2
movsd %xmm2, 0x8(%rax)
movl %ebx, 0x18(%rax)
movl %ebx, %edi
callq 0x8620
movq %rax, 0x20(%r14)
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newLFO
lfo *
newLFO(double freq)
    {
    lfo *o = New(sizeof(lfo));
    o->start = 0;
    o->freq = freq;
    o->step = 2 * M_PI / (SampleRate / freq);
    return o;
    }

// Assembly:
pushq %rax
movsd %xmm0, (%rsp)
movl $0x18, %edi
callq 0x6ddf
movq $0x0, 0x8(%rax)
movsd (%rsp), %xmm1
movsd %xmm1, (%rax)
leaq 0x6769(%rip), %rcx      # 0xf430
xorps %xmm0, %xmm0
cvtsi2sdl (%rcx), %xmm0
divsd %xmm1, %xmm0
movsd 0x1abe(%rip), %xmm1     # 0xa798
divsd %xmm0, %xmm1
movsd %xmm1, 0x10(%rax)
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newMDE
mde *
newMDE(double wet,double fb,int dsamples,double freq,int lo,int hi)
    {
    mde *m = New(sizeof(mde));
    m->dry = 1 - wet;
    m->wet = wet;
    m->fb = fb;
    m->sdelay = newDelay(dsamples);
    m->osc = newLFO(freq);
    m->lo = lo;
    m->hi = hi;
    return m;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movl %edx, %ebx
movl %esi, %ebp
movsd %xmm2, 0x10(%rsp)
movl %edi, %r15d
movsd %xmm1, 0x8(%rsp)
movsd %xmm0, (%rsp)
movl $0x30, %edi
callq 0x6ddf
movq %rax, %r14
movsd 0x151b(%rip), %xmm0     # 0xa260
movsd (%rsp), %xmm1
subsd %xmm1, %xmm0
movsd %xmm0, 0x10(%rax)
movsd %xmm1, 0x18(%rax)
movsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x20(%rax)
movl %r15d, %edi
callq 0x8620
movq %rax, (%r14)
movl $0x18, %edi
callq 0x6ddf
movq $0x0, 0x8(%rax)
movsd 0x10(%rsp), %xmm1
movsd %xmm1, (%rax)
leaq 0x669f(%rip), %rcx      # 0xf430
xorps %xmm0, %xmm0
cvtsi2sdl (%rcx), %xmm0
divsd %xmm1, %xmm0
movsd 0x19f4(%rip), %xmm1     # 0xa798
divsd %xmm0, %xmm1
movsd %xmm1, 0x10(%rax)
movq %rax, 0x8(%r14)
movl %ebp, 0x28(%r14)
movl %ebx, 0x2c(%r14)
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: updateMDE
int
updateMDE(mde *m,int in)
    {
    int out = getMDE(m,in);
    int recirc = getMDEDelay(m);
    
    updateLFO(m->osc);
    updateDelay(m->sdelay,in + m->fb * recirc);

    return out;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebp
movq %rdi, %r14
callq 0x8dc7
movl %eax, %ebx
movq 0x8(%r14), %rax
movsd 0x8(%rax), %xmm0
callq 0x2290
movl 0x28(%r14), %eax
movl 0x2c(%r14), %ecx
leal (%rcx,%rax), %edx
cvtsi2sd %edx, %xmm1
subl %eax, %ecx
cvtsi2sd %ecx, %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
mulsd 0x13e1(%rip), %xmm0     # 0xa268
movq (%r14), %rdi
callq 0x86a9
movl %eax, %r15d
movq 0x8(%r14), %r12
movsd 0x8(%r12), %xmm0
callq 0x2290
movsd 0x10(%r12), %xmm0
addsd 0x8(%r12), %xmm0
movsd %xmm0, 0x8(%r12)
movq (%r14), %rcx
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
xorps %xmm1, %xmm1
cvtsi2sd %r15d, %xmm1
mulsd 0x20(%r14), %xmm1
addsd %xmm0, %xmm1
cvttsd2si %xmm1, %eax
movslq (%rcx), %rdx
movq 0x8(%rcx), %rsi
movl %eax, (%rsi,%rdx,4)
movl (%rcx), %eax
incl %eax
cltd
idivl 0x4(%rcx)
movl %edx, (%rcx)
movl %ebx, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newCombF
combf *
newCombF(int samplesDelayed,double fb)
    {
    combf *c = New(sizeof(combf));
    c->sdelay = newDelay(samplesDelayed);
    c->fb = fb;
    c->length = samplesDelayed;
    return c;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movsd %xmm0, (%rsp)
movl %edi, %ebx
movl $0x18, %edi
callq 0x6ddf
movq %rax, %r14
movl %ebx, %edi
callq 0x8620
movq %rax, 0x10(%r14)
movsd (%rsp), %xmm0
movsd %xmm0, (%r14)
movl %ebx, 0x8(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newLPC
lpc *
newLPC(int samplesDelayed,double gc,double glp)
    {
    lpc *f = New(sizeof(lpc));
    f->idelay = newDelay(samplesDelayed+1);
    f->odelay = newDelay(samplesDelayed);
    f->gc = gc;
    f->glp = glp;
    f->length = samplesDelayed;
    return f;
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movsd %xmm1, 0x10(%rsp)
movsd %xmm0, 0x8(%rsp)
movl %edi, %ebx
movl $0x30, %edi
callq 0x6ddf
movq %rax, %r14
leal 0x1(%rbx), %edi
callq 0x8620
movq %rax, 0x10(%r14)
movl %ebx, %edi
callq 0x8620
movq %rax, 0x18(%r14)
movsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x20(%r14)
movsd 0x10(%rsp), %xmm0
movsd %xmm0, 0x28(%r14)
movl %ebx, 0x8(%r14)
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: updateLPC
int
updateLPC(lpc *f,int in)
    {
    int out = getLPC(f,in);
    updateDelay(f->idelay,in);
    updateDelay(f->odelay,out);
    return out;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
callq 0x8ff7
movl %eax, %ecx
movq 0x10(%r14), %rsi
movslq (%rsi), %rax
movq 0x8(%rsi), %rdx
movl %ebx, (%rdx,%rax,4)
movl (%rsi), %eax
incl %eax
cltd
idivl 0x4(%rsi)
movl %edx, (%rsi)
movq 0x18(%r14), %rsi
movslq (%rsi), %rax
movq 0x8(%rsi), %rdx
movl %ecx, (%rdx,%rax,4)
movl (%rsi), %eax
incl %eax
cltd
idivl 0x4(%rsi)
movl %edx, (%rsi)
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/lib/filters.c
// Function: newDAP
dap *
newDAP(int samplesDelayed,double g)
    {
    dap *f = New(sizeof(dap));
    f->xdelay = newDelay(samplesDelayed);
    f->ydelay = newDelay(samplesDelayed);
    f->g = g;
    f->length = samplesDelayed;
    return f;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movsd %xmm0, (%rsp)
movl %edi, %ebx
movl $0x28, %edi
callq 0x6ddf
movq %rax, %r14
movl %ebx, %edi
callq 0x8620
movq %rax, 0x10(%r14)
movl %ebx, %edi
callq 0x8620
movq %rax, 0x18(%r14)
movsd (%rsp), %xmm0
movsd %xmm0, 0x20(%r14)
movl %ebx, 0x8(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/wjmelements[P]evm/include/labelQueue.h
// Function: registerLabel
static void registerLabel(jump_t jump) {
    for (uint32_t i = 0; i < labelCount; i++) {
        if (labels[i].length != jump.label.length) {
            continue;
        }
        if (memcmp(labels[i].start, jump.label.start, jump.label.length)) {
            continue;
        }
        fprintf(stderr, "Duplicate label at %s\n", jump.label.start);
        assert(0); // duplicate label
    }
    labelLocations[labelCount] = jump.programCounter;
    dataSizes[labelCount] = jump.dataSize;
    labels[labelCount++] = jump.label;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x40(%rsp), %rsi
movl 0x4fec(%rip), %r12d     # 0x7860
testq %r12, %r12
je 0x28bf
movq 0x10(%rsi), %rbx
movq 0x18(%rsi), %r14
movq %r12, %r13
shlq $0x4, %r13
xorl %ebp, %ebp
leaq 0x4fdf(%rip), %r15      # 0x7870
cmpq %r14, 0x8(%rbp,%r15)
jne 0x28ac
movq (%rbp,%r15), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x2070
testl %eax, %eax
je 0x28f9
addq $0x10, %rbp
cmpq %rbp, %r13
jne 0x2891
movq %r12, %rax
leaq 0x40(%rsp), %rsi
jmp 0x28c1
xorl %eax, %eax
movl (%rsi), %ecx
leaq 0x8fa6(%rip), %rdx      # 0xb870
movl %ecx, (%rdx,%rax,4)
incl %r12d
movl %r12d, 0x4f89(%rip)     # 0x7860
shlq $0x4, %rax
leaq 0x4f8e(%rip), %rcx      # 0x7870
movups 0x10(%rsi), %xmm0
movups %xmm0, (%rax,%rcx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
callq 0x2090
// File: /workspace/github_c_makefile_star2_O3/wjmelements[P]evm/include/labelQueue.h
// Function: incrementLabelLocations
static uint32_t firstLabelAfter(uint32_t pc) {
    // inclusive
    uint32_t begin = 0; 
    // exclusive
    uint32_t end = labelCount;
    while (begin < end) {
        uint32_t mid = (begin + end) / 2;
        if (labelLocations[mid] <= pc) {
            begin = mid + 1;
        } else {
            end = mid;
        }
    }
    return begin;
}

// Assembly:
movl 0x4f59(%rip), %eax      # 0x7860
testq %rax, %rax
je 0x293c
xorl %edx, %edx
leaq 0x8f5b(%rip), %rcx      # 0xb870
movl %eax, %r9d
leal (%r9,%rdx), %r10d
shrl %r10d
cmpl %edi, (%rcx,%r10,4)
leal 0x1(%r10), %r8d
cmovbel %r9d, %r10d
cmoval %edx, %r8d
movl %r8d, %edx
movl %r10d, %r9d
cmpl %r10d, %r8d
jb 0x2918
jmp 0x293f
xorl %r8d, %r8d
cmpl %eax, %r8d
jae 0x2967
movl %r8d, %ecx
subq %rcx, %rax
shlq $0x2, %rcx
xorl %edx, %edx
leaq 0x8f19(%rip), %rdi      # 0xb870
leaq (%rcx,%rdx,4), %r8
addl %esi, (%rdi,%r8)
incq %rdx
cmpq %rdx, %rax
jne 0x2957
retq
// File: /workspace/github_c_makefile_star2_O3/samtools[P]htslib/bgzip.c
// Function: confirm_overwrite
static int confirm_overwrite(const char *fn)
{
    int save_errno = errno;
    int ret = 0;

    if (isatty(STDIN_FILENO)) {
        fprintf(stderr, "[bgzip] %s already exists; do you wish to overwrite (y or n)? ", fn);
        if (ask_yn()) ret = 1;
    }

    errno = save_errno;
    return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
callq 0x4050
movq %rax, %rbx
movl (%rax), %r12d
xorl %ebp, %ebp
xorl %edi, %edi
callq 0x48f0
testl %eax, %eax
jne 0x7b32
movl %r12d, (%rbx)
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0xc(%rsp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x4cf0
movl (%r15), %ebp
jmp 0x7b20
// File: /workspace/github_c_makefile_star2_O3/samtools[P]htslib/bgzip.c
// Function: setfilespec
static int setfilespec(const char *path, const struct stat *status)
{
    if (!path || !status) {     //invalid
        return -1;
    }
    if (!strcmp(path, "-")) {   //cant get / set for stdin/out, return success
        return 0;
    }

#ifdef _WIN32
    struct _utimbuf tval;
    //time upto sec - access & modification time
    tval.actime = status->st_atime;
    tval.modtime = status->st_mtime;
    if (_utime(path, &tval) < 0) {
        fprintf(stderr, "[bgzip] Failed to set file specifications.\n");
        return -1;
    }
#else
    struct timeval tval[2];
    memset(&tval[0], 0, sizeof(tval));
    //time upto sec - access time
    tval[0].tv_sec = status->st_atime;
    //time upto sec - modification time
    tval[1].tv_sec = status->st_mtime;
    if (utimes(path, &tval[0]) < 0) {
        fprintf(stderr, "[bgzip] Failed to set file specifications.\n");
        return -1;
    }
#endif //_WIN32
    return 0;
}

// Assembly:
testq %rsi, %rsi
je 0x7c26
cmpb $0x2d, (%rdi)
jne 0x7bf1
cmpb $0x0, 0x1(%rdi)
je 0x7c2c
subq $0x28, %rsp
xorps %xmm0, %xmm0
movq %rsp, %rax
movaps %xmm0, 0x10(%rax)
movaps %xmm0, (%rax)
movq 0x48(%rsi), %rcx
movq %rcx, (%rax)
movq 0x58(%rsi), %rcx
movq %rcx, 0x10(%rax)
movq %rax, %rsi
callq 0x4320
movl %eax, %ecx
xorl %eax, %eax
testl %ecx, %ecx
js 0x7c2f
addq $0x28, %rsp
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
xorl %eax, %eax
retq
callq 0x4d56
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x7c21
nop
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/test_hm_dir.c
// Function: main
int main(int argc, char **argv)
{
	if (argc > 2){

		if (argc == 4 && strcmp("find", argv[1]) == 0)
			return find_in_dir(argv[2], argv[3]);

		if (argc == 3 && strcmp("dump", argv[1]) == 0)
			return dump_dir(argv[2]);

		if (argc == 3 && strcmp("list", argv[1]) == 0)
			return list_dir(argv[2]);
	}

	printf("Usage:\n");
	printf("\t%s list [directory] - list files in the database\n", argv[0]);
	printf("\t%s find [directory] [key] - find in the database\n", argv[0]);
	printf("\t%s dump [directory] - dump the database\n", argv[0]);
	printf("\t\tDo not forget about quotes around the directory\n");

	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
cmpl $0x3, %edi
jl 0x1363
je 0x1335
cmpl $0x4, %edi
jne 0x1363
movq 0x8(%rbx), %rsi
leaq 0x1d09(%rip), %rdi      # 0x3004
callq 0x10c0
testl %eax, %eax
jne 0x1363
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %r14
callq 0x1693
movq %rax, %rbx
movq %rax, %rdi
movq %r14, %rsi
callq 0x16f2
testq %rax, %rax
je 0x141d
movq %rax, %rdi
callq 0x1afb
jmp 0x1429
movq 0x8(%rbx), %r14
leaq 0x1cc9(%rip), %rdi      # 0x3009
movq %r14, %rsi
callq 0x10c0
testl %eax, %eax
je 0x13b9
leaq 0x1cbb(%rip), %rdi      # 0x300e
movq %r14, %rsi
callq 0x10c0
testl %eax, %eax
je 0x1407
leaq 0x1d39(%rip), %rdi      # 0x30a3
callq 0x1040
movq (%rbx), %rsi
leaq 0x1c9a(%rip), %rdi      # 0x3013
xorl %eax, %eax
callq 0x1090
movq (%rbx), %rsi
leaq 0x1cbc(%rip), %rdi      # 0x3046
xorl %eax, %eax
callq 0x1090
movq (%rbx), %rsi
leaq 0x1cde(%rip), %rdi      # 0x3079
xorl %eax, %eax
callq 0x1090
leaq 0x1d01(%rip), %rdi      # 0x30aa
callq 0x1040
movl $0x1, %eax
popq %rbx
popq %r14
popq %r15
retq
movq 0x10(%rbx), %rdi
callq 0x1693
movq %rax, %rbx
movq %rax, %rdi
callq 0x174b
movq %rax, %r14
movq %rax, %rdi
callq 0x176f
testq %rax, %rax
je 0x13fd
movl $0x1e, %r15d
movq %rax, %rdi
callq 0x1afb
decq %r15
je 0x13fd
movq %r14, %rdi
callq 0x17ce
testq %rax, %rax
jne 0x13e3
movq %r14, %rdi
callq 0x176a
jmp 0x1429
movq 0x10(%rbx), %rdi
callq 0x1693
movq %rax, %rbx
movq %rax, %rdi
callq 0x1894
jmp 0x1429
leaq 0x1cb8(%rip), %rdi      # 0x30dc
callq 0x1040
movq %rbx, %rdi
callq 0x1644
movq %rbx, %rdi
callq 0x1030
xorl %eax, %eax
jmp 0x13b3
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_glob.c
// Function: hm_glob_open
const char **hm_glob_open(glob_t *globresults, const char *path)
{
	int result = glob(path, 0, NULL, globresults);

	if (result == GLOB_NOMATCH)
		return _hm_glob_emptyresult();

	if (result)
		return NULL;

	// size is at least 1
	size_t size = globresults->gl_pathc;

	const char **files = malloc( (size + 1) * sizeof(char *));
	if (files == NULL)
		return NULL;

	// check if there is something else than file / symlink in the directory
	size_t j = 0;
	size_t i;
	for (i = 0; i < globresults->gl_pathc; ++i){
		const char *filename = globresults->gl_pathv[i];

		if (_hm_glob_check_file( filename ))
			files[j++] = filename;
	}

	files[j] = NULL;

	return files;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdi, %r14
xorl %ebx, %ebx
movq %rsi, %rdi
xorl %esi, %esi
xorl %edx, %edx
movq %r14, %rcx
callq 0x10f0
testl %eax, %eax
je 0x1482
cmpl $0x3, %eax
jne 0x14e9
movl $0x8, %edi
callq 0x1130
movq %rax, %rbx
testq %rax, %rax
jne 0x14e2
jmp 0x14d7
movq (%r14), %r15
leaq 0x8(,%r15,8), %rdi
callq 0x1130
testq %rax, %rax
je 0x14d7
movq %rax, %rbx
testq %r15, %r15
je 0x14db
xorl %ebp, %ebp
leaq 0x8(%rsp), %r15
xorl %r13d, %r13d
movq 0x8(%r14), %rax
movq (%rax,%rbp,8), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x1080
testl $0xa000, 0x20(%rsp)     # imm = 0xA000
je 0x14cd
movq %r12, (%rbx,%r13,8)
incq %r13
incq %rbp
cmpq (%r14), %rbp
jb 0x14a9
jmp 0x14de
xorl %ebx, %ebx
jmp 0x14e9
xorl %r13d, %r13d
leaq (%rbx,%r13,8), %rax
movq $0x0, (%rax)
movq %rbx, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_glob.c
// Function: hm_glob_size
size_t hm_glob_size(const char **files)
{
	size_t count = 0;
	while(*files){
		++files;
		++count;
	}

	return count;
}

// Assembly:
cmpq $0x0, (%rdi)
je 0x1516
xorl %ecx, %ecx
leaq 0x1(%rcx), %rax
cmpq $0x0, 0x8(%rdi,%rcx,8)
movq %rax, %rcx
jne 0x1506
retq
xorl %eax, %eax
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_open
hm_dir_t *hm_dir_open(hm_dir_t *dir, const char *path)
{
	dir->path = path;

	glob_t globresults;

	const char **files = hm_glob_open(& globresults, dir->path);

	if (files == NULL)
		return NULL;

	size_t count = hm_glob_size(files);

	if (count == 0){
		hm_glob_close(& globresults, files);

		dir->count = 0;
		dir->files = NULL;

		// success
		return dir;
	}

	// dir->count is at least 1

	dir->files = malloc(count * sizeof(hm_disktable_t));
	if (dir->files == NULL){
		hm_glob_close(& globresults, files);

		return NULL;
	}

	dir->count = 0;

	size_t i;
	for(i = 0; i < count; ++i){
		const char *filename = files[i];
		// open the file
		hm_disktable_t *file = hm_disktable_open( & dir->files[i], filename);

		if (file == NULL){
			// this is really problematic...
			// some files are open, some are not.
			// close / free everything

			hm_glob_close(& globresults, files);

			// dir->count is not increased,
			// so no reason for this not to work...
			hm_dir_close(dir);

			return NULL;
		}

		// I don't like this,
		// because file->filename is "private property",
		// but it seems to be best way.
		// if fail, will produce NULL, so no checks need
		file->filename = strdup(filename);

		++(dir->count);
	}

	hm_glob_close(& globresults, files);

	return dir;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, (%rsp)
movq %rsi, (%rdi)
leaq 0x10(%rsp), %rdi
callq 0x1440
testq %rax, %rax
je 0x1633
movq %rax, %r13
movq %rax, %rdi
callq 0x14fe
testq %rax, %rax
je 0x15e4
movq %rax, %r14
leaq (,%rax,8), %rax
leaq (%rax,%rax,4), %rdi
callq 0x1130
movq (%rsp), %rbx
movq %rax, 0x10(%rbx)
testq %rax, %rax
je 0x1603
movq $0x0, 0x8(%rbx)
xorl %ebp, %ebp
xorl %r15d, %r15d
movq %r13, 0x8(%rsp)
movq (%r13,%r15,8), %r12
movq 0x10(%rbx), %rdi
addq %rbp, %rdi
movq %r12, %rsi
callq 0x1b38
testq %rax, %rax
je 0x1617
movq %rax, %r13
movq %r12, %rdi
callq 0x1180
movq %rax, (%r13)
incq 0x8(%rbx)
incq %r15
addq $0x28, %rbp
cmpq %r15, %r14
movq 0x8(%rsp), %r13
jne 0x158f
movq %r13, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x1060
movq (%rsp), %rax
jmp 0x1635
movq %r13, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x1060
xorps %xmm0, %xmm0
movq (%rsp), %rax
movups %xmm0, 0x8(%rax)
jmp 0x1635
movq %r13, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x1060
jmp 0x1633
movq 0x8(%rsp), %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1644
xorl %eax, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_close
void hm_dir_close(hm_dir_t *dir)
{
	size_t i;
	for(i = 0; i < dir->count; ++i){
		hm_disktable_t *file = & dir->files[i];

		hm_disktable_close(file);

		// cast because file->filename is declared const
		free( (void *) file->filename );
	}

	free(dir->files);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpq $0x0, 0x8(%rdi)
je 0x167f
xorl %r14d, %r14d
xorl %r15d, %r15d
movq 0x10(%rbx), %r12
leaq (%r12,%r14), %rdi
callq 0x1c11
movq (%r12,%r14), %rdi
callq 0x1030
incq %r15
addq $0x28, %r14
cmpq 0x8(%rbx), %r15
jb 0x165c
movq 0x10(%rbx), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_opena
hm_dir_t *hm_dir_opena(const char *path)
{
	hm_dir_t *dir = malloc(sizeof(hm_dir_t));

	if (dir == NULL)
		return NULL;

	if (hm_dir_open(dir, path))
		return dir;

	free(dir);

	return NULL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x18, %edi
callq 0x1130
testq %rax, %rax
je 0x16c4
movq %rax, %rbx
movq %rax, %rdi
movq %r14, %rsi
callq 0x151c
testq %rax, %rax
jne 0x16c6
movq %rbx, %rdi
callq 0x1030
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_get
const void *hm_dir_get(const hm_dir_t *dir, const char *key)
{
	size_t i;
	for(i = dir->count; i > 0; --i){
		hm_disktable_t *file = & dir->files[i - 1];

		const void *data = hm_disktable_get(file, key);

		if (data)
			return data;

		++file;
	}

	return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x8(%rdi), %r12
testq %r12, %r12
je 0x1737
movq %rsi, %r14
movq %rdi, %r15
leaq (%r12,%r12,4), %rax
leaq -0x28(,%rax,8), %r13
xorl %ebx, %ebx
movq 0x10(%r15), %rdi
addq %r13, %rdi
movq %r14, %rsi
callq 0x1c31
testq %rax, %rax
jne 0x173b
addq $-0x28, %r13
decq %r12
jne 0x1718
jmp 0x173e
xorl %ebx, %ebx
jmp 0x173e
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_it_first
const hm_pair_t *hm_dir_it_first(hm_dir_it_t *it)
{
	size_t i;
	for(i = 0; i < it->dir->count; ++i){
		const hm_disktable_t *file = & it->dir->files[i];

		it->p[i].pos  = 0;
		it->p[i].pair = hm_disktable_getat(file, 0);
	}

	return hm_dir_it_next(it);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
cmpq $0x0, 0x8(%rax)
je 0x17bb
leaq 0x10(%rbx), %r14
xorl %r15d, %r15d
xorl %r12d, %r12d
movq 0x10(%rax), %rdi
addq %r15, %rdi
movq $0x0, -0x8(%r14)
xorl %esi, %esi
callq 0x1cb7
movq %rax, (%r14)
incq %r12
movq (%rbx), %rax
addq $0x10, %r14
addq $0x28, %r15
cmpq 0x8(%rax), %r12
jb 0x178e
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x17ce
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_it_next
const hm_pair_t *hm_dir_it_next(hm_dir_it_t *it)
{
	const hm_pair_t *pair = NULL;

	size_t i;

	// step 1: find minimal in reverse order to find most recent.
	for(i = it->dir->count; i > 0; --i){
		const hm_pair_t *pair2 = it->p[i - 1].pair;

		// skip pair
		if (pair2 == NULL)
			continue;

		// initialize pair
		if (pair == NULL){
			pair = pair2;
			continue;
		}

		// compare and swap pair
		if (hm_pair_cmppair(pair, pair2) > 0)
			pair = pair2;
	}

	if (pair == NULL)
		return NULL;

	// step 2: increase all duplicates
	for(i = 0; i < it->dir->count; ++i){
		const hm_pair_t *pair2 = it->p[i].pair;

		if (pair2 && hm_pair_cmppair(pair, pair2) == 0){
			const hm_disktable_t *file = & it->dir->files[i];

			it->p[i].pair = hm_disktable_getat(file, ++it->p[i].pos);
		}
	}

	return pair;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq (%rdi), %rax
movq 0x8(%rax), %r12
testq %r12, %r12
je 0x1885
movq %rdi, %r14
movq %r12, %r13
shlq $0x4, %r13
addq %rdi, %r13
xorl %ebx, %ebx
movq (%r13), %r15
testq %r15, %r15
je 0x1819
testq %rbx, %rbx
je 0x1816
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1a8b
testl %eax, %eax
jg 0x1816
movq %rbx, %r15
movq %r15, %rbx
decq %r12
addq $-0x10, %r13
testq %r12, %r12
jne 0x17f6
testq %rbx, %rbx
je 0x1885
movq (%r14), %rcx
cmpq $0x0, 0x8(%rcx)
je 0x1887
leaq 0x10(%r14), %r15
xorl %r12d, %r12d
xorl %r13d, %r13d
movq (%r15), %rsi
testq %rsi, %rsi
je 0x1872
movq %rbx, %rdi
callq 0x1a8b
movq (%r14), %rcx
testl %eax, %eax
jne 0x1872
movq 0x10(%rcx), %rdi
addq %r12, %rdi
movq -0x8(%r15), %rsi
incq %rsi
movq %rsi, -0x8(%r15)
callq 0x1cb7
movq %rax, (%r15)
movq (%r14), %rcx
incq %r13
addq $0x28, %r12
addq $0x10, %r15
cmpq 0x8(%rcx), %r13
jb 0x183e
jmp 0x1887
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_dir.c
// Function: hm_dir_printf
void hm_dir_printf(const hm_dir_t *dir)
{
	size_t i;
	for(i = 0; i < dir->count; ++i){
		hm_disktable_t *file = & dir->files[i];

		printf("%5zu : %s\n", i, file->filename);
	}
}

// Assembly:
cmpq $0x0, 0x8(%rdi)
je 0x18e0
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x1839(%rip), %r14      # 0x30e6
xorl %r12d, %r12d
xorl %r15d, %r15d
movq 0x10(%rbx), %rax
movq (%rax,%r12), %rdx
movq %r14, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x1090
incq %r15
addq $0x28, %r12
cmpq 0x8(%rbx), %r15
jb 0x18b3
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/nmmmnu[P]HM2/hm_pair.c
// Function: hm_pair_printf
int hm_pair_printf(const hm_pair_t *pair){
	printf("| %s | %-12p | %-20s | %-20s |\n",
			"hm_pair_t",
			pair,
			hm_pair_getkey(pair),
			hm_pair_getval(pair)
	);

	return 0;
}

// Assembly:
movq %rdi, %rdx
leaq 0x7(%rdi), %rcx
cmpl $0x0, (%rdi)
je 0x1b1b
movzwl 0x4(%rdx), %eax
rolw $0x8, %ax
movzwl %ax, %eax
leaq (%rax,%rcx), %r8
incq %r8
jmp 0x1b1e
xorl %r8d, %r8d
pushq %rax
leaq 0x15cb(%rip), %rdi      # 0x30f1
leaq 0x15e4(%rip), %rsi      # 0x3111
xorl %eax, %eax
callq 0x1090
xorl %eax, %eax
popq %rcx
retq