// File: /workspace/github_c_makefile_star2_O0/mtnygard[P]complisp/lisp.c
// Function: compile_binary_mul_nested
TEST compile_binary_mul_nested(Buffer *buf) {
  ASTNode *node = new_binary_call(
      "*", new_binary_call("*", AST_new_integer(1), AST_new_integer(2)),
      new_binary_call("*", AST_new_integer(3), AST_new_integer(4)));
  int compile_result = Compile_entry(buf, node);
  ASSERT_EQ(compile_result, 0);
  Buffer_make_executable(buf);
  uword result = Testing_execute_expr(buf);
  ASSERT_EQ_FMT(Object_encode_integer(24), result, "0x%lx");
  AST_heap_free(node);
  PASS();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movl $0x1, %edi
callq 0x15c0
movq %rax, -0x40(%rbp)
movl $0x2, %edi
callq 0x15c0
movq -0x40(%rbp), %rsi
movq %rax, %rdx
leaq 0x7baa(%rip), %rdi      # 0x149fc
callq 0x5020
movq %rax, -0x30(%rbp)
movl $0x3, %edi
callq 0x15c0
movq %rax, -0x38(%rbp)
movl $0x4, %edi
callq 0x15c0
movq -0x38(%rbp), %rsi
movq %rax, %rdx
leaq 0x7b7b(%rip), %rdi      # 0x149fc
callq 0x5020
movq -0x30(%rbp), %rsi
movq %rax, %rdx
leaq 0x7b68(%rip), %rdi      # 0x149fc
callq 0x5020
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x4690
movl %eax, -0x1c(%rbp)
movl 0xe291(%rip), %eax      # 0x1b144
addl $0x1, %eax
movl %eax, 0xe288(%rip)      # 0x1b144
cmpl $0x0, -0x1c(%rbp)
je 0xcf0a
jmp 0xcec4
leaq 0x77d8(%rip), %rax      # 0x146a3
movq %rax, 0xe27e(%rip)      # 0x1b150
movl $0x7c5, 0xe26c(%rip)    # imm = 0x7C5
leaq 0x91a2(%rip), %rax      # 0x16085
movq %rax, 0xe26e(%rip)      # 0x1b158
movzbl 0xe20f(%rip), %eax      # 0x1b100
andl $0x4, %eax
cmpl $0x0, %eax
je 0xcefe
callq 0x1040
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xd036
jmp 0xcf0c
movq -0x10(%rbp), %rdi
callq 0x1c50
movq -0x10(%rbp), %rdi
callq 0x4f20
movq %rax, -0x28(%rbp)
movl 0xe21c(%rip), %eax      # 0x1b144
addl $0x1, %eax
movl %eax, 0xe213(%rip)      # 0x1b144
movl $0x18, %edi
callq 0x1290
cmpq -0x28(%rbp), %rax
je 0xd019
movq 0xe084(%rip), %rax      # 0x1afd0
movq (%rax), %rdi
leaq 0x87d8(%rip), %rsi      # 0x1572e
movb $0x0, %al
callq 0x1100
movq 0xe06c(%rip), %rax      # 0x1afd0
movq (%rax), %rax
movq %rax, -0x48(%rbp)
movl $0x18, %edi
callq 0x1290
movq -0x48(%rbp), %rdi
movq %rax, %rdx
leaq 0x9345(%rip), %rsi      # 0x162c8
movb $0x0, %al
callq 0x1100
movq 0xe03f(%rip), %rax      # 0x1afd0
movq (%rax), %rdi
leaq 0x879f(%rip), %rsi      # 0x1573a
movb $0x0, %al
callq 0x1100
movq 0xe027(%rip), %rax      # 0x1afd0
movq (%rax), %rdi
movq -0x28(%rbp), %rdx
leaq 0x9311(%rip), %rsi      # 0x162c8
movb $0x0, %al
callq 0x1100
movq 0xe00b(%rip), %rax      # 0x1afd0
movq (%rax), %rdi
leaq 0x99ed(%rip), %rsi      # 0x169bc
movb $0x0, %al
callq 0x1100
leaq 0x76c6(%rip), %rax      # 0x146a3
movq %rax, 0xe16c(%rip)      # 0x1b150
movl $0x7c8, 0xe15a(%rip)    # imm = 0x7C8
leaq 0x92fd(%rip), %rax      # 0x162f2
movq %rax, 0xe15c(%rip)      # 0x1b158
movzbl 0xe0fd(%rip), %eax      # 0x1b100
andl $0x4, %eax
cmpl $0x0, %eax
je 0xd010
callq 0x1040
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xd036
jmp 0xd01b
movq -0x18(%rbp), %rdi
callq 0x1800
movq $0x0, 0xe129(%rip) # 0x1b158
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nop