// File: alexwarth[P]nothing/main.cpp
// Function: interp(int, int)
value_t interp(value_t prog, value_t retFp = Int(-1)) {
  ipb = prog;
  ip  = Int(0);
  while (1) {
    value_t instr = slotAt(ipb, ip), primIdx = IntValue(car(instr)), op = cdr(instr);
    dPrintf2("\n\n%S\nExecuting instruction <<%o %o>>\n", primNames[primIdx], op);
    if (0 <= primIdx && primIdx < numPrims) prims[primIdx](op);
    else                                    error("%d is not a valid primitive\n", primIdx);
    ip = Int(IntValue(ip) + 1);
    dPrintf2("\n%S\n\n\n");
    if (primIdx == IntValue(Halt))
      break;
    else if (primIdx == IntValue(Ret) && fp == retFp) {
      ip = Int(IntValue(ip) - 1); // undo increment of ip
      break;
    }
  }
  return _p(Pop);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movl %edi, -0x4(%rbp)
movl %esi, -0x8(%rbp)
movl -0x4(%rbp), %eax
movl %eax, 0x14bc6(%rip)     # 0x22090
movl $0x1, 0x14bc0(%rip)     # 0x22094
movl 0x14bb6(%rip), %eax     # 0x22090
movl %eax, -0x14(%rbp)
cmpl $0x0, 0x14b9c(%rip)     # 0x22080
je 0xd514
movl -0x14(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0xd4f3
jmp 0xd512
leaq 0xcb60(%rip), %rdi      # 0x1a05a
leaq 0xcb36(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf9ec(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd514
movl -0x14(%rbp), %eax
sarl %eax
movl %eax, -0x18(%rbp)
movl -0x18(%rbp), %eax
movl %eax, -0x10(%rbp)
movl 0x14b6c(%rip), %eax     # 0x22094
movl %eax, -0x20(%rbp)
cmpl $0x0, 0x14b4e(%rip)     # 0x22080
je 0xd562
movl -0x20(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd541
jmp 0xd560
leaq 0xcc5f(%rip), %rdi      # 0x1a1a7
leaq 0xcae8(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf99e(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd562
movl -0x20(%rbp), %eax
sarl %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x1c(%rbp)
cmpl $0x0, 0x14b09(%rip)     # 0x22080
je 0xd62c
xorl %eax, %eax
xorl %ecx, %ecx
cmpl -0x1c(%rbp), %ecx
movb %al, -0xb5(%rbp)
jg 0xd5fd
movl -0x1c(%rbp), %eax
movl %eax, -0xbc(%rbp)
movq 0x14b54(%rip), %rax     # 0x220f0
movslq -0x10(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x28(%rbp)
cmpl $0x0, 0x14acd(%rip)     # 0x22080
je 0xd5e3
movl -0x28(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd5c2
jmp 0xd5e1
leaq 0xcbde(%rip), %rdi      # 0x1a1a7
leaq 0xca67(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf91d(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd5e3
movl -0xbc(%rbp), %eax
movl -0x28(%rbp), %ecx
sarl %ecx
movl %ecx, -0x2c(%rbp)
cmpl -0x2c(%rbp), %eax
setl %al
movb %al, -0xb5(%rbp)
movb -0xb5(%rbp), %al
testb $0x1, %al
jne 0xd609
jmp 0xd60b
jmp 0xd62a
leaq 0xf908(%rip), %rdi      # 0x1cf1a
leaq 0xca1e(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf8d4(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd62c
movq 0x14abd(%rip), %rax     # 0x220f0
movslq -0x10(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0xc(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x40(%rbp)
cmpl $0x0, 0x14a21(%rip)     # 0x22080
je 0xd68f
movl -0x40(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0xd66e
jmp 0xd68d
leaq 0xc9e5(%rip), %rdi      # 0x1a05a
leaq 0xc9bb(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf871(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd68f
movl -0x40(%rbp), %eax
sarl %eax
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl $0x1, -0x4c(%rbp)
cmpl $0x0, 0x149d5(%rip)     # 0x22080
je 0xd6db
movl -0x4c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd6ba
jmp 0xd6d9
leaq 0xcae6(%rip), %rdi      # 0x1a1a7
leaq 0xc96f(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf825(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd6db
movl -0x4c(%rbp), %eax
sarl %eax
movl %eax, -0x50(%rbp)
movl -0x50(%rbp), %eax
movl %eax, -0x48(%rbp)
cmpl $0x0, 0x14990(%rip)     # 0x22080
je 0xd7a5
xorl %eax, %eax
xorl %ecx, %ecx
cmpl -0x48(%rbp), %ecx
movb %al, -0xbd(%rbp)
jg 0xd776
movl -0x48(%rbp), %eax
movl %eax, -0xc4(%rbp)
movq 0x149db(%rip), %rax     # 0x220f0
movslq -0x3c(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x54(%rbp)
cmpl $0x0, 0x14954(%rip)     # 0x22080
je 0xd75c
movl -0x54(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd73b
jmp 0xd75a
leaq 0xca65(%rip), %rdi      # 0x1a1a7
leaq 0xc8ee(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf7a4(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd75c
movl -0xc4(%rbp), %eax
movl -0x54(%rbp), %ecx
sarl %ecx
movl %ecx, -0x58(%rbp)
cmpl -0x58(%rbp), %eax
setl %al
movb %al, -0xbd(%rbp)
movb -0xbd(%rbp), %al
testb $0x1, %al
jne 0xd782
jmp 0xd784
jmp 0xd7a3
leaq 0xf78f(%rip), %rdi      # 0x1cf1a
leaq 0xc8a5(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf75b(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd7a5
movq 0x14944(%rip), %rax     # 0x220f0
movslq -0x3c(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movslq -0x48(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x5c(%rbp)
movl -0x5c(%rbp), %eax
movl %eax, -0x38(%rbp)
cmpl $0x0, 0x148ae(%rip)     # 0x22080
je 0xd802
movl -0x38(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd7e1
jmp 0xd800
leaq 0xc9bf(%rip), %rdi      # 0x1a1a7
leaq 0xc848(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf6fe(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd802
movl -0x38(%rbp), %eax
sarl %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
movl %eax, -0x34(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x6c(%rbp)
cmpl $0x0, 0x14863(%rip)     # 0x22080
je 0xd84d
movl -0x6c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0xd82c
jmp 0xd84b
leaq 0xc827(%rip), %rdi      # 0x1a05a
leaq 0xc7fd(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf6b3(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd84d
movl -0x6c(%rbp), %eax
sarl %eax
movl %eax, -0x70(%rbp)
movl -0x70(%rbp), %eax
movl %eax, -0x68(%rbp)
movl $0x3, -0x78(%rbp)
cmpl $0x0, 0x14817(%rip)     # 0x22080
je 0xd899
movl -0x78(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd878
jmp 0xd897
leaq 0xc928(%rip), %rdi      # 0x1a1a7
leaq 0xc7b1(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf667(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd899
movl -0x78(%rbp), %eax
sarl %eax
movl %eax, -0x7c(%rbp)
movl -0x7c(%rbp), %eax
movl %eax, -0x74(%rbp)
cmpl $0x0, 0x147d2(%rip)     # 0x22080
je 0xd969
xorl %eax, %eax
xorl %ecx, %ecx
cmpl -0x74(%rbp), %ecx
movb %al, -0xc5(%rbp)
jg 0xd93a
movl -0x74(%rbp), %eax
movl %eax, -0xcc(%rbp)
movq 0x1481d(%rip), %rax     # 0x220f0
movslq -0x68(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x80(%rbp)
cmpl $0x0, 0x14796(%rip)     # 0x22080
je 0xd91a
movl -0x80(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd8f9
jmp 0xd918
leaq 0xc8a7(%rip), %rdi      # 0x1a1a7
leaq 0xc730(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf5e6(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd91a
movl -0xcc(%rbp), %eax
movl -0x80(%rbp), %ecx
sarl %ecx
movl %ecx, -0x84(%rbp)
cmpl -0x84(%rbp), %eax
setl %al
movb %al, -0xc5(%rbp)
movb -0xc5(%rbp), %al
testb $0x1, %al
jne 0xd946
jmp 0xd948
jmp 0xd967
leaq 0xf5cb(%rip), %rdi      # 0x1cf1a
leaq 0xc6e1(%rip), %rsi      # 0x1a037
movl $0x1cb, %edx            # imm = 0x1CB
leaq 0xf597(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xd969
movq 0x14780(%rip), %rax     # 0x220f0
movslq -0x68(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movslq -0x74(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x88(%rbp)
movl -0x88(%rbp), %eax
movl %eax, -0x64(%rbp)
movslq -0x34(%rbp), %rcx
leaq 0x14970(%rip), %rax     # 0x22310
movq (%rax,%rcx,8), %rsi
movl -0x64(%rbp), %edx
leaq 0xf63a(%rip), %rdi      # 0x1cfe8
movb $0x0, %al
callq 0x2410
xorl %eax, %eax
cmpl -0x34(%rbp), %eax
jg 0xd9df
movslq -0x34(%rbp), %rax
cmpq 0x14b49(%rip), %rax     # 0x22510
jae 0xd9df
movslq -0x34(%rbp), %rcx
leaq 0x1473c(%rip), %rax     # 0x22110
movq (%rax,%rcx,8), %rax
movl -0x64(%rbp), %edi
callq *%rax
jmp 0xd9f0
movl -0x34(%rbp), %esi
leaq 0xf625(%rip), %rdi      # 0x1d00e
movb $0x0, %al
callq 0x24c0
movl 0x1469e(%rip), %eax     # 0x22094
movl %eax, -0x8c(%rbp)
cmpl $0x0, 0x1467d(%rip)     # 0x22080
je 0xda36
movl -0x8c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xda15
jmp 0xda34
leaq 0xc78b(%rip), %rdi      # 0x1a1a7
leaq 0xc614(%rip), %rsi      # 0x1a037
movl $0x1cf, %edx            # imm = 0x1CF
leaq 0xf4ca(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xda36
movl -0x8c(%rbp), %eax
sarl %eax
movl %eax, -0x90(%rbp)
movl -0x90(%rbp), %eax
addl $0x1, %eax
shll %eax
orl $0x1, %eax
movl %eax, 0x1463c(%rip)     # 0x22094
leaq 0xf5cc(%rip), %rdi      # 0x1d02b
movb $0x0, %al
callq 0x2410
movl -0x34(%rbp), %eax
movl %eax, -0xd0(%rbp)
movl 0x14b1f(%rip), %eax     # 0x22594
movl %eax, -0x94(%rbp)
cmpl $0x0, 0x145fe(%rip)     # 0x22080
je 0xdab5
movl -0x94(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xda94
jmp 0xdab3
leaq 0xc70c(%rip), %rdi      # 0x1a1a7
leaq 0xc595(%rip), %rsi      # 0x1a037
movl $0x1d1, %edx            # imm = 0x1D1
leaq 0xf44b(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xdab5
movl -0xd0(%rbp), %eax
movl -0x94(%rbp), %ecx
sarl %ecx
movl %ecx, -0x98(%rbp)
cmpl -0x98(%rbp), %eax
jne 0xdad6
jmp 0xdbbd
movl -0x34(%rbp), %eax
movl %eax, -0xd4(%rbp)
movl 0x14a77(%rip), %eax     # 0x2255c
movl %eax, -0x9c(%rbp)
cmpl $0x0, 0x1458e(%rip)     # 0x22080
je 0xdb25
movl -0x9c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xdb04
jmp 0xdb23
leaq 0xc69c(%rip), %rdi      # 0x1a1a7
leaq 0xc525(%rip), %rsi      # 0x1a037
movl $0x1d3, %edx            # imm = 0x1D3
leaq 0xf3db(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xdb25
movl -0xd4(%rbp), %eax
movl -0x9c(%rbp), %ecx
sarl %ecx
movl %ecx, -0xa0(%rbp)
cmpl -0xa0(%rbp), %eax
jne 0xdbb6
movl 0x14551(%rip), %eax     # 0x22098
cmpl -0x8(%rbp), %eax
jne 0xdbb6
movl 0x14542(%rip), %eax     # 0x22094
movl %eax, -0xa4(%rbp)
cmpl $0x0, 0x14521(%rip)     # 0x22080
je 0xdb92
movl -0xa4(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xdb71
jmp 0xdb90
leaq 0xc62f(%rip), %rdi      # 0x1a1a7
leaq 0xc4b8(%rip), %rsi      # 0x1a037
movl $0x1d4, %edx            # imm = 0x1D4
leaq 0xf36e(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xdb92
movl -0xa4(%rbp), %eax
sarl %eax
movl %eax, -0xa8(%rbp)
movl -0xa8(%rbp), %eax
subl $0x1, %eax
shll %eax
orl $0x1, %eax
movl %eax, 0x144e0(%rip)     # 0x22094
jmp 0xdbbd
jmp 0xdbb8
jmp 0xd4d4
movl 0x14959(%rip), %eax     # 0x2251c
movl %eax, -0xb0(%rbp)
cmpl $0x0, 0x144b0(%rip)     # 0x22080
je 0xdc03
movl -0xb0(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xdbe2
jmp 0xdc01
leaq 0xc5be(%rip), %rdi      # 0x1a1a7
leaq 0xc447(%rip), %rsi      # 0x1a037
movl $0x1d8, %edx            # imm = 0x1D8
leaq 0xf2fd(%rip), %rcx      # 0x1cef9
callq 0x1060
jmp 0xdc03
movl -0xb0(%rbp), %eax
sarl %eax
movl %eax, -0xb4(%rbp)
movslq -0xb4(%rbp), %rcx
leaq 0x144f1(%rip), %rax     # 0x22110
movq (%rax,%rcx,8), %rax
movl 0x1445f(%rip), %edi     # 0x22088
callq *%rax
movl %eax, -0xac(%rbp)
movl -0xac(%rbp), %eax
addq $0xe0, %rsp
popq %rbp
retq