LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/stefpant[P]TCPserver/webserver/webserver.c
// Function: threadExec
void *threadExec(void * rootdir){
	char *buf;
	char *page = NULL;
	char *ans = NULL;
	int anslen;
	char *rdir = (char *)rootdir;
	char *rdpage = NULL;
	int reqerr,localbytes;
	while( 1 ){//try to obtain a file desc and exit if u obtain -1
		buf = NULL;//malloc(10*sizeof(char));
		int data;
		data = obtain(&ra);
		//printf("thread: %d\n",data);
		pthread_cond_signal(&cv_notfull);
		if( data == -1) break;
		pthread_mutex_lock(&mtxcounter);
		totalrc++;
		pthread_mutex_unlock(&mtxcounter);
		while( (buf = read_request(data,BUFFERSIZE)) == NULL ){}//in case client haven't answered yet,repeat
		//printf("buf= %s\n",buf);
		reqerr = analyze_request(buf,&page);
		if(page != NULL){
			rdpage = (char *)malloc((strlen(page) + strlen(rdir) + 1)*sizeof(char));
			strcpy(rdpage,rdir);
			strcat(rdpage,page);
		}
		//printf("%s\n",rdpage);
		ans = create_answer(&anslen,rdpage,reqerr,&localbytes);
		pthread_mutex_lock(&mtxbytes);
		totalBytes += localbytes;
		pthread_mutex_unlock(&mtxbytes);
		//printf("%s\n",ans);
		write(data,ans,anslen);
		close(data);
		free(page);
		free(ans);
		free(rdpage);
		free(buf);
	}
	free(buf);
	printf("thread exiting...\n");
	return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
leaq -0x30(%rbp), %rax
andq $0x0, (%rax)
movq %rdi, -0x48(%rbp)
xorl %ebx, %ebx
leaq 0x3030(%rip), %rdi      # 0x6258
callq 0x3194
movl %eax, %r12d
leaq 0x2fc1(%rip), %rdi      # 0x61f8
callq 0x2150
cmpl $-0x1, %r12d
je 0x3341
leaq 0x3013(%rip), %r14      # 0x6260
movq %r14, %rdi
callq 0x2340
incl 0x2f6d(%rip)            # 0x61c8
movq %r14, %rdi
callq 0x21d0
movl %r12d, %edi
movl $0x80, %esi
callq 0x26ac
testq %rax, %rax
je 0x3263
movq %rax, %r13
movq %rax, %rdi
leaq -0x30(%rbp), %rsi
callq 0x2758
movq -0x30(%rbp), %r14
testq %r14, %r14
je 0x32cf
movq %r14, %rdi
movl %eax, -0x34(%rbp)
callq 0x20e0
movq %rax, %rbx
movq -0x48(%rbp), %r15
movq %r15, %rdi
callq 0x20e0
leaq (%rbx,%rax), %rdi
incq %rdi
callq 0x21e0
movq %rax, %rbx
movq %rax, %rdi
movq %r15, %rsi
callq 0x2070
movq %rbx, %rdi
movq %r14, %rsi
callq 0x22e0
movl -0x34(%rbp), %eax
leaq -0x3c(%rbp), %rdi
movq %rbx, %rsi
movl %eax, %edx
leaq -0x38(%rbp), %rcx
callq 0x2945
movq %rax, %r14
leaq 0x2f9d(%rip), %r15      # 0x6288
movq %r15, %rdi
callq 0x2340
movl -0x38(%rbp), %eax
addl %eax, 0x2ed0(%rip)      # 0x61cc
movq %r15, %rdi
callq 0x21d0
movslq -0x3c(%rbp), %rdx
movl %r12d, %edi
movq %r14, %rsi
callq 0x20b0
movl %r12d, %edi
callq 0x2130
movq -0x30(%rbp), %rdi
callq 0x2030
movq %r14, %rdi
callq 0x2030
movq %rbx, %rdi
callq 0x2030
movq %r13, %rdi
callq 0x2030
jmp 0x3221
leaq 0x10cf(%rip), %rdi      # 0x4417
callq 0x2090
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/CSerxzm[P]WindowstoLinuxInterface/src/DEL.c
// Function: del_file
int del_file(const char *dir){
    DIR* dirp;
    struct dirent *dp;
    struct stat dir_stat;
    char dir_name[255];

    if(access(dir,F_OK)!=0){
        return 0;
    }
    if(stat(dir, &dir_stat)<0){
        perror("失败!\n");
        return -1;
    } 
    if(S_ISREG(dir_stat.st_mode)){
        remove(dir);
    }
    else{
        perror("error!\n");
    }

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x90, %rsp
movq %rdi, %r14
xorl %ebx, %ebx
xorl %esi, %esi
callq 0x1070
testl %eax, %eax
jne 0x12cf
leaq -0xa0(%rbp), %rsi
movq %r14, %rdi
callq 0x1060
testl %eax, %eax
js 0x12dd
movl $0xf000, %eax           # imm = 0xF000
andl -0x88(%rbp), %eax
cmpl $0x8000, %eax           # imm = 0x8000
jne 0x12ee
movq %r14, %rdi
callq 0x1030
movl %ebx, %eax
addq $0x90, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0xd20(%rip), %rdi       # 0x2004
callq 0x1080
pushq $-0x1
popq %rbx
jmp 0x12cf
leaq 0xd18(%rip), %rdi       # 0x200d
callq 0x1080
jmp 0x12cf
// File: /workspace/github_c_makefile_star2_O2/CSerxzm[P]WindowstoLinuxInterface/src/DEL.c
// Function: main
int main(int argc, char** argv){
    char lines[argc+1][255];
    predealLine(argc, argv, lines);

    if((strcmp("DEL",lines[0])==0)||(strcmp("del",lines[0])==0)){
        for(int i=1;i<argc;i++){
            del_file(lines[i]);
        }
    }
    else{
        perror("error after lines\n");
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %r14d
leal 0x1(%r14), %eax
movq %rsp, %rbx
imulq $0xff, %rax, %rax
addq $0xf, %rax
andq $-0x10, %rax
subq %rax, %rbx
movq %rbx, %rsp
movq %rbx, %rdx
callq 0x11ac
leaq 0xce1(%rip), %rdi       # 0x2015
movq %rbx, %rsi
callq 0x1050
testl %eax, %eax
je 0x1353
leaq 0xcd2(%rip), %rdi       # 0x2019
movq %rbx, %rsi
callq 0x1050
testl %eax, %eax
jne 0x137a
movslq %r14d, %r14
addq $0xff, %rbx
pushq $0x1
popq %r15
cmpq %r14, %r15
jge 0x1386
movq %rbx, %rdi
callq 0x1284
incq %r15
addq $0xff, %rbx
jmp 0x1361
leaq 0xc9c(%rip), %rdi       # 0x201d
callq 0x1080
xorl %eax, %eax
leaq -0x18(%rbp), %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/enzo1982[P]smooth/tools/pciffmanager/main.cpp
// Function: PCIFFManager::OpenFile()
Void PCIFFManager::OpenFile()
{
	FileSelection	 dialog;

	dialog.SetParentWindow(wnd);

	dialog.AddFilter("PCI Image Files", "*.pci");
	dialog.AddFilter("All Files", "*.*");

	if (dialog.ShowDialog() == Success())
	{
		filename = dialog.GetFileName();

		String	 file = filename.Tail(filename.Length() - filename.FindLast(Directory::GetDirectoryDelimiter()) - 1);

		wnd->SetText(String("smooth PCIFF Manager v").Append(SMOOTH_VERSION).Append(" - ").Append(file));
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x7a0, %rsp            # imm = 0x7A0
movq %rdi, %rbx
leaq 0x60(%rsp), %r14
movq %r14, %rdi
callq 0x3340
movq 0x5b8(%rbx), %rsi
movq %r14, %rdi
callq 0x3080
leaq 0x164b(%rip), %rsi      # 0x5066
leaq 0x18(%rsp), %rdi
callq 0x3330
leaq 0x164a(%rip), %rsi      # 0x5076
movq %rsp, %rdi
callq 0x3330
leaq 0x60(%rsp), %rdi
leaq 0x18(%rsp), %rsi
movq %rsp, %rdx
callq 0x3120
movq %rsp, %rdi
callq 0x31f0
leaq 0x18(%rsp), %rdi
callq 0x31f0
leaq 0x161d(%rip), %rsi      # 0x507c
leaq 0x18(%rsp), %rdi
callq 0x3330
leaq 0x1616(%rip), %rsi      # 0x5086
movq %rsp, %rdi
callq 0x3330
leaq 0x60(%rsp), %rdi
leaq 0x18(%rsp), %rsi
movq %rsp, %rdx
callq 0x3120
movq %rsp, %rdi
callq 0x31f0
leaq 0x18(%rsp), %rdi
callq 0x31f0
leaq 0x60(%rsp), %rdi
callq 0x31b0
movq 0x4543(%rip), %rcx      # 0x7ff0
addq $0x10, %rcx
leaq 0x18(%rsp), %rsi
movq %rcx, (%rsi)
andl $0x0, 0x8(%rsi)
movq (%rax), %rcx
movq %rax, %rdi
callq *0x18(%rcx)
testb %al, %al
je 0x3bc1
leaq 0x60(%rsp), %rdi
callq 0x3090
leaq 0x5e0(%rbx), %r14
movq %r14, %rdi
movq %rax, %rsi
callq 0x3250
movq %r14, %rdi
callq 0x3140
movl %eax, %ebp
callq 0x3060
movq %rsp, %rdi
movq %rax, %rsi
callq 0x3330
movq %rsp, %rsi
movq %r14, %rdi
callq 0x31e0
notl %eax
addl %eax, %ebp
leaq 0x18(%rsp), %rdi
movq %r14, %rsi
movl %ebp, %edx
callq 0x3190
movq %rsp, %rdi
callq 0x31f0
movq 0x5b8(%rbx), %rbx
leaq 0x14fb(%rip), %rsi      # 0x5033
movq %rsp, %rdi
callq 0x3330
leaq 0x1503(%rip), %rsi      # 0x504a
leaq 0x48(%rsp), %rdi
callq 0x3330
movq %rsp, %rdi
leaq 0x48(%rsp), %rsi
callq 0x30c0
movq %rax, %r14
leaq 0x1522(%rip), %rsi      # 0x508a
leaq 0x30(%rsp), %rdi
callq 0x3330
leaq 0x30(%rsp), %rsi
movq %r14, %rdi
callq 0x30c0
leaq 0x18(%rsp), %rsi
movq %rax, %rdi
callq 0x30c0
movq (%rbx), %rcx
movq %rbx, %rdi
movq %rax, %rsi
callq *0xa0(%rcx)
leaq 0x30(%rsp), %rdi
callq 0x31f0
leaq 0x48(%rsp), %rdi
callq 0x31f0
movq %rsp, %rdi
callq 0x31f0
leaq 0x18(%rsp), %rdi
callq 0x31f0
leaq 0x60(%rsp), %rdi
callq 0x3230
addq $0x7a0, %rsp            # imm = 0x7A0
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x3bd9
movq %rax, %rbx
jmp 0x3c0f
jmp 0x3bf6
jmp 0x3bfb
jmp 0x3c2d
movq %rax, %rbx
movq %rsp, %rdi
jmp 0x3c26
jmp 0x3c2d
jmp 0x3c2d
jmp 0x3bf6
jmp 0x3bfb
jmp 0x3c2d
movq %rax, %rbx
jmp 0x3c19
movq %rax, %rbx
jmp 0x3c21
jmp 0x3c2d
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x31f0
leaq 0x48(%rsp), %rdi
callq 0x31f0
movq %rsp, %rdi
callq 0x31f0
leaq 0x18(%rsp), %rdi
callq 0x31f0
jmp 0x3c30
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x3230
movq %rbx, %rdi
callq 0x3150
// File: /workspace/github_c_makefile_star2_O2/enzo1982[P]smooth/tools/pciffmanager/main.cpp
// Function: PCIFFManager::~PCIFFManager()
PCIFFManager::~PCIFFManager()
{
	DeleteObject(title);
	DeleteObject(wnd);
	DeleteObject(menubar);
	DeleteObject(menu_file);
	DeleteObject(statusbar);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x3e97(%rip), %rax      # 0x7af0
movq %rax, (%rdi)
movq 0x5c0(%rdi), %rdi
callq 0x33b0
movq 0x5b8(%rbx), %rdi
callq 0x33b0
movq 0x5c8(%rbx), %rdi
callq 0x33b0
movq 0x5d8(%rbx), %rdi
callq 0x33b0
movq 0x5d0(%rbx), %rdi
callq 0x33b0
leaq 0x5e0(%rbx), %rdi
callq 0x31f0
movq %rbx, %rdi
popq %rbx
jmp 0x3210
movq %rax, %rdi
callq 0x3def
nop
// File: /workspace/github_c_makefile_star2_O2/kilobyte[P]colormatch/243-256.c
// Function: main
int main()
{
    for (int c = 0; c < 16777216; ++c)
    {
        nt[c] = closest(c);
        if (!(c&0xff))
            printf("%06X\n", c);
    }

    int fd = creat("243.rgb", 0666);
    write(fd, nt, sizeof(nt));
    close(fd);

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl $0xff, %r15d
xorl %r14d, %r14d
cmpq $0x1000000, %r14        # imm = 0x1000000
je 0x1243
movl %r14d, %eax
shrl $0x10, %eax
movl %eax, 0xc(%rsp)
movl %r14d, %ebx
shrl $0x8, %ebx
andl %r15d, %ebx
movq %r14, 0x10(%rsp)
movl %r14d, %r12d
andl %r15d, %r12d
xorl %ebp, %ebp
movl $0x7fffffff, %r14d      # imm = 0x7FFFFFFF
xorl %r13d, %r13d
cmpl $0x100, %ebp            # imm = 0x100
je 0x1215
movl %ebp, %edi
callq 0x1284
movl %eax, %ecx
shrl $0x10, %ecx
movl %eax, %edx
shrl $0x8, %edx
andl %r15d, %ecx
subl 0xc(%rsp), %ecx
imull %ecx, %ecx
andl %r15d, %edx
subl %ebx, %edx
imull %edx, %edx
andl %r15d, %eax
subl %r12d, %eax
imull %eax, %eax
leal (%rax,%rax,2), %eax
leal (%rax,%rdx,4), %eax
leal (%rax,%rcx,2), %eax
cmpl %r14d, %eax
cmovll %eax, %r14d
cmovll %ebp, %r13d
incl %ebp
jmp 0x11c9
leaq 0x2e44(%rip), %rax      # 0x4060
movq 0x10(%rsp), %r14
movb %r13b, (%r14,%rax)
testl %r12d, %r12d
jne 0x123b
leaq 0xdd3(%rip), %rdi       # 0x2004
movl %r14d, %esi
xorl %eax, %eax
callq 0x1050
incq %r14
jmp 0x1193
leaq 0xdc0(%rip), %rdi       # 0x200a
movl $0x1b6, %esi            # imm = 0x1B6
callq 0x1070
movl %eax, %ebx
leaq 0x2e03(%rip), %rsi      # 0x4060
movl $0x1000000, %edx        # imm = 0x1000000
movl %eax, %edi
callq 0x1040
movl %ebx, %edi
callq 0x1060
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/sort_bucket/main.c
// Function: printArray
void printArray(int array[], int n){
    int i;
    for(i=0;i<n;i++){
        printf("%d ",array[i]);
    }
    printf("\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
xorl %eax, %eax
testl %esi, %esi
cmovlel %eax, %ebx
leaq 0xe8a(%rip), %r15       # 0x2004
xorl %r12d, %r12d
cmpq %r12, %rbx
je 0x1195
movl (%r14,%r12,4), %esi
movq %r15, %rdi
xorl %eax, %eax
callq 0x1040
incq %r12
jmp 0x117d
pushq $0xa
popq %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O2/mcxiaoke[P]dsaac/ch3/sort_bucket/main.c
// Function: main
int main(int argc, char **argv)
{
    int i;
    for(i=0;i<10;i++){
        nums[i]=rand()%100;
    }
    
    int j;
    for(j=0;j<10;j++){
        bucket[nums[j]]++;
    }
    
    printArray(nums,10);
    int k;
    for(k=0;k<100;k++){
        if(bucket[k]==1){
            printf("%d ",k);
        }
    }
	printf("\n");
    
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
xorl %r14d, %r14d
pushq $0x64
popq %r15
leaq 0x2e93(%rip), %rbx      # 0x4050
cmpq $0x28, %r14
je 0x11d6
callq 0x1050
cltd
idivl %r15d
movl %edx, (%r14,%rbx)
addq $0x4, %r14
jmp 0x11bd
xorl %eax, %eax
leaq 0x2ea1(%rip), %r15      # 0x4080
cmpq $0x28, %rax
je 0x11f3
movslq (%rax,%rbx), %rcx
incl (%r15,%rcx,4)
addq $0x4, %rax
jmp 0x11df
leaq 0x2e56(%rip), %rdi      # 0x4050
pushq $0xa
popq %rsi
callq 0x115c
leaq 0xdfb(%rip), %rbx       # 0x2004
xorl %r14d, %r14d
cmpq $0x64, %r14
je 0x122e
cmpl $0x1, (%r15)
jne 0x1225
movq %rbx, %rdi
movl %r14d, %esi
xorl %eax, %eax
callq 0x1040
incq %r14
addq $0x4, %r15
jmp 0x120c
pushq $0xa
popq %rdi
callq 0x1030
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/yueyoum[P]termgif/record.c
// Function: main
int main(int argc, char *argv[])
{
    Display *d = XOpenDisplay(NULL);
    if (d==NULL) {
        fprintf(stderr, "can not connect x server!\n");
        exit(2);
    }
    Window active;
    int revert;
    XWindowAttributes attr;

    XGetInputFocus(d, &active, &revert);
    /* active = current_window(d); */
    active = target_window(d);
    XGetWindowAttributes(d, active, &attr);

    int width = attr.width;
    int height = attr.height;
    printf("%d, %d, %d, %d\n", attr.x, attr.y, width, height);


    struct timeval delay;
    delay.tv_sec = 0;
    int i;
    char name[12] = {'\0'};
    XImage *image = XGetImage(d, active, 0, 0, width, height, AllPlanes, ZPixmap);
    init_wjpeg(image->width, image->height);

    for(i = 0; i<20; i++)
    {
        sprintf(name, "test_%02d.jpg", i);
        printf("%s\n", name);
        fflush(stdout);
        image = XGetImage(d, active, 0, 0, width, height, AllPlanes, ZPixmap);
        write_jpeg(image, name);
        delay.tv_usec = 500 * 1000;
        select(0, NULL, NULL, NULL, &delay);
    }

    destroy_wjpeg();
    XCloseDisplay(d);
    return(0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
xorl %edi, %edi
callq 0x20b0
testq %rax, %rax
je 0x2407
movq %rax, %rbx
leaq -0x30(%rbp), %r12
leaq -0x34(%rbp), %rdx
movq %rax, %rdi
movq %r12, %rsi
callq 0x2190
movq %rbx, %rdi
callq 0x25f8
movq %rax, (%r12)
leaq -0xe0(%rbp), %r13
movq %rbx, %rdi
movq %rax, %rsi
movq %r13, %rdx
callq 0x2110
movl 0x8(%r13), %r14d
movl 0xc(%r13), %r15d
movl (%r13), %esi
movl 0x4(%r13), %edx
leaq 0x2ed01(%rip), %rdi     # 0x3101f
movl %r14d, %ecx
movl %r15d, %r8d
xorl %eax, %eax
callq 0x2090
leaq -0x48(%rbp), %rax
andq $0x0, (%rax)
leaq -0x58(%rbp), %r13
andl $0x0, 0x8(%r13)
andq $0x0, (%r13)
movq (%r12), %rsi
movq %rbx, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
movl %r14d, %r8d
movl %r15d, %r9d
pushq $0x2
pushq $-0x1
callq 0x2180
addq $0x10, %rsp
movl (%rax), %edi
movl 0x4(%rax), %esi
callq 0x242c
xorl %r12d, %r12d
cmpl $0x14, %r12d
je 0x23e4
movq %r13, %rdi
leaq 0x2ecb3(%rip), %rsi     # 0x3102f
movl %r12d, %edx
xorl %eax, %eax
callq 0x2130
movq %r13, %rdi
callq 0x2050
movq 0x6ebab(%rip), %rax     # 0x70f40
movq (%rax), %rdi
callq 0x20f0
movq -0x30(%rbp), %rsi
movq %rbx, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
movl %r14d, %r8d
movl %r15d, %r9d
pushq $0x2
pushq $-0x1
callq 0x2180
addq $0x10, %rsp
movq %rax, %rdi
movq %r13, %rsi
callq 0x2474
movq $0x7a120, -0x40(%rbp)   # imm = 0x7A120
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
leaq -0x48(%rbp), %r8
callq 0x20d0
incl %r12d
jmp 0x236c
xorl %eax, %eax
callq 0x2457
movq %rbx, %rdi
callq 0x2170
xorl %eax, %eax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x6ebd2(%rip), %rax     # 0x70fe0
movq (%rax), %rcx
leaq 0x2ebec(%rip), %rdi     # 0x31004
pushq $0x1a
popq %rsi
pushq $0x1
popq %rdx
callq 0x2150
pushq $0x2
popq %rdi
callq 0x2140
nop
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Env_find
bool Env_find(Env *env, const char *key, word *result) {
  if (env == NULL) {
    return false;
  }
  if (strcmp(env->name, key) == 0) {
    *result = env->value;
    return true;
  }
  return Env_find(env->prev, key, result);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
testq %rbx, %rbx
je 0x1472
movq (%rbx), %rdi
movq %r15, %rsi
callq 0x10f0
testl %eax, %eax
je 0x146b
movq 0x10(%rbx), %rbx
jmp 0x1451
movq 0x8(%rbx), %rax
movq %rax, (%r14)
testq %rbx, %rbx
setne %al
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: AST_heap_free
void AST_heap_free(ASTNode *node) {
  if (!AST_is_heap_object(node)) {
    return;
  }
  if (AST_is_pair(node)) {
    AST_heap_free(AST_pair_car(node));
    AST_heap_free(AST_pair_cdr(node));
  }
  free((void *)Object_address(node));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
testb $0x3, %bl
sete %al
movl %ebx, %ecx
notl %ecx
testb $0x7, %cl
sete %cl
orb %al, %cl
jne 0x15d8
movl %ebx, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x15c6
movq %rbx, %rdi
callq 0x15ee
movq %rax, %rdi
callq 0x157f
movq %rbx, %rdi
callq 0x15fc
movq %rax, %rdi
callq 0x157f
andq $-0x8, %rbx
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1030
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: AST_new_pair
ASTNode *AST_new_pair(ASTNode *car, ASTNode *cdr) {
  ASTNode *node = AST_heap_alloc(kPairTag, sizeof(Pair));
  AST_pair_set_car(node, car);
  AST_pair_set_cdr(node, cdr);
  return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x1
popq %rdi
pushq $0x10
popq %rsi
callq 0x1545
movq %rax, %r15
movq %rax, %rdi
callq 0x167f
movq %r14, (%rax)
movq %r15, %rdi
callq 0x167f
movq %rbx, 0x8(%rax)
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: AST_new_symbol
ASTNode *AST_new_symbol(const char *str) {
  word data_length = strlen(str) + 1;
  ASTNode *node = AST_heap_alloc(kSymbolTag, sizeof(Symbol) + data_length);
  Symbol *s = AST_as_symbol(node);
  s->length = data_length;
  memcpy(s->cstr, str, data_length);
  return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x1070
leaq 0x1(%rax), %r14
leaq 0x9(%rax), %rsi
pushq $0x5
popq %rdi
callq 0x1545
movq %rax, %r15
movq %rax, %rdi
callq 0x1701
movq %r14, (%rax)
leaq 0x8(%rax), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x1110
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Buffer_alloc_writable
byte *Buffer_alloc_writable(size_t capacity) {
  byte *result = mmap(NULL, capacity, PROT_READ | PROT_WRITE,
                      MAP_ANONYMOUS | MAP_PRIVATE, -1, 0);
  assert(result != MAP_FAILED);
  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rsi
pushq $0x3
popq %rdx
pushq $0x22
popq %rcx
pushq $-0x1
popq %r8
xorl %edi, %edi
xorl %r9d, %r9d
callq 0x1080
cmpq $-0x1, %rax
je 0x179d
popq %rbp
retq
leaq 0xbed6(%rip), %rdi      # 0xd67a
leaq 0xbdd0(%rip), %rsi      # 0xd57b
leaq 0xbedd(%rip), %rcx      # 0xd68f
movl $0x12e, %edx            # imm = 0x12E
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Buffer_init
void Buffer_init(Buffer *result, size_t capacity) {
  result->address = Buffer_alloc_writable(capacity);
  assert(result->address != MAP_FAILED);
  result->state = kWritable;
  result->len = 0;
  result->capacity = capacity;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x177a
movq %rax, (%r14)
andl $0x0, 0x8(%r14)
andq $0x0, 0x10(%r14)
movq %rbx, 0x18(%r14)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Buffer_deinit
void Buffer_deinit(Buffer *buf) {
  munmap(buf->address, buf->capacity);
  buf->address = NULL;
  buf->len = 0;
  buf->capacity = 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rdi
movq 0x18(%rbx), %rsi
callq 0x1150
andq $0x0, (%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Buffer_ensure_capacity
void Buffer_ensure_capacity(Buffer *buf, word additional_capacity) {
  if (buf->len + additional_capacity <= buf->capacity) {
    return;
  }
  word new_capacity =
      max(buf->capacity * 2, buf->capacity + additional_capacity);
  byte *address = Buffer_alloc_writable(new_capacity);
  memcpy(address, buf->address, buf->len);
  int result = munmap(buf->address, buf->capacity);
  assert(result == 0 && "munmap failed");
  buf->address = address;
  buf->capacity = new_capacity;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x10(%rdi), %rcx
addq %rsi, %rcx
movq 0x18(%rdi), %rax
cmpq %rax, %rcx
jbe 0x18e7
movq %rsi, %rbx
movq %rdi, %r14
leaq (%rax,%rax), %rcx
addq %rax, %rbx
cmpq %rbx, %rcx
cmovgq %rcx, %rbx
movq %rbx, %rdi
callq 0x177a
movq %rax, %r15
movq (%r14), %rsi
movq 0x10(%r14), %rdx
movq %rax, %rdi
callq 0x1110
movq (%r14), %rdi
movq 0x18(%r14), %rsi
callq 0x1150
testl %eax, %eax
jne 0x18f2
movq %r15, (%r14)
movq %rbx, 0x18(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0xbdba(%rip), %rdi      # 0xd6b3
leaq 0xbc7b(%rip), %rsi      # 0xd57b
leaq 0xbdcb(%rip), %rcx      # 0xd6d2
movl $0x15d, %edx            # imm = 0x15D
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_mov_reg_imm32
void Emit_mov_reg_imm32(Buffer *buf, Register dst, int32_t src) {
  Buffer_write8(buf, kRexPrefix);
  Buffer_write8(buf, 0xc7);
  Buffer_write8(buf, modrm(3, dst, 0));
  Buffer_write32(buf, src);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r15
pushq $0x48
popq %rsi
callq 0x1911
movq %r15, %rdi
movl $0xc7, %esi
callq 0x1911
andb $0x7, %r14b
orb $-0x40, %r14b
movzbl %r14b, %esi
movq %r15, %rdi
callq 0x1911
movq %r15, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x193c
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_add_reg_imm32
void Emit_add_reg_imm32(Buffer *buf, Register dst, int32_t src) {
  Buffer_write8(buf, kRexPrefix);
  if (dst == kRax) {
    // Optimization: add eax, {imm32} can either be encoded as 05 {imm32} or 81
    // c0 {imm32}.
    Buffer_write8(buf, 0x05);
  } else {
    Buffer_write8(buf, 0x81);
    Buffer_write8(buf, modrm(3, dst, 0));
  }
  Buffer_write32(buf, src);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r15d
movq %rdi, %r14
pushq $0x48
popq %rsi
callq 0x1911
testl %r15d, %r15d
je 0x1a86
movq %r14, %rdi
movl $0x81, %esi
callq 0x1911
andb $0x7, %r15b
orb $-0x40, %r15b
jmp 0x1a89
movb $0x5, %r15b
movzbl %r15b, %esi
movq %r14, %rdi
callq 0x1911
movq %r14, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x193c
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_sub_reg_imm32
void Emit_sub_reg_imm32(Buffer *buf, Register dst, int32_t src) {
  Buffer_write8(buf, kRexPrefix);
  if (dst == kRax) {
    // Optimization: sub eax, {imm32} can either be encoded as 2d {imm32} or 81
    // e8 {imm32}.
    Buffer_write8(buf, 0x2d);
  } else {
    Buffer_write8(buf, 0x81);
    Buffer_write8(buf, modrm(3, dst, 5));
  }
  Buffer_write32(buf, src);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r15d
movq %rdi, %r14
pushq $0x48
popq %rsi
callq 0x1911
testl %r15d, %r15d
je 0x1adf
movq %r14, %rdi
movl $0x81, %esi
callq 0x1911
andb $0x7, %r15b
orb $-0x18, %r15b
jmp 0x1ae2
movb $0x2d, %r15b
movzbl %r15b, %esi
movq %r14, %rdi
callq 0x1911
movq %r14, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x193c
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_shl_reg_imm8
void Emit_shl_reg_imm8(Buffer *buf, Register dst, int8_t bits) {
  Buffer_write8(buf, kRexPrefix);
  Buffer_write8(buf, 0xc1);
  Buffer_write8(buf, modrm(3, dst, 4));
  Buffer_write8(buf, bits);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r15
pushq $0x48
popq %rsi
callq 0x1911
movq %r15, %rdi
movl $0xc1, %esi
callq 0x1911
andb $0x7, %r14b
orb $-0x20, %r14b
movzbl %r14b, %esi
movq %r15, %rdi
callq 0x1911
movzbl %bl, %esi
movq %r15, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1911
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_or_reg_imm8
void Emit_or_reg_imm8(Buffer *buf, Register dst, uint8_t tag) {
  Buffer_write8(buf, kRexPrefix);
  Buffer_write8(buf, 0x83);
  Buffer_write8(buf, modrm(3, dst, 1));
  Buffer_write8(buf, tag);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r15
pushq $0x48
popq %rsi
callq 0x1911
movq %r15, %rdi
movl $0x83, %esi
callq 0x1911
andb $0x7, %r14b
orb $-0x38, %r14b
movzbl %r14b, %esi
movq %r15, %rdi
callq 0x1911
movq %r15, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1911
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_cmp_reg_imm32
void Emit_cmp_reg_imm32(Buffer *buf, Register left, int32_t right) {
  Buffer_write8(buf, kRexPrefix);
  if (left == kRax) {
    // Optimization: cmp rax, {imm32} can be encoded as 0x3d {imm32}
    Buffer_write8(buf, 0x3d);
  } else {
    Buffer_write8(buf, 0x81);
    Buffer_write8(buf, modrm(3, left, 7));
  }
  Buffer_write32(buf, right);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r15d
movq %rdi, %r14
pushq $0x48
popq %rsi
callq 0x1911
testl %r15d, %r15d
je 0x1c72
movq %r14, %rdi
movl $0x81, %esi
callq 0x1911
orb $-0x8, %r15b
jmp 0x1c75
movb $0x3d, %r15b
movzbl %r15b, %esi
movq %r14, %rdi
callq 0x1911
movq %r14, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x193c
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_address_disp8
void Emit_address_disp8(Buffer *buf, Register direct, Indirect indirect) {
  if (indirect.reg == kRsp) {
    Buffer_write8(buf, modrm(1, kIndexNone, direct));
    Buffer_write8(buf, sib(kRsp, kIndexNone, Scale1));
  } else {
    Buffer_write8(buf, modrm(1, indirect.reg, direct));
  }
  Buffer_write8(buf, disp8(indirect.disp));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rdi, %r14
shlb $0x3, %sil
andb $0x38, %sil
cmpl $0x4, %ebx
jne 0x1d10
orb $0x44, %sil
movzbl %sil, %esi
movq %r14, %rdi
callq 0x1911
movb $0x24, %al
jmp 0x1d19
movl %ebx, %eax
andb $0x7, %al
orb %sil, %al
orb $0x40, %al
movzbl %al, %esi
movq %r14, %rdi
callq 0x1911
shrq $0x20, %rbx
movzbl %bl, %esi
movq %r14, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x1911
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_jcc
word Emit_jcc(Buffer *buf, Condition cond, int32_t offset) {
  Buffer_write8(buf, 0x0f);
  Buffer_write8(buf, 0x80 + cond);
  word pos = Buffer_len(buf);
  Buffer_write32(buf, disp32(offset));
  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r15
pushq $0xf
popq %rsi
callq 0x1911
addb $-0x80, %r14b
movzbl %r14b, %esi
movq %r15, %rdi
callq 0x1911
movq 0x10(%r15), %r14
movq %r15, %rdi
movl %ebx, %esi
callq 0x193c
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_jmp
word Emit_jmp(Buffer *buf, int32_t offset) {
  Buffer_write8(buf, 0xe9);
  word pos = Buffer_len(buf);
  Buffer_write32(buf, disp32(offset));
  return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movl $0xe9, %esi
callq 0x1911
movq 0x10(%r14), %r15
movq %r14, %rdi
movl %ebx, %esi
callq 0x193c
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Emit_rsp_adjust
void Emit_rsp_adjust(Buffer *buf, word adjust) {
  if (adjust < 0) {
    Emit_sub_reg_imm32(buf, kRsp, -adjust);
  } else if (adjust > 0) {
    Emit_add_reg_imm32(buf, kRsp, adjust);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rsi, %rdx
testq %rsi, %rsi
js 0x1f97
je 0x1fa4
movl $0x4, %esi
popq %rbp
jmp 0x1a50
negl %edx
movl $0x4, %esi
popq %rbp
jmp 0x1aa9
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_expr
int Compile_expr(Buffer *buf, ASTNode *node, word stack_index, Env *varenv,
                 Env *labels) {
  if (AST_is_integer(node)) {
    word value = AST_get_integer(node);
    Emit_mov_reg_imm32(buf, kRax, Object_encode_integer(value));
    return 0;
  }
  if (AST_is_char(node)) {
    char value = AST_get_char(node);
    Emit_mov_reg_imm32(buf, kRax, Object_encode_char(value));
    return 0;
  }
  if (AST_is_bool(node)) {
    bool value = AST_get_bool(node);
    Emit_mov_reg_imm32(buf, kRax, Object_encode_bool(value));
    return 0;
  }
  if (AST_is_nil(node)) {
    Emit_mov_reg_imm32(buf, kRax, Object_nil());
    return 0;
  }
  if (AST_is_pair(node)) {
    return Compile_call(buf, AST_pair_car(node), AST_pair_cdr(node),
                        stack_index, varenv, labels);
  }
  if (AST_is_symbol(node)) {
    const char *symbol = AST_symbol_cstr(node);
    word value;
    if (Env_find(varenv, symbol, &value)) {
      Emit_load_reg_indirect(buf, kRax, Ind(kRsp, value));
      return 0;
    }
    return -1;
  }
  assert(0 && "unexpected node type");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
testb $0x3, %r14b
je 0x204a
movl %r14d, %eax
andl $0x3f, %eax
cmpq $0x1f, %rax
je 0x2065
cmpl $0xf, %eax
jne 0x207d
movswl %r14w, %edx
andl $0xffffff00, %edx       # imm = 0xFFFFFF00
orl $0xf, %edx
xorl %r15d, %r15d
jmp 0x20e1
sarq $0x2, %r14
movq %r14, %rdi
callq 0x12ac
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %esi, %esi
movl %eax, %edx
jmp 0x20e6
andl $0x80, %r14d
orl $0x1f, %r14d
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %esi, %esi
movl %r14d, %edx
jmp 0x20e6
cmpq $0x2f, %r14
je 0x20db
movq %rcx, %r15
movl %r14d, %eax
andl $0x7, %eax
cmpq $0x5, %rax
je 0x20fd
cmpl $0x1, %eax
jne 0x213d
movq %r8, %r12
movq %rdx, %r13
movq %r14, %rdi
callq 0x15ee
movq %rax, -0x30(%rbp)
movq %r14, %rdi
callq 0x15fc
movq %rbx, %rdi
movq -0x30(%rbp), %rsi
movq %rax, %rdx
movq %r13, %rcx
movq %r15, %r8
movq %r12, %r9
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x215c
xorl %r15d, %r15d
pushq $0x2f
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x19f2
movl %r15d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
callq 0x1701
leaq 0x8(%rax), %rsi
leaq -0x38(%rbp), %rdx
movq %r15, %rdi
callq 0x143e
testb %al, %al
je 0x2137
movq -0x38(%rbp), %rax
movzbl %al, %edx
shlq $0x20, %rdx
orq $0x4, %rdx
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1e63
jmp 0x20eb
pushq $-0x1
popq %r15
jmp 0x20eb
leaq 0xb5ba(%rip), %rdi      # 0xd6fe
leaq 0xb430(%rip), %rsi      # 0xd57b
leaq 0xb5c8(%rip), %rcx      # 0xd71a
movl $0x2aa, %edx            # imm = 0x2AA
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_if
int Compile_if(Buffer *buf, ASTNode *cond, ASTNode *consequent,
               ASTNode *alternate, word stack_index, Env *varenv, Env *labels) {
  _(Compile_expr(buf, cond, stack_index, varenv, labels));
  Emit_cmp_reg_imm32(buf, kRax, Object_false());
  word alternate_pos = Emit_jcc(buf, kEqual, kLabelPlaceholder);
  _(Compile_expr(buf, consequent, stack_index, varenv, labels));
  word end_pos = Emit_jmp(buf, kLabelPlaceholder);
  Emit_backpatch_imm32(buf, alternate_pos);
  _(Compile_expr(buf, alternate, stack_index, varenv, labels));
  Emit_backpatch_imm32(buf, end_pos);
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, %r15
movq %r8, %r12
movq %rcx, %r14
movq %rdx, %r13
movq %rdi, %rbx
movq 0x10(%rbp), %r8
movq %r12, %rdx
movq %r9, %rcx
callq 0x2007
pushq $-0x1
popq %rcx
testl %eax, %eax
jne 0x2ad6
movq %r14, -0x38(%rbp)
pushq $0x1f
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1c40
pushq $0x4
popq %rsi
movq %rbx, %rdi
movl $0xdeadbeef, %edx       # imm = 0xDEADBEEF
callq 0x1ea3
movq %rax, -0x30(%rbp)
movq %rbx, %rdi
movq %r13, %rsi
movq %r12, %rdx
movq %r15, %rcx
movq 0x10(%rbp), %r14
movq %r14, %r8
callq 0x2007
testl %eax, %eax
je 0x2a91
pushq $-0x1
popq %rcx
jmp 0x2ad6
movq %rbx, %rdi
movl $0xdeadbeef, %esi       # imm = 0xDEADBEEF
callq 0x1ee9
movq %rax, %r13
movq %rbx, %rdi
movq -0x30(%rbp), %rsi
callq 0x1f1e
movq %rbx, %rdi
movq -0x38(%rbp), %rsi
movq %r12, %rdx
movq %r15, %rcx
movq %r14, %r8
callq 0x2007
testl %eax, %eax
pushq $-0x1
popq %rcx
jne 0x2ad6
movq %rbx, %rdi
movl %r13d, %esi
callq 0x1f1e
xorl %ecx, %ecx
movl %ecx, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_cons
int Compile_cons(Buffer *buf, ASTNode *car, ASTNode *cdr, int stack_index,
                 Env *varenv, Env *labels) {
  // Compile and store car on the stack
  _(Compile_expr(buf, car, stack_index, varenv, labels));
  Emit_store_reg_indirect(buf, Ind(kRbp, stack_index), kRax);
  // Compile and store cdr
  _(Compile_expr(buf, cdr, stack_index - kWordSize, varenv, labels));
  Emit_store_reg_indirect(buf, Ind(kHeapPointer, kCdrOffset), kRax);
  // Fetch car and store in heap
  Emit_load_reg_indirect(buf, kRax, Ind(kRbp, stack_index));
  Emit_store_reg_indirect(buf, Ind(kHeapPointer, kCarOffset), kRax);

  // Store tagged pointer in tax
  Emit_mov_reg_reg(buf, kRax, kHeapPointer);
  Emit_or_reg_imm8(buf, kRax, kPairTag);
  // Bump the heap pointer
  Emit_add_reg_imm32(buf, kHeapPointer, kPairSize);
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %r14
movq %r8, %r12
movl %ecx, %r13d
movq %rdx, %r15
movq %rdi, %rbx
movslq %ecx, %rdx
movq %r8, %rcx
movq %r9, %r8
callq 0x2007
pushq $-0x1
popq %rcx
testl %eax, %eax
jne 0x2bb6
movq %r15, -0x30(%rbp)
movzbl %r13b, %r15d
shlq $0x20, %r15
orq $0x5, %r15
movq %rbx, %rdi
movq %r15, %rsi
xorl %edx, %edx
callq 0x1d37
addl $-0x8, %r13d
movslq %r13d, %rdx
movq %rbx, %rdi
movq -0x30(%rbp), %rsi
movq %r12, %rcx
movq %r14, %r8
callq 0x2007
pushq $-0x1
popq %rcx
testl %eax, %eax
jne 0x2bb6
movabsq $0x800000006, %rsi      # imm = 0x800000006
movq %rbx, %rdi
xorl %edx, %edx
callq 0x1d37
movq %rbx, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x1e63
pushq $0x6
popq %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x1d37
pushq $0x6
popq %r14
movq %rbx, %rdi
xorl %esi, %esi
movl %r14d, %edx
callq 0x1f33
pushq $0x1
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1ba2
pushq $0x10
popq %rdx
movq %rbx, %rdi
movl %r14d, %esi
callq 0x1a50
xorl %ecx, %ecx
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: list_length
word list_length(ASTNode *node) {
  if (AST_is_nil(node)) {
    return 0;
  }
  assert(AST_is_pair(node));
  return 1 + list_length(AST_pair_cdr(node));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
xorl %ebx, %ebx
cmpq $0x2f, %rdi
je 0x2bec
movl %edi, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x2bf6
callq 0x15fc
movq %rax, %rdi
incq %rbx
jmp 0x2bcf
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0xaa19(%rip), %rdi      # 0xd616
leaq 0xa977(%rip), %rsi      # 0xd57b
leaq 0xab49(%rip), %rcx      # 0xd754
movl $0x2d6, %edx            # imm = 0x2D6
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_labelcall
int Compile_labelcall(Buffer *buf, ASTNode *callable, ASTNode *args,
                      word stack_index, Env *varenv, Env *labels, word nargs,
                      word rsp_adjust) {
  if (AST_is_nil(args)) {
    const char *symbol = AST_symbol_cstr(callable);
    word code_address;
    if (!Env_find(labels, symbol, &code_address)) {
      return -1;
    }
    Emit_rsp_adjust(buf, rsp_adjust);
    Emit_call_imm32(buf, code_address);
    Emit_rsp_adjust(buf, -rsp_adjust);
    return 0;
  }

  assert(AST_is_pair(args));
  ASTNode *arg = AST_pair_car(args);
  _(Compile_expr(buf, arg, stack_index, varenv, labels));
  Emit_store_reg_indirect(buf, Ind(kRsp, stack_index), kRax);
  return Compile_labelcall(buf, callable, AST_pair_cdr(args),
                           stack_index - kWordSize, varenv, labels, nargs,
                           rsp_adjust);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, -0x30(%rbp)
movq %r8, %r13
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, -0x38(%rbp)
movq %rdi, %rbx
movq %rcx, %r14
shlq $0x20, %r14
cmpq $0x2f, %r12
je 0x2cb7
movl %r12d, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x2d14
movq %r12, %rdi
callq 0x15ee
movq %rbx, %rdi
movq %rax, %rsi
movq %r15, %rdx
movq %r13, %rcx
movq -0x30(%rbp), %r8
callq 0x2007
testl %eax, %eax
jne 0x2d02
movq %r14, %rsi
movabsq $0xff00000000, %rax     # imm = 0xFF00000000
andq %rax, %rsi
orq $0x4, %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x1d37
movq %r12, %rdi
callq 0x15fc
movq %rax, %r12
addq $-0x8, %r15
movabsq $-0x800000000, %rax     # imm = 0xFFFFFFF800000000
addq %rax, %r14
jmp 0x2c41
movq -0x38(%rbp), %rdi
callq 0x1701
leaq 0x8(%rax), %rsi
leaq -0x40(%rbp), %rdx
movq -0x30(%rbp), %rdi
callq 0x143e
testb %al, %al
je 0x2d02
movq %rbx, %rdi
movq 0x18(%rbp), %r14
movq %r14, %rsi
callq 0x1f7e
movq -0x40(%rbp), %rsi
movq %rbx, %rdi
callq 0x1fa6
negq %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1f7e
xorl %eax, %eax
jmp 0x2d05
pushq $-0x1
popq %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xaa55(%rip), %rdi      # 0xd770
leaq 0xa859(%rip), %rsi      # 0xd57b
leaq 0xaa59(%rip), %rcx      # 0xd782
movl $0x2e9, %edx            # imm = 0x2E9
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_let
int Compile_let(Buffer *buf, ASTNode *bindings, ASTNode *body, word stack_index,
                Env *binding_env, Env *body_env, Env *labels) {
  if (AST_is_nil(bindings)) {
    // Base case: no bindings (or none left)
    _(Compile_expr(buf, body, stack_index, body_env, labels));
    return 0;
  }
  assert(AST_is_pair(bindings));
  // Unpack the binding
  ASTNode *binding = AST_pair_car(bindings);
  ASTNode *name = AST_pair_car(binding);
  assert(AST_is_symbol(name));
  ASTNode *binding_expr = AST_pair_car(AST_pair_cdr(binding));
  // Evaluate the RHS, store result on stack
  _(Compile_expr(buf, binding_expr, stack_index, binding_env, labels));
  Emit_store_reg_indirect(buf, Ind(kRsp, stack_index), kRax);
  // Bind the name to a stack offset
  Env entry = Env_bind(AST_symbol_cstr(name), stack_index, body_env);
  _(Compile_let(buf, AST_pair_cdr(bindings), body, stack_index - kWordSize,
                binding_env, &entry, labels));
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, %rbx
movq %rdi, %r13
movq 0x10(%rbp), %r14
cmpq $0x2f, %rsi
je 0x2dc7
movq %rsi, %r15
movq %r9, -0x40(%rbp)
movq %rdx, -0x48(%rbp)
movq %r8, -0x30(%rbp)
movl %r15d, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x2e62
movq %r15, %rdi
callq 0x15ee
movq %rax, %r12
movq %rax, %rdi
callq 0x15ee
movq %rax, -0x38(%rbp)
andl $0x7, %eax
cmpl $0x5, %eax
jne 0x2e81
movq %r12, %rdi
callq 0x15fc
movq %rax, %rdi
callq 0x15ee
movq %r13, %rdi
movq %rax, %rsi
movq %rbx, %rdx
movq -0x30(%rbp), %rcx
movq %r14, %r8
callq 0x2007
testl %eax, %eax
je 0x2de9
pushq $-0x1
popq %r12
jmp 0x2e50
movq %r13, %rdi
movq %rdx, %rsi
movq %rbx, %rdx
movq %r9, %rcx
movq %r14, %r8
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2007
movzbl %bl, %esi
shlq $0x20, %rsi
orq $0x4, %rsi
xorl %r12d, %r12d
movq %r13, %rdi
xorl %edx, %edx
callq 0x1d37
movq -0x38(%rbp), %rdi
callq 0x1701
addq $0x8, %rax
leaq -0x60(%rbp), %rcx
movq %rax, (%rcx)
movq %rbx, 0x8(%rcx)
movq -0x40(%rbp), %rax
movq %rax, 0x10(%rcx)
movq %r15, %rdi
callq 0x15fc
addq $-0x8, %rbx
movq %r14, (%rsp)
movq %r13, %rdi
movq %rax, %rsi
movq -0x48(%rbp), %rdx
movq %rbx, %rcx
movq -0x30(%rbp), %r8
leaq -0x60(%rbp), %r9
callq 0x2d33
negl %eax
sbbl %r12d, %r12d
movl %r12d, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xaa36(%rip), %rdi      # 0xd89f
leaq 0xa70b(%rip), %rsi      # 0xd57b
leaq 0xaa3e(%rip), %rcx      # 0xd8b5
movl $0x386, %edx            # imm = 0x386
callq 0x1090
leaq 0xaa78(%rip), %rdi      # 0xd900
leaq 0xa6ec(%rip), %rsi      # 0xd57b
leaq 0xaa1f(%rip), %rcx      # 0xd8b5
movl $0x38a, %edx            # imm = 0x38A
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_compare_imm32
void Compile_compare_imm32(Buffer *buf, int32_t value) {
  Emit_cmp_reg_imm32(buf, kRax, value);
  Emit_mov_reg_imm32(buf, kRax, 0);
  Emit_setcc_imm8(buf, kEqual, kAl);
  Emit_shl_reg_imm8(buf, kRax, kBoolShift);
  Emit_or_reg_imm8(buf, kRax, kBoolTag);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %esi, %edx
movq %rdi, %rbx
xorl %esi, %esi
callq 0x1c40
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x19f2
pushq $0x4
popq %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x1c95
pushq $0x7
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1b02
pushq $0x1f
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1ba2
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_code_impl
int Compile_code_impl(Buffer *buf, ASTNode *formals, ASTNode *body,
                      word stack_index, Env *varenv) {
  if (AST_is_nil(formals)) {
    _(Compile_expr(buf, body, stack_index, varenv, NULL));
    Buffer_write_arr(buf, kFunctionEpilogue, sizeof kFunctionEpilogue);
    return 0;
  }

  assert(AST_is_pair(formals));
  ASTNode *name = AST_pair_car(formals);
  assert(AST_is_symbol(name));
  Env entry = Env_bind(AST_symbol_cstr(name), stack_index, varenv);
  return Compile_code_impl(buf, AST_pair_cdr(formals), body,
                           stack_index - kWordSize, &entry);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r8, %r12
movq %rcx, %r14
movq %rdx, %r15
movq %rdi, %rbx
cmpq $0x2f, %rsi
je 0x2f7b
movq %rsi, %r13
movl %r13d, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x2fc0
movq %rbx, -0x30(%rbp)
movq %r13, %rdi
callq 0x15ee
movl %eax, %ecx
andl $0x7, %ecx
cmpl $0x5, %ecx
jne 0x2fdf
movq %rax, %rdi
callq 0x1701
addq $0x8, %rax
leaq -0x48(%rbp), %rbx
movq %rax, (%rbx)
movq %r14, 0x8(%rbx)
movq %r12, 0x10(%rbx)
movq %r13, %rdi
callq 0x15fc
addq $-0x8, %r14
movq -0x30(%rbp), %rdi
movq %rax, %rsi
movq %r15, %rdx
movq %r14, %rcx
movq %rbx, %r8
callq 0x2eeb
movl %eax, %r13d
jmp 0x2fae
xorl %r13d, %r13d
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
xorl %r8d, %r8d
callq 0x2007
testl %eax, %eax
je 0x2f9c
pushq $-0x1
popq %r13
jmp 0x2fae
leaq 0xa10d(%rip), %rsi      # 0xd0b0
pushq $0x1
popq %rdx
movq %rbx, %rdi
callq 0x1977
movl %r13d, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xa94d(%rip), %rdi      # 0xd914
leaq 0xa5ad(%rip), %rsi      # 0xd57b
leaq 0xa954(%rip), %rcx      # 0xd929
movl $0x3ab, %edx            # imm = 0x3AB
callq 0x1090
leaq 0xa91a(%rip), %rdi      # 0xd900
leaq 0xa58e(%rip), %rsi      # 0xd57b
leaq 0xa935(%rip), %rcx      # 0xd929
movl $0x3ad, %edx            # imm = 0x3AD
callq 0x1090
// File: /workspace/github_c_makefile_star2_O2/mtnygard[P]complisp/lisp.c
// Function: Compile_code
int Compile_code(Buffer *buf, ASTNode *code) {
  assert(AST_is_pair(code));
  ASTNode *code_sym = AST_pair_car(code);
  assert(AST_is_symbol(code_sym));
  assert(AST_symbol_matches(code_sym, "code"));
  ASTNode *formals = AST_pair_car(AST_pair_cdr(code));
  ASTNode *code_body = AST_pair_car(AST_pair_cdr(AST_pair_cdr(code)));
  return Compile_code_impl(buf, formals, code_body, -kWordSize, NULL);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movl %r14d, %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x308b
movq %rdi, %rbx
movq %r14, %rdi
callq 0x15ee
movl %eax, %ecx
andl $0x7, %ecx
cmpl $0x5, %ecx
jne 0x30aa
leaq 0xa98a(%rip), %rsi      # 0xd9bc
movq %rax, %rdi
callq 0x1754
testb %al, %al
je 0x30c9
movq %r14, %rdi
callq 0x15fc
movq %rax, %rdi
callq 0x15ee
movq %rax, %r15
movq %r14, %rdi
callq 0x15fc
movq %rax, %rdi
callq 0x15fc
movq %rax, %rdi
callq 0x15ee
pushq $-0x8
popq %rcx
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
xorl %r8d, %r8d
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x2eeb
leaq 0xa8da(%rip), %rdi      # 0xd96c
leaq 0xa4e2(%rip), %rsi      # 0xd57b
leaq 0xa8de(%rip), %rcx      # 0xd97e
movl $0x3b4, %edx            # imm = 0x3B4
callq 0x1090
leaq 0xa8f3(%rip), %rdi      # 0xd9a4
leaq 0xa4c3(%rip), %rsi      # 0xd57b
leaq 0xa8bf(%rip), %rcx      # 0xd97e
movl $0x3b6, %edx            # imm = 0x3B6
callq 0x1090
leaq 0xa8f1(%rip), %rdi      # 0xd9c1
leaq 0xa4a4(%rip), %rsi      # 0xd57b
leaq 0xa8a0(%rip), %rcx      # 0xd97e
movl $0x3b7, %edx            # imm = 0x3B7
callq 0x1090