LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/wjmelements[P]evm/src/uint256.c
// Function: addmod256
void addmod256(const uint256_t *number1, const uint256_t *number2, const uint256_t *divisor, uint256_t *target) {
    uint512_t one, two, sum, three, result;
    clear256(&UPPER_P(&one));
    clear256(&UPPER_P(&two));
    clear256(&UPPER_P(&three));
    copy256(&LOWER_P(&one), number1);
    copy256(&LOWER_P(&two), number2);
    copy256(&LOWER_P(&three), divisor);
    add512(&one, &two, &sum);
    if (zero256(&UPPER(sum))) {
        divmod256(&LOWER(sum), divisor, &LOWER(one), target);
    } else {
        copy256(&LOWER(two), divisor);
        divmod512(&sum, &two, &one, &result);
        copy256(target, &LOWER(result));
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x100, %rsp            # imm = 0x100
movq %rcx, %rbx
movq %rdx, %r14
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rax
movaps %xmm0, (%rax)
movaps %xmm0, 0x10(%rax)
leaq 0x80(%rsp), %rcx
movaps %xmm0, (%rcx)
movaps %xmm0, 0x10(%rcx)
movups (%rdi), %xmm0
movaps %xmm0, 0x20(%rax)
movups 0x10(%rdi), %xmm0
movaps %xmm0, 0x30(%rax)
movups (%rsi), %xmm0
movaps %xmm0, 0x20(%rcx)
movups 0x10(%rsi), %xmm0
movaps %xmm0, 0x30(%rcx)
movq %rsp, %r15
movq %rax, %rdi
movq %rcx, %rsi
movq %r15, %rdx
callq 0x3b1f
cmpq $0x0, 0x18(%r15)
jne 0x4bcb
cmpq $0x0, 0x10(%rsp)
jne 0x4bcb
cmpq $0x0, 0x8(%rsp)
jne 0x4bcb
cmpq $0x0, (%rsp)
jne 0x4bcb
leaq 0x60(%rsp), %rdx
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movq %rbx, %rcx
callq 0x4767
jmp 0x4c0d
movups (%r14), %xmm0
leaq 0x80(%rsp), %rsi
movaps %xmm0, 0x20(%rsi)
movups 0x10(%r14), %xmm0
movaps %xmm0, 0x30(%rsi)
movq %rsp, %rdi
leaq 0x40(%rsp), %rdx
leaq 0xc0(%rsp), %r14
movq %r14, %rcx
callq 0x4922
movups 0x20(%r14), %xmm0
movups %xmm0, (%rbx)
movups 0x30(%r14), %xmm0
movups %xmm0, 0x10(%rbx)
addq $0x100, %rsp            # imm = 0x100
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/wjmelements[P]evm/src/uint256.c
// Function: mulmod256
void mulmod256(const uint256_t *number1, const uint256_t *number2, const uint256_t *divisor, uint256_t *target) {
    uint512_t one, two, product, three, result;
    clear256(&UPPER_P(&one));
    clear256(&UPPER_P(&two));
    clear256(&UPPER_P(&three));
    copy256(&LOWER_P(&one), number1);
    copy256(&LOWER_P(&two), number2);
    copy256(&LOWER_P(&three), divisor);
    mul512(&one, &two, &product);
    if (zero256(&UPPER(product))) {
        divmod256(&LOWER(product), divisor, &LOWER(one), target);
    } else {
        copy256(&LOWER(two), divisor);
        divmod512(&product, &two, &one, &result);
        copy256(target, &LOWER(result));
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x100, %rsp            # imm = 0x100
movq %rcx, %rbx
movq %rdx, %r14
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rax
movaps %xmm0, (%rax)
movaps %xmm0, 0x10(%rax)
leaq 0x80(%rsp), %rcx
movaps %xmm0, (%rcx)
movaps %xmm0, 0x10(%rcx)
movups (%rdi), %xmm0
movaps %xmm0, 0x20(%rax)
movups 0x10(%rdi), %xmm0
movaps %xmm0, 0x30(%rax)
movups (%rsi), %xmm0
movaps %xmm0, 0x20(%rcx)
movups 0x10(%rsi), %xmm0
movaps %xmm0, 0x30(%rcx)
movq %rsp, %r15
movq %rax, %rdi
movq %rcx, %rsi
movq %r15, %rdx
callq 0x4149
cmpq $0x0, 0x18(%r15)
jne 0x4cae
cmpq $0x0, 0x10(%rsp)
jne 0x4cae
cmpq $0x0, 0x8(%rsp)
jne 0x4cae
cmpq $0x0, (%rsp)
jne 0x4cae
leaq 0x60(%rsp), %rdx
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movq %rbx, %rcx
callq 0x4767
jmp 0x4cf0
movups (%r14), %xmm0
leaq 0x80(%rsp), %rsi
movaps %xmm0, 0x20(%rsi)
movups 0x10(%r14), %xmm0
movaps %xmm0, 0x30(%rsi)
movq %rsp, %rdi
leaq 0x40(%rsp), %rdx
leaq 0xc0(%rsp), %r14
movq %r14, %rcx
callq 0x4922
movups 0x20(%r14), %xmm0
movups %xmm0, (%rbx)
movups 0x30(%r14), %xmm0
movups %xmm0, 0x10(%rbx)
addq $0x100, %rsp            # imm = 0x100
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/wjmelements[P]evm/src/uint256.c
// Function: tostring128
bool tostring128(const uint128_t *number, uint32_t baseParam, char *out,
                 uint32_t outLength) {
    if ((baseParam < 2) || (baseParam > 36)) {
        return false;
    }
    uint128_t rDiv;
    uint128_t rMod;
    uint128_t base;
    copy128(&rDiv, number);
    clear128(&base);
    LOWER(base) = baseParam;
    uint32_t offset = 0;
    do {
        if (offset > (outLength - 1)) {
            return false;
        }
        divmod128(&rDiv, &base, &rDiv, &rMod);
        out[offset++] = HEXDIGITS[LOWER(rMod)];
    } while (!zero128(&rDiv));
    out[offset] = '\0';
    reverseString(out, offset);
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
leal -0x25(%rsi), %eax
xorl %ebp, %ebp
movl $0x0, %r15d
cmpl $-0x23, %eax
jb 0x4d8e
movl %ecx, %r14d
movq %rdx, %rbx
movups (%rdi), %xmm0
movq %rsp, %r12
movaps %xmm0, (%r12)
leaq 0x18(%rsp), %rcx
andq $0x0, (%rcx)
movl %esi, %eax
movq %rax, 0x8(%rcx)
decl %r14d
leaq 0x14cb(%rip), %r13      # 0x6210
cmpl %r14d, %ebp
setbe %r15b
ja 0x4d8e
movq %r12, %rdi
leaq 0x18(%rsp), %rsi
movq %r12, %rdx
leaq 0x28(%rsp), %rcx
callq 0x460d
movq 0x30(%rsp), %rax
movb (%rax,%r13), %al
movl %ebp, %ecx
incl %ebp
movb %al, (%rbx,%rcx)
movq (%rsp), %rax
orq 0x8(%rsp), %rax
jne 0x4d45
movl %ebp, %eax
movb $0x0, (%rbx,%rax)
movq %rbx, %rdi
movl %ebp, %esi
callq 0x4da0
movl %r15d, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/wjmelements[P]evm/src/uint256.c
// Function: reverseString
static inline void reverseString(char *str, uint32_t length) {
    uint32_t i, j;
    for (i = 0, j = length - 1; i < j; i++, j--) {
        uint8_t c;
        c = str[i];
        str[i] = str[j];
        str[j] = c;
    }
}

// Assembly:
decl %esi
xorl %eax, %eax
movl %esi, %ecx
cmpq %rcx, %rax
jae 0x4dc1
movb (%rdi,%rax), %dl
movb (%rdi,%rcx), %sil
movb %sil, (%rdi,%rax)
movb %dl, (%rdi,%rcx)
incq %rax
leal -0x1(%rcx), %esi
jmp 0x4da4
retq
// File: /workspace/github_c_makefile_star2_O2/wjmelements[P]evm/src/uint256.c
// Function: tostring256
bool tostring256(const uint256_t *number, uint32_t baseParam, char *out,
                 uint32_t outLength) {
    if ((baseParam < 2) || (baseParam > 36)) {
        return false;
    }
    uint256_t rDiv;
    uint256_t rMod;
    uint256_t base;
    copy256(&rDiv, number);
    clear256(&base);
    UPPER(LOWER(base)) = 0;
    LOWER(LOWER(base)) = baseParam;
    uint32_t offset = 0;
    do {
        if (offset > (outLength - 1)) {
            return false;
        }
        divmod256(&rDiv, &base, &rDiv, &rMod);
        out[offset++] = HEXDIGITS[LOWER(LOWER(rMod))];
    } while (!zero256(&rDiv));
    out[offset] = '\0';
    reverseString(out, offset);
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
leal -0x25(%rsi), %eax
xorl %ebp, %ebp
movl $0x0, %r12d
cmpl $-0x23, %eax
jb 0x4e79
movl %ecx, %r14d
movq %rdx, %rbx
movups (%rdi), %xmm0
movq %rsp, %r15
movaps %xmm0, (%r15)
movups 0x10(%rdi), %xmm0
movaps %xmm0, 0x10(%r15)
movl %esi, %eax
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %r13
movaps %xmm0, (%r13)
andq $0x0, 0x10(%r13)
movq %rax, 0x18(%r13)
decl %r14d
cmpl %r14d, %ebp
setbe %r12b
ja 0x4e79
movq %r15, %rdi
movq %r13, %rsi
movq %r15, %rdx
leaq 0x20(%rsp), %rcx
callq 0x4767
movq 0x38(%rsp), %rax
leaq 0x13d0(%rip), %rcx      # 0x6210
movb (%rax,%rcx), %al
movl %ebp, %ecx
incl %ebp
movb %al, (%rbx,%rcx)
cmpq $0x0, 0x18(%rsp)
jne 0x4e18
cmpq $0x0, 0x10(%rsp)
jne 0x4e18
cmpq $0x0, 0x8(%rsp)
jne 0x4e18
cmpq $0x0, (%rsp)
jne 0x4e18
movl %ebp, %eax
movb $0x0, (%rbx,%rax)
movq %rbx, %rdi
movl %ebp, %esi
callq 0x4da0
movl %r12d, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: create
Stack create(int initSize){
    Stack stack;
    if(initSize<MIN_STACK_SIZE){
        fatal("stack size is too small");
    }
    stack=(Stack)malloc(sizeof(struct STACK));
    if(stack==NULL){
        fatal("stack malloc failed.");
    }
    stack->data=malloc(sizeof(int)*initSize);
    stack->size=initSize;
    clear(stack);
    return stack;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpl $0x4, %edi
jle 0x11e9
movl %edi, %ebx
pushq $0x10
popq %rdi
callq 0x1080
testq %rax, %rax
je 0x11f5
movq %rax, %r14
movl %ebx, %edi
shlq $0x2, %rdi
callq 0x1080
movq %rax, 0x8(%r14)
movl %ebx, (%r14)
orl $-0x1, 0x4(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0xe14(%rip), %rdi       # 0x2004
callq 0x1201
leaq 0xe20(%rip), %rdi       # 0x201c
callq 0x1201
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: push
void push(int value, Stack s){
    assert(s!=NULL);
    if(isFull(s)){
        fatal("stack is full");
    }
    //s->data[++s->top]=value;
    ++s->top;
    s->data[s->top]=value;
}

// Assembly:
pushq %rax
testq %rsi, %rsi
je 0x12ce
movslq 0x4(%rsi), %rax
movl (%rsi), %ecx
decl %ecx
cmpl %ecx, %eax
je 0x12eb
leaq 0x1(%rax), %rcx
movl %ecx, 0x4(%rsi)
movq 0x8(%rsi), %rcx
movl %edi, 0x4(%rcx,%rax,4)
popq %rax
retq
leaq 0xd5c(%rip), %rdi       # 0x2031
leaq 0xd5d(%rip), %rsi       # 0x2039
leaq 0xd98(%rip), %rcx       # 0x207b
pushq $0x2d
popq %rdx
callq 0x1070
leaq 0xd9f(%rip), %rdi       # 0x2091
callq 0x1201
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: pop
void pop(Stack s){
    assert(s!=NULL);
    if(isEmpty(s)){
        fatal("stack is empty.");
    }
    s->top--;
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x130c
movl 0x4(%rdi), %eax
cmpl $-0x1, %eax
je 0x1329
decl %eax
movl %eax, 0x4(%rdi)
popq %rax
retq
leaq 0xd1e(%rip), %rdi       # 0x2031
leaq 0xd1f(%rip), %rsi       # 0x2039
leaq 0xd7e(%rip), %rcx       # 0x209f
pushq $0x36
popq %rdx
callq 0x1070
leaq 0xded(%rip), %rdi       # 0x211d
callq 0x1201
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: top
int top(Stack s){
    assert(s!=NULL);
    if(isEmpty(s)){
        fatal("stack is empty.");
    }
    return s->data[s->top];
}

// Assembly:
pushq %rax
testq %rdi, %rdi
je 0x134e
movslq 0x4(%rdi), %rax
cmpq $-0x1, %rax
je 0x136b
movq 0x8(%rdi), %rcx
movl (%rcx,%rax,4), %eax
popq %rcx
retq
leaq 0xcdc(%rip), %rdi       # 0x2031
leaq 0xcdd(%rip), %rsi       # 0x2039
leaq 0xd4c(%rip), %rcx       # 0x20af
pushq $0x3d
popq %rdx
callq 0x1070
leaq 0xdab(%rip), %rdi       # 0x211d
callq 0x1201
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: print
void print(Stack s){
    assert(s!=NULL);
    if(isEmpty(s)){
        printf("stack is empty.\n");
    }else{
    	int i;
        for(i=s->top;i>=0;i--){
            printf("[%d]--%d\n",i, s->data[i]);
        }
        printf("\n"); 
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x1413
movq %rdi, %rbx
movl 0x4(%rdi), %ebp
cmpl $-0x1, %ebp
je 0x1403
leaq 0xd0b(%rip), %r14       # 0x20e5
testl %ebp, %ebp
js 0x13f7
movq 0x8(%rbx), %rax
movl %ebp, %ecx
movl (%rax,%rcx,4), %edx
movq %r14, %rdi
movl %ebp, %esi
xorl %eax, %eax
callq 0x1060
decl %ebp
jmp 0x13da
pushq $0xa
popq %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x1040
leaq 0xd13(%rip), %rdi       # 0x211d
popq %rbx
popq %r14
popq %rbp
jmp 0x1050
leaq 0xc17(%rip), %rdi       # 0x2031
leaq 0xc18(%rip), %rsi       # 0x2039
leaq 0xcab(%rip), %rcx       # 0x20d3
pushq $0x4b
popq %rdx
callq 0x1070
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/stack_array/stack2.c
// Function: main
int main(int argc, char **argv)
{
    Stack s=create(10);
    int i;
    for(i=0;i<10;i++){
        push(rand()%100,s);
    }
    printf("Stack Size: %d\n", s->size);
    printf("Stack Top: %d\n", s->top);
    print(s);
    pop(s);
    pop(s);
    print(s);
    printf("topAndPop: %d\n",topAndPop(s));
    print(s);
    clear(s);
    print(s);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
pushq $0xa
popq %rbp
movl %ebp, %edi
callq 0x11ac
movq %rax, %rbx
pushq $0x64
popq %r14
subl $0x1, %ebp
jb 0x145f
callq 0x10a0
cltd
idivl %r14d
movl %edx, %edi
movq %rbx, %rsi
callq 0x12ab
jmp 0x1445
movl (%rbx), %esi
leaq 0xc87(%rip), %rdi       # 0x20ef
xorl %eax, %eax
callq 0x1060
movl 0x4(%rbx), %esi
leaq 0xc86(%rip), %rdi       # 0x20ff
xorl %eax, %eax
callq 0x1060
movq %rbx, %rdi
callq 0x13bf
movq %rbx, %rdi
callq 0x12f7
movq %rbx, %rdi
callq 0x12f7
movq %rbx, %rdi
callq 0x13bf
movq %rbx, %rdi
callq 0x1377
leaq 0xc5f(%rip), %rdi       # 0x210e
movl %eax, %esi
xorl %eax, %eax
callq 0x1060
movq %rbx, %rdi
callq 0x13bf
orl $-0x1, 0x4(%rbx)
movq %rbx, %rdi
callq 0x13bf
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/dlist.c
// Function: dlist_make
LakeDottedList *dlist_make(LakeList *head, LakeVal *tail)
{
    LakeDottedList *dlist = dlist_alloc();
    dlist->head = head;
    dlist->tail = tail;
    return dlist;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x20
popq %rdi
callq 0x11a0
movl $0x6, (%rax)
movq $0x20, 0x8(%rax)
movq %r14, 0x10(%rax)
movq %rbx, 0x18(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/dlist.c
// Function: dlist_repr
char *dlist_repr(LakeDottedList *dlist)
{
    char *s = malloc(2);
    s[0] = '(';
    s[1] = '\0';
    int i;
    char *s2;
    if (dlist->head && LIST_N(dlist->head))
    {
        for (i = 0; i < LIST_N(dlist->head); ++i)
        {
            s2 = lake_repr(LIST_VAL(dlist->head, i));
            s = lake_str_append(s, s2);
            free(s2);
            if (i != LIST_N(dlist->head) - 1) s = lake_str_append(s, " ");
        }
    }
    else if (dlist->head)
    {
        s2 = lake_repr(dlist->head);
        s = lake_str_append(s, s2);
        free(s2);
    }
    s = lake_str_append(s, " . ");
    s2 = lake_repr(dlist->tail);
    s = lake_str_append(s, s2);
    free(s2);
    return lake_str_append(s, ")");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
pushq $0x2
popq %rdi
callq 0x11a0
movq %rax, %r14
movw $0x28, (%rax)
movq 0x10(%rbx), %rdi
testq %rdi, %rdi
je 0x150f
movq 0x18(%rdi), %rax
testq %rax, %rax
je 0x14f1
xorl %r13d, %r13d
leaq 0x4b72(%rip), %r15      # 0x600c
cmpq %r13, %rax
jbe 0x150f
movq 0x20(%rdi), %rax
movq (%rax,%r13,8), %rdi
callq 0x2a74
movq %rax, %r12
movq %r14, %rdi
movq %rax, %rsi
callq 0x131c
movq %rax, %r14
movq %r12, %rdi
callq 0x1030
movq 0x10(%rbx), %rdi
movq 0x18(%rdi), %rax
leaq -0x1(%rax), %rcx
cmpq %rcx, %r13
je 0x14ec
movq %r14, %rdi
movq %r15, %rsi
callq 0x131c
movq %rax, %r14
movq 0x10(%rbx), %rdi
movq 0x18(%rdi), %rax
incq %r13
jmp 0x149a
callq 0x2a74
movq %rax, %r15
movq %r14, %rdi
movq %rax, %rsi
callq 0x131c
movq %rax, %r14
movq %r15, %rdi
callq 0x1030
leaq 0x4af4(%rip), %rsi      # 0x600a
movq %r14, %rdi
callq 0x131c
movq %rax, %r14
movq 0x18(%rbx), %rdi
callq 0x2a74
movq %rax, %rbx
movq %r14, %rdi
movq %rax, %rsi
callq 0x131c
movq %rax, %r14
movq %rbx, %rdi
callq 0x1030
leaq 0x4e6b(%rip), %rsi      # 0x63b5
movq %r14, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x131c
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/env.c
// Function: env_make
Env *env_make(Env *parent)
{
    Env *env = malloc(sizeof(Env));
    env->parent = parent;
    env->bindings = lake_hash_make();
    return env;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
pushq $0x10
popq %rdi
callq 0x11a0
movq %rax, %r14
movq %rbx, (%rax)
pushq $0x1
popq %rdi
pushq $0x28
popq %rsi
callq 0x1150
movq %rax, 0x8(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: init_special_form_handlers
void init_special_form_handlers(LakeCtx *ctx)
{
    /* define_handler(ctx, "load", &load_special_form); */
    define_handler(ctx, "quote", &_quote);
    define_handler(ctx, "and", &_and);
    define_handler(ctx, "or", &_or);
    define_handler(ctx, "if", &_if);
    define_handler(ctx, "when", &_when);
    define_handler(ctx, "cond", &_cond);
    define_handler(ctx, "set!", &_setB);
    define_handler(ctx, "define", &_define);
    define_handler(ctx, "lambda", &_lambda);
    /* define_handler(ctx, "let", &_let); */
    /* define_handler(ctx, "let!", &_letB); */
    /* define_handler(ctx, "letrec", &_letrec); */
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x49b1(%rip), %rsi      # 0x6034
leaq 0xbc(%rip), %rdx        # 0x1746
callq 0x173d
leaq 0x49a4(%rip), %rsi      # 0x603a
leaq 0xc8(%rip), %rdx        # 0x1765
movq %rbx, %rdi
callq 0x173d
leaq 0x4f73(%rip), %rsi      # 0x661f
leaq 0x13f(%rip), %rdx       # 0x17f2
movq %rbx, %rdi
callq 0x173d
leaq 0x497c(%rip), %rsi      # 0x603e
leaq 0x1b6(%rip), %rdx       # 0x187f
movq %rbx, %rdi
callq 0x173d
leaq 0x4969(%rip), %rsi      # 0x6041
leaq 0x22f(%rip), %rdx       # 0x190e
movq %rbx, %rdi
callq 0x173d
leaq 0x4958(%rip), %rsi      # 0x6046
leaq 0x287(%rip), %rdx       # 0x197c
movq %rbx, %rdi
callq 0x173d
leaq 0x4947(%rip), %rsi      # 0x604b
leaq 0x32f(%rip), %rdx       # 0x1a3a
movq %rbx, %rdi
callq 0x173d
leaq 0x4936(%rip), %rsi      # 0x6050
leaq 0x3d0(%rip), %rdx       # 0x1af1
movq %rbx, %rdi
callq 0x173d
leaq 0x4927(%rip), %rsi      # 0x6057
leaq 0x4f8(%rip), %rdx       # 0x1c2f
movq %rbx, %rdi
popq %rbx
jmp 0x173d
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: and
static LakeVal *_and(LakeCtx *ctx, Env *env, LakeList *expr)
{
    /* drop the "and" symbol */
    list_shift(expr);

    /* (and ...) */
    LakeVal *result =
        LIST_N(expr) ? eval(ctx, env, list_shift(expr)) : VAL(ctx->T);
    while (lake_is_truthy(ctx, result) && LIST_N(expr) > 0)
    {
        result = lake_bool_and(ctx, result, eval(ctx, env, list_shift(expr)));
    }
    return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x2f38
cmpq $0x0, 0x18(%rbx)
je 0x17a0
movq %rbx, %rdi
callq 0x2f38
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %rax, %r12
jmp 0x17a4
movq 0x18(%r15), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x13c4
testl %eax, %eax
je 0x17e3
cmpq $0x0, 0x18(%rbx)
je 0x17e3
movq %rbx, %rdi
callq 0x2f38
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x1400
movq %rax, %r12
jmp 0x17a4
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: or
static LakeVal *_or(LakeCtx *ctx, Env *env, LakeList *expr)
{
    /* drop the "or" symbol */
    list_shift(expr);

    /* (or ...) */
    LakeVal *result =
        LIST_N(expr) ? eval(ctx, env, list_shift(expr)) : VAL(ctx->F);
    while (lake_is_falsy(ctx, result) && LIST_N(expr) > 0)
    {
        result = lake_bool_or(ctx, result, eval(ctx, env, list_shift(expr)));
    }
    return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x2f38
cmpq $0x0, 0x18(%rbx)
je 0x182d
movq %rbx, %rdi
callq 0x2f38
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %rax, %r12
jmp 0x1831
movq 0x20(%r15), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x13ce
testl %eax, %eax
je 0x1870
cmpq $0x0, 0x18(%rbx)
je 0x1870
movq %rbx, %rdi
callq 0x2f38
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x1416
movq %rax, %r12
jmp 0x1831
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: if
static LakeVal *_if(LakeCtx *ctx, Env *env, LakeList *expr)
{
    if (LIST_N(expr) != 3)
    {
        invalid_special_form(expr, "if requires 3 parameters");
        return NULL;
    }
    list_shift(expr); /* "if" token */
    LakeVal *cond = eval(ctx, env, list_shift(expr));
    if (lake_is_truthy(ctx, cond))
    {
        return eval(ctx, env, list_shift(expr));
    }
    else
    {
        return eval(ctx, env, LIST_VAL(expr, 1));
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
cmpq $0x3, 0x18(%rdx)
jne 0x18d4
movq %rsi, %rbx
movq %rdi, %r14
movq %r15, %rdi
callq 0x2f38
movq %r15, %rdi
callq 0x2f38
movq %r14, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x1dad
movq %r14, %rdi
movq %rax, %rsi
callq 0x13c4
testl %eax, %eax
je 0x18eb
movq %r15, %rdi
callq 0x2f38
movq %r14, %rdi
movq %rbx, %rsi
movq %rax, %rdx
jmp 0x1904
leaq 0x489b(%rip), %rsi      # 0x6176
movq %r15, %rdi
callq 0x22fa
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
cmpq $0x2, 0x18(%r15)
jb 0x18fc
movq 0x20(%r15), %rax
movq 0x8(%rax), %rdx
jmp 0x18fe
xorl %edx, %edx
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x1dad
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: when
static LakeVal *_when(LakeCtx *ctx, Env *env, LakeList *expr)
{
    if (LIST_N(expr) < 2)
    {
        invalid_special_form(expr, "when requires at least 2 parameters");
        return NULL;
    }
    list_shift(expr); /* "when" token */
    LakeVal *cond = eval(ctx, env, list_shift(expr));
    return lake_is_truthy(ctx, cond) ? eval_exprs1(ctx, env, expr) : NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
cmpq $0x1, 0x18(%rdx)
ja 0x192e
leaq 0x486b(%rip), %rsi      # 0x618f
movq %rbx, %rdi
callq 0x22fa
jmp 0x1974
movq %rsi, %r14
movq %rdi, %r15
movq %rbx, %rdi
callq 0x2f38
movq %rbx, %rdi
callq 0x2f38
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %r15, %rdi
movq %rax, %rsi
callq 0x13c4
testl %eax, %eax
je 0x1974
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x22d0
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: cond
static LakeVal *_cond(LakeCtx *ctx, Env *env, LakeList *expr)
{
    static LakeVal *ELSE = NULL;
    if (!ELSE) ELSE = VAL(sym_intern(ctx, "else"));

    list_shift(expr); /* "cond" token */
    LakeVal *pred;
    LakeList *conseq;
    while (LIST_N(expr))
    {
        if (!lake_is_type(TYPE_LIST, LIST_VAL(expr, 0)))
        {
            invalid_special_form(expr,
                                 "expected a (predicate consequence) pair");
            return NULL;
        }
        conseq = LIST(list_shift(expr));
        pred = list_shift(conseq);
        if (pred == ELSE || lake_is_truthy(ctx, eval(ctx, env, pred)))
        {
            return eval_exprs1(ctx, env, conseq);
        }
    }
    return NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
cmpq $0x0, 0x8793(%rip)      # 0xa128
jne 0x19ad
leaq 0x4815(%rip), %rsi      # 0x61b3
movq %r15, %rdi
callq 0x4c24
movq %rax, 0x877b(%rip)      # 0xa128
movq %rbx, %rdi
callq 0x2f38
pushq $0x5
popq %rbp
cmpq $0x0, 0x18(%rbx)
je 0x1a2f
movq 0x20(%rbx), %rax
movq (%rax), %rsi
movl %ebp, %edi
callq 0x2a6c
testl %eax, %eax
je 0x1a20
movq %rbx, %rdi
callq 0x2f38
movq %rax, %r12
movq %rax, %rdi
callq 0x2f38
cmpq 0x873d(%rip), %rax      # 0xa128
je 0x1a0a
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1dad
movq %r15, %rdi
movq %rax, %rsi
callq 0x13c4
testl %eax, %eax
je 0x19b8
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x22d0
leaq 0x4791(%rip), %rsi      # 0x61b8
movq %rbx, %rdi
callq 0x22fa
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: setB
static LakeVal *_setB(LakeCtx *ctx, Env *env, LakeList *expr)
{
    /* (set! x 42) */
    if (LIST_N(expr) == 3 && lake_is_type(TYPE_SYM, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "set!" symbol */
        LakeSym *var = SYM(list_shift(expr));
        LakeVal *form = list_shift(expr);
        if (!env_set(env, var, form))
        {
            ERR("%s is not defined", sym_repr(var));
        }
    }
    else
    {
        invalid_special_form(expr, "set! requires exactly 2 parameters");
    }
    return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
cmpq $0x3, 0x18(%rdx)
jne 0x1ada
movq %rsi, %rbx
movq 0x20(%r14), %rax
movq 0x8(%rax), %rsi
pushq $0x1
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1ada
movq %r14, %rdi
callq 0x2f38
movq %r14, %rdi
callq 0x2f38
movq %rax, %r15
movq %r14, %rdi
callq 0x2f38
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x161b
testq %rax, %rax
jne 0x1ae9
movq 0x855f(%rip), %r14      # 0x9ff8
movq (%r14), %rcx
leaq 0x45bb(%rip), %rdi      # 0x605e
pushq $0x7
popq %rsi
pushq $0x1
popq %rdx
callq 0x11f0
movq (%r14), %rbx
movq %r15, %rdi
callq 0x4cbb
leaq 0x4720(%rip), %rsi      # 0x61e0
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x1170
movq (%r14), %rsi
pushq $0xa
popq %rdi
callq 0x1100
jmp 0x1ae9
leaq 0x4711(%rip), %rsi      # 0x61f2
movq %r14, %rdi
callq 0x22fa
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: define
static LakeVal *_define(LakeCtx *ctx, Env *env, LakeList *expr)
{
    /* TODO: make these more robust, check all expected params */

    /* (define x 42) */
    if (LIST_N(expr) == 3 && lake_is_type(TYPE_SYM, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "define" symbol */
        LakeSym *var = SYM(list_shift(expr));
        LakeVal *form = list_shift(expr);
        env_define(env, var, eval(ctx, env, form));
    }

    /* (define (inc x) (+ 1 x)) */
    else if (LIST_N(expr) >= 3 && lake_is_type(TYPE_LIST, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "define" symbol */
        LakeList *params = LIST(list_shift(expr));
        LakeSym *var = SYM(list_shift(params));
        LakeList *body = expr;
        env_define(env, var, VAL(fn_make(params, NULL, body, env)));
    }

    /* (define (print format . args) (...)) */
    else if (LIST_N(expr) >= 3 && lake_is_type(TYPE_DLIST, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "define" symbol */
        LakeDottedList *def = DLIST(list_shift(expr));
        LakeList *params = dlist_head(def);
        LakeSym *varargs = SYM(dlist_tail(def));
        LakeSym *var = SYM(list_shift(params));
        LakeList *body = expr;
        env_define(env, var, VAL(fn_make(params, varargs, body, env)));
    }

    else
    {
        invalid_special_form(expr, "define requires at least 2 parameters");
    }

    return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %rbx
movq 0x18(%rdx), %rax
cmpq $0x3, %rax
jne 0x1b50
movq %rdi, %r15
movq 0x20(%r14), %rax
movq 0x8(%rax), %rsi
pushq $0x1
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1b4c
movq %r14, %rdi
callq 0x2f38
movq %r14, %rdi
callq 0x2f38
movq %rax, %r12
movq %r14, %rdi
callq 0x2f38
movq %r15, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x1dad
jmp 0x1b9c
movq 0x18(%r14), %rax
cmpq $0x3, %rax
jb 0x1c14
movq 0x20(%r14), %rax
movq 0x8(%rax), %rsi
pushq $0x5
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1bac
movq %r14, %rdi
callq 0x2f38
movq %r14, %rdi
callq 0x2f38
movq %rax, %r15
movq %rax, %rdi
callq 0x2f38
movq %rax, %r12
movq %r15, %rdi
xorl %esi, %esi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x2360
movq %rbx, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x1600
jmp 0x1c23
cmpq $0x3, 0x18(%r14)
jb 0x1c14
movq 0x20(%r14), %rax
movq 0x8(%rax), %rsi
pushq $0x6
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1c14
movq %r14, %rdi
callq 0x2f38
movq %r14, %rdi
callq 0x2f38
movq %rax, %r15
movq %rax, %rdi
callq 0x1454
movq %rax, %r12
movq %r15, %rdi
callq 0x1459
movq %rax, %r15
movq %r12, %rdi
callq 0x2f38
movq %rax, %r13
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x2360
movq %rbx, %rdi
movq %r13, %rsi
jmp 0x1ba2
leaq 0x45fa(%rip), %rsi      # 0x6215
movq %r14, %rdi
callq 0x22fa
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: lambda
static LakeVal *_lambda(LakeCtx *ctx, Env *env, LakeList *expr)
{
    /* (lambda (a b c) ...) */
    if (LIST_N(expr) >= 3 && lake_is_type(TYPE_LIST, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "lambda" symbol */
        LakeList *params = LIST(list_shift(expr));
        LakeList *body = expr;
        return VAL(fn_make(params, NULL, body, env));
    }
    else if (LIST_N(expr) >= 3 && lake_is_type(TYPE_DLIST, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "lambda" symbol */
        LakeDottedList *def = DLIST(list_shift(expr));
        LakeList *params = dlist_head(def);
        LakeSym *varargs = SYM(dlist_tail(def));
        LakeList *body = expr;
        return VAL(fn_make(params, varargs, body, env));
    }
    else if (LIST_N(expr) >= 3 && lake_is_type(TYPE_SYM, LIST_VAL(expr, 1)))
    {
        list_shift(expr); /* drop the "lambda" symbol */
        LakeSym *varargs = SYM(list_shift(expr));
        LakeList *body = expr;
        return VAL(fn_make(list_make(), varargs, body, env));
    }
    else
    {
        invalid_special_form(expr, "lambda requires at least 2 parameters");
        return NULL;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
cmpq $0x3, 0x18(%rdx)
jb 0x1d12
movq %rsi, %r14
movq 0x20(%rbx), %rax
movq 0x8(%rax), %rsi
pushq $0x5
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1c87
movq %rbx, %rdi
callq 0x2f38
movq %rbx, %rdi
callq 0x2f38
movq %rax, %rdi
xorl %esi, %esi
movq %rbx, %rdx
movq %r14, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x2360
cmpq $0x3, 0x18(%rbx)
jb 0x1d12
movq 0x20(%rbx), %rax
movq 0x8(%rax), %rsi
pushq $0x6
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1cd4
movq %rbx, %rdi
callq 0x2f38
movq %rbx, %rdi
callq 0x2f38
movq %rax, %r15
movq %rax, %rdi
callq 0x1454
movq %rax, %r12
movq %r15, %rdi
callq 0x1459
movq %r12, %rdi
movq %rax, %rsi
jmp 0x1c71
cmpq $0x3, 0x18(%rbx)
jb 0x1d12
movq 0x20(%rbx), %rax
movq 0x8(%rax), %rsi
pushq $0x1
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x1d12
movq %rbx, %rdi
callq 0x2f38
movq %rbx, %rdi
callq 0x2f38
movq %rax, %r15
callq 0x2d01
movq %rax, %rdi
movq %r15, %rsi
jmp 0x1c71
leaq 0x4522(%rip), %rsi      # 0x623b
movq %rbx, %rdi
callq 0x22fa
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: eval_exprs
LakeList *eval_exprs(LakeCtx *ctx, Env *env, LakeList *exprs)
{
    LakeList *results = list_make_with_capacity(LIST_N(exprs));
    int i;
    for (i = 0; i < LIST_N(exprs); ++i)
    {
        list_append(results, eval(ctx, env, LIST_VAL(exprs, i)));
    }
    return results;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq 0x18(%rdx), %rdi
callq 0x2d21
movq %rax, %r12
xorl %r13d, %r13d
cmpq %r13, 0x18(%rbx)
jbe 0x22c3
movq 0x20(%rbx), %rax
movq (%rax,%r13,8), %rdx
movq %r15, %rdi
movq %r14, %rsi
callq 0x1dad
movq %r12, %rdi
movq %rax, %rsi
callq 0x2e14
incq %r13
jmp 0x229a
movq %r12, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/eval.c
// Function: eval_exprs1
LakeVal *eval_exprs1(LakeCtx *ctx, Env *env, LakeList *exprs)
{
    LakeList *results = eval_exprs(ctx, env, exprs);
    LakeVal *result = list_pop(results);
    list_free(results);
    return result;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x2279
movq %rax, %rbx
movq %rax, %rdi
callq 0x2f6d
movq %rax, %r14
movq %rbx, %rdi
callq 0x2cfc
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/fn.c
// Function: fn_make
LakeFn *fn_make(LakeList *params, LakeSym *varargs, LakeList *body,
                Env *closure)
{
    LakeFn *fn = fn_alloc();
    fn->params = params;
    fn->varargs = varargs;
    fn->body = body;
    fn->closure = closure;
    return fn;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
pushq $0x30
popq %rdi
callq 0x11a0
movl $0x8, (%rax)
movq $0x30, 0x8(%rax)
movq %r12, 0x10(%rax)
movq %r15, 0x18(%rax)
movq %r14, 0x20(%rax)
movq %rbx, 0x28(%rax)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/fn.c
// Function: fn_repr
char *fn_repr(LakeFn *fn)
{
    char *s = malloc(8);
    s[0] = '\0';
    s = lake_str_append(s, "(lambda ");
    char *s2;
    if (LIST_N(fn->params) && fn->varargs)
    {
        LakeDottedList *params = dlist_make(fn->params, VAL(fn->varargs));
        s2 = dlist_repr(params);
        s = lake_str_append(s, s2);
        free(s2);
    }
    else if (fn->varargs)
    {
        s2 = lake_repr(fn->varargs);
        s = lake_str_append(s, s2);
        free(s2);
    }
    else
    {
        s2 = lake_repr(fn->params);
        s = lake_str_append(s, s2);
        free(s2);
    }
    s = lake_str_append(s, " ");
    int i;
    for (i = 0; i < LIST_N(fn->body); ++i)
    {
        s2 = lake_repr(LIST_VAL(fn->body, i));
        s = lake_str_append(s, s2);
        free(s2);
        if (i != LIST_N(fn->body) - 1) s = lake_str_append(s, " ");
    }
    return lake_str_append(s, ")");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
pushq $0x8
popq %rdi
callq 0x11a0
movb $0x0, (%rax)
leaq 0x3ebb(%rip), %rsi      # 0x627f
movq %rax, %rdi
callq 0x131c
movq %rax, %r14
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %rsi
cmpq $0x0, 0x18(%rdi)
je 0x23f2
testq %rsi, %rsi
je 0x23fa
callq 0x1424
movq %rax, %rdi
callq 0x145e
jmp 0x23ff
testq %rsi, %rsi
je 0x23fa
movq %rsi, %rdi
callq 0x2a74
movq %rax, %r15
movq %r14, %rdi
movq %rax, %rsi
callq 0x131c
movq %rax, %r12
movq %r15, %rdi
callq 0x1030
leaq 0x3bed(%rip), %r14      # 0x600c
movq %r12, %rdi
movq %r14, %rsi
callq 0x131c
movq %rax, %r15
xorl %r13d, %r13d
movq 0x20(%rbx), %rax
cmpq %r13, 0x18(%rax)
jbe 0x2483
movq 0x20(%rax), %rax
movq (%rax,%r13,8), %rdi
callq 0x2a74
movq %rax, %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x131c
movq %rax, %r15
movq %r12, %rdi
callq 0x1030
movq 0x20(%rbx), %rax
movq 0x18(%rax), %rax
decq %rax
cmpq %rax, %r13
je 0x247e
movq %r15, %rdi
movq %r14, %rsi
callq 0x131c
movq %rax, %r15
incq %r13
jmp 0x2430
leaq 0x3f2b(%rip), %rsi      # 0x63b5
movq %r15, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x131c
nop
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/./khash.h
// Function: _ac_X31_hash_string
static inline khint_t __ac_X31_hash_string(const char *s)
{
    khint_t h = *s;
    if (h)
        for (++s; *s; ++s)
            h = (h << 5) - h + *s;
    return h;
}

// Assembly:
movsbl (%rdi), %eax
testl %eax, %eax
je 0x29e1
incq %rdi
movsbl (%rdi), %ecx
testl %ecx, %ecx
je 0x29e3
imull $0x1f, %eax, %eax
addl %ecx, %eax
jmp 0x29d0
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/int.c
// Function: int_to_str
LakeStr *int_to_str(LakeInt *i)
{
    char *s = int_repr(i);
    LakeStr *str = lake_str_from_c(s);
    free(s);
    return str;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x2a09
movq %rax, %rbx
movq %rax, %rdi
callq 0x4b86
movq %rax, %r14
movq %rbx, %rdi
callq 0x1030
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/lake.c
// Function: lake_repr
char *lake_repr(void *expr)
{
    if (expr == NULL) return strdup("(null)");

    char *s = NULL;

    LakeVal *e = VAL(expr);
    switch (e->type)
    {

    case TYPE_SYM:
        s = sym_repr(SYM(e));
        break;

    case TYPE_BOOL:
        s = lake_bool_repr(BOOL(e));
        break;

    case TYPE_INT:
        s = int_repr(INT(e));
        break;

    case TYPE_STR:
    {
        // +3 for surrounding quotes and null terminator
        size_t n = strlen(STR_S(STR(e))) + 3;
        s = malloc(n);
        /* TODO: quote the string */
        snprintf(s, n, "\"%s\"", STR_S(STR(e)));
        break;
    }

    case TYPE_LIST:
        s = list_repr(LIST(e));
        break;

    case TYPE_DLIST:
        s = dlist_repr(DLIST(e));
        break;

    case TYPE_PRIM:
        s = prim_repr(PRIM(e));
        break;

    case TYPE_FN:
        s = fn_repr(FN(e));
        break;

    case TYPE_COMM:
        s = comment_repr(COMM(e));
        break;

    default:
        // If it wasn't a LakeVal we already crashed at the beginning of the
        // switch, so go ahead and print out the size too.
        fprintf(stderr, "error: unrecognized value, type %d, size %zu bytes",
                e->type, e->size);
        s = strdup("(unknown)");
    }

    return s;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x2aa6
movl (%rdi), %edx
leal -0x1(%rdx), %eax
cmpl $0x8, %eax
ja 0x2b38
leaq 0x3809(%rip), %rcx      # 0x629c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
popq %rbx
popq %r14
popq %r15
jmp 0x4cbb
leaq 0x385b(%rip), %rdi      # 0x6308
popq %rbx
popq %r14
popq %r15
jmp 0x1200
popq %rbx
popq %r14
popq %r15
jmp 0x301b
popq %rbx
popq %r14
popq %r15
jmp 0x2a09
movq 0x18(%rdi), %rbx
movq %rbx, %rdi
callq 0x10b0
leaq 0x3(%rax), %r14
movq %r14, %rdi
callq 0x11a0
movq %rax, %r15
leaq 0x3822(%rip), %rdx      # 0x630f
movq %rax, %rdi
movq %r14, %rsi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x10d0
movq %r15, %rax
popq %rbx
popq %r14
popq %r15
retq
popq %rbx
popq %r14
popq %r15
jmp 0x23a6
popq %rbx
popq %r14
popq %r15
jmp 0x13e5
popq %rbx
popq %r14
popq %r15
jmp 0x145e
popq %rbx
popq %r14
popq %r15
jmp 0x3996
popq %rbx
popq %r14
popq %r15
jmp 0x138b
movq 0x74b9(%rip), %rax      # 0x9ff8
movq (%rax), %rax
movq 0x8(%rdi), %rcx
leaq 0x37c7(%rip), %rsi      # 0x6314
movq %rax, %rdi
xorl %eax, %eax
callq 0x1170
leaq 0x37e9(%rip), %rdi      # 0x6347
jmp 0x2aad
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/lake.c
// Function: lake_is
bool lake_is(LakeVal *a, LakeVal *b)
{
    if (lake_is_type(TYPE_INT, a) && lake_is_type(TYPE_INT, b))
    {
        return INT_VAL(INT(a)) == INT_VAL(INT(b));
    }
    if (lake_is_nil(a) && lake_is_nil(b)) return TRUE;
    return a == b;
}

// Assembly:
movl (%rdi), %eax
cmpl $0x5, %eax
je 0x2b8e
cmpl $0x3, %eax
jne 0x2ba1
cmpl $0x3, (%rsi)
jne 0x2ba1
movl 0x10(%rdi), %eax
cmpl 0x10(%rsi), %eax
jmp 0x2ba4
cmpq $0x0, 0x18(%rdi)
jne 0x2ba1
cmpl $0x5, (%rsi)
jne 0x2ba1
cmpq $0x0, 0x18(%rsi)
je 0x2bab
cmpq %rsi, %rdi
sete %al
movzbl %al, %eax
retq
movb $0x1, %al
jmp 0x2ba7
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/lake.c
// Function: lake_equal
bool lake_equal(LakeVal *a, LakeVal *b)
{
    if (a->type != b->type) return FALSE;
    switch (a->type)
    {

    /* singletons can be compared directly */
    case TYPE_SYM:
    case TYPE_BOOL:
    case TYPE_PRIM:
    case TYPE_FN:
        return a == b;

    case TYPE_INT:
        return INT_VAL(INT(a)) == INT_VAL(INT(b));

    case TYPE_STR:
        return lake_str_equal(STR(a), STR(b));

    case TYPE_LIST:
        return list_equal(LIST(a), LIST(b));

    case TYPE_DLIST:
        return dlist_equal(DLIST(a), DLIST(b));

    case TYPE_COMM:
        return comment_equal(COMM(a), COMM(b));

    default:
        ERR("unknown type %d (%s)", a->type, type_name(a));
        return FALSE;
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl (%rdi), %eax
xorl %ebp, %ebp
cmpl (%rsi), %eax
jne 0x2bde
movq %rdi, %rbx
decl %eax
cmpl $0x8, %eax
ja 0x2c1f
leaq 0x36f4(%rip), %rcx      # 0x62c0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
xorl %ebp, %ebp
cmpq %rsi, %rbx
sete %bpl
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x155b
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x4bf6
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x2f8a
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x139c
movl 0x10(%rbx), %eax
xorl %ebp, %ebp
cmpl 0x10(%rsi), %eax
jmp 0x2bda
movq 0x73d2(%rip), %r14      # 0x9ff8
movq (%r14), %rcx
leaq 0x342e(%rip), %rdi      # 0x605e
pushq $0x7
popq %rsi
pushq $0x1
popq %rdx
callq 0x11f0
movq (%r14), %rdi
movl (%rbx), %edx
cmpq $0x8, %rdx
ja 0x2c56
leaq 0x3697(%rip), %rax      # 0x62e4
movslq (%rax,%rdx,4), %rcx
addq %rax, %rcx
jmp 0x2c5d
leaq 0x374a(%rip), %rcx      # 0x63a7
leaq 0x36ed(%rip), %rsi      # 0x6351
xorl %ebp, %ebp
xorl %eax, %eax
callq 0x1170
movq (%r14), %rsi
pushq $0xa
popq %rdi
callq 0x1100
jmp 0x2bde
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/lake.c
// Function: lake_init
LakeCtx *lake_init(void)
{
    LakeCtx *ctx = malloc(sizeof(LakeCtx));
    ctx->toplevel = env_make(NULL);
    ctx->symbols = lake_hash_make();
    ctx->special_form_handlers = lake_hash_make();
    ctx->T = bool_make(TRUE);
    ctx->F = bool_make(FALSE);
    bind_primitives(ctx);
    init_special_form_handlers(ctx);
    return ctx;
}

// Assembly:
pushq %rbx
pushq $0x28
popq %rdi
callq 0x11a0
movq %rax, %rbx
xorl %edi, %edi
callq 0x15a0
movq %rax, (%rbx)
callq 0x2cef
movq %rax, 0x8(%rbx)
callq 0x2cef
movq %rax, 0x10(%rbx)
pushq $0x1
popq %rdi
callq 0x2cd1
movq %rax, 0x18(%rbx)
xorl %edi, %edi
callq 0x2cd1
movq %rax, 0x20(%rbx)
movq %rbx, %rdi
callq 0x39e6
movq %rbx, %rdi
callq 0x1678
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/lake.c
// Function: bool_make
static LakeBool *bool_make(bool val)
{
    LakeBool *b = malloc(sizeof(LakeBool));
    VAL(b)->type = TYPE_BOOL;
    VAL(b)->size = sizeof(LakeBool);
    b->val = val;
    return b;
}

// Assembly:
pushq %rbx
movl %edi, %ebx
pushq $0x18
popq %rdi
callq 0x11a0
movl $0x2, (%rax)
movq $0x18, 0x8(%rax)
movl %ebx, 0x10(%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_make_with_capacity
LakeList *list_make_with_capacity(size_t cap)
{
    LakeList *list = list_alloc();
    list->cap = cap;
    list->n = 0;
    list->vals = malloc(cap * sizeof(LakeVal *));
    return list;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
pushq $0x28
popq %rdi
callq 0x11a0
movq %rax, %r14
movl $0x5, (%rax)
movq $0x28, 0x8(%rax)
movq %rbx, 0x10(%rax)
andq $0x0, 0x18(%rax)
shlq $0x3, %rbx
movq %rbx, %rdi
callq 0x11a0
movq %rax, 0x20(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_cons
LakeList *list_cons(LakeVal *car, LakeVal *cdr)
{
    LakeList *list;
    if (lake_is_type(TYPE_LIST, cdr))
    {
        list = LIST(cdr);
        list_unshift(list, car);
    }
    else
    {
        list = list_make_with_capacity(2);
        list_append(list, car);
        list_append(list, cdr);
    }
    return list;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x5
popq %rdi
callq 0x2a6c
testl %eax, %eax
je 0x2d89
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2db6
jmp 0x2dad
pushq $0x2
popq %rdi
callq 0x2d21
movq %rax, %r15
movq %rax, %rdi
movq %r14, %rsi
callq 0x2e14
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2e14
movq %r15, %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_unshift
LakeVal *list_unshift(LakeList *list, LakeVal *val)
{
    if (list->n == 0)
    {
        list_append(list, val);
    }
    else
    {
        if (list->n >= list->cap)
        {
            list_grow(list);
        }
        size_t i = list->n++;
        do
        {
            list->vals[i] = list->vals[i - 1];
        } while (i--);
        list->vals[0] = val;
    }
    return NULL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rdi), %rax
testq %rax, %rax
je 0x2dff
cmpq 0x10(%r14), %rax
jb 0x2ddb
movq %r14, %rdi
callq 0x2ec6
movq 0x18(%r14), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x18(%r14)
movq 0x20(%r14), %rcx
movq -0x8(%rcx,%rax,8), %rdx
movq %rdx, (%rcx,%rax,8)
addq $-0x1, %rax
jb 0x2de3
movq 0x20(%r14), %rax
movq %rbx, (%rax)
jmp 0x2e0a
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2e14
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_append
LakeVal *list_append(LakeList *list, LakeVal *val)
{
    if (list->n >= list->cap)
    {
        list_grow(list);
    }
    list->vals[list->n++] = val;
    return NULL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rdi), %rax
cmpq 0x10(%rdi), %rax
jb 0x2e34
movq %r14, %rdi
callq 0x2ec6
movq 0x18(%r14), %rax
movq 0x20(%r14), %rcx
leaq 0x1(%rax), %rdx
movq %rdx, 0x18(%r14)
movq %rbx, (%rcx,%rax,8)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_from_array
LakeList *list_from_array(size_t n, LakeVal *vals[])
{
    LakeList *list = list_make_with_capacity(n);
    memcpy(list->vals, vals, n * sizeof(LakeVal *));
    list->n = n;
    return list;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
callq 0x2d21
movq %rax, %r15
movq 0x20(%rax), %rdi
leaq (,%r14,8), %rdx
movq %rbx, %rsi
callq 0x1190
movq %r14, 0x18(%r15)
movq %r15, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_shift
LakeVal *list_shift(LakeList *list)
{
    LakeVal *head = NULL;
    if (list->n > 0)
    {
        head = list->vals[0];
        size_t i;
        size_t n = list->n;
        for (i = 1; i < n; ++i)
        {
            list->vals[i - 1] = list->vals[i];
        }
        list->n--;
    }
    return head;
}

// Assembly:
movq 0x18(%rdi), %rcx
testq %rcx, %rcx
je 0x2f6a
movq 0x20(%rdi), %rax
movq (%rax), %rax
pushq $0x1
popq %rdx
cmpq %rdx, %rcx
je 0x2f62
movq 0x20(%rdi), %rsi
movq (%rsi,%rdx,8), %r8
movq %r8, -0x8(%rsi,%rdx,8)
incq %rdx
jmp 0x2f4b
decq %rcx
movq %rcx, 0x18(%rdi)
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_equal
bool list_equal(LakeList *a, LakeList *b)
{
    if (a == b) return TRUE;
    size_t n = LIST_N(a);
    if (n != LIST_N(b)) return FALSE;
    size_t i;
    for (i = 0; i < n; ++i)
    {
        if (!lake_equal(LIST_VAL(a, i), LIST_VAL(b, i))) return FALSE;
    }
    return TRUE;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq $0x1
popq %rbx
cmpq %rsi, %rdi
je 0x2fe5
movq %rsi, %r14
movq %rdi, %r15
movq 0x18(%rdi), %r12
cmpq 0x18(%rsi), %r12
jne 0x2fe3
xorl %r13d, %r13d
cmpq %r13, %r12
je 0x2fe5
cmpq 0x18(%r15), %r13
jae 0x2fc3
movq 0x20(%r15), %rax
movq (%rax,%r13,8), %rdi
jmp 0x2fc5
xorl %edi, %edi
cmpq 0x18(%r14), %r13
jae 0x2fd5
movq 0x20(%r14), %rax
movq (%rax,%r13,8), %rsi
jmp 0x2fd7
xorl %esi, %esi
callq 0x2baf
incq %r13
testl %eax, %eax
jne 0x2fae
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/samsonjs[P]lake/src/list.c
// Function: list_to_str
LakeStr *list_to_str(LakeList *list)
{
    char *s = list_repr(list);
    LakeStr *str = lake_str_from_c(s);
    free(s);
    return str;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
callq 0x301b
movq %rax, %rbx
movq %rax, %rdi
callq 0x4b86
movq %rax, %r14
movq %rbx, %rdi
callq 0x1030
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq