// File: biotomas[P]ipasir/sat/picosat961/picosat-961/picosat.c
// Function: picosat_add
int
picosat_add (PS * ps, int int_lit)
{
  int res = ps->oadded;
  Lit *lit;

  if (ps->measurealltimeinlib)
    enter (ps);
  else
    check_ready (ps);

  ABORTIF (ps->rup && ps->rupstarted && ps->oadded >= (unsigned)ps->rupclauses,
           "API usage: adding too many clauses after RUP header written");
#ifndef NADC
  ABORTIF (ps->addingtoado, 
           "API usage: 'picosat_add' and 'picosat_add_ado_lit' mixed");
#endif
  if (ps->state != READY)
    reset_incremental_usage (ps);

  if (ps->saveorig)
    {
      if (ps->sohead == ps->eoso)
	ENLARGE (ps->soclauses, ps->sohead, ps->eoso);

      *ps->sohead++ = int_lit;
    }

  if (int_lit)
    {
      lit = import_lit (ps, int_lit, 1);
      add_lit (ps, lit);
    }
  else
    simplify_and_add_original_clause (ps);

  if (ps->measurealltimeinlib)
    leave (ps);

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl 0x438(%rax), %eax
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x35c(%rax)
je 0x68b4
movq -0x8(%rbp), %rdi
callq 0x43a0
jmp 0x68bd
movq -0x8(%rbp), %rdi
callq 0x49e0
jmp 0x68bf
movq -0x8(%rbp), %rax
cmpq $0x0, 0x230(%rax)
je 0x68f0
movq -0x8(%rbp), %rax
cmpl $0x0, 0x238(%rax)
je 0x68f0
movq -0x8(%rbp), %rax
movl 0x438(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0x240(%rcx), %eax
jae 0x68f2
jmp 0x690f
jmp 0x68f4
movq 0x1d6fd(%rip), %rax     # 0x23ff8
movq (%rax), %rsi
leaq 0x16ad6(%rip), %rdi     # 0x1d3db
callq 0x10c0
callq 0x1060
movq -0x8(%rbp), %rax
cmpl $0x1, (%rax)
je 0x6921
movq -0x8(%rbp), %rdi
callq 0x4db0
movq -0x8(%rbp), %rax
cmpl $0x0, 0x228(%rax)
je 0x6a90
movq -0x8(%rbp), %rax
movq 0x218(%rax), %rax
movq -0x8(%rbp), %rcx
cmpq 0x220(%rcx), %rax
jne 0x6a72
jmp 0x6950
movq -0x8(%rbp), %rax
movq 0x220(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x210(%rcx), %rcx
subq %rcx, %rax
sarq $0x2, %rax
movl %eax, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0x6980
movl -0x1c(%rbp), %eax
shll %eax
movl %eax, -0x44(%rbp)
jmp 0x698a
movl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x698a
movl -0x44(%rbp), %eax
movl %eax, %eax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0x218(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x210(%rcx), %rcx
subq %rcx, %rax
sarq $0x2, %rax
movl %eax, -0x2c(%rbp)
movq -0x8(%rbp), %rax
movq 0x210(%rax), %rax
movq -0x8(%rbp), %rcx
cmpq 0x220(%rcx), %rax
ja 0x69cd
jmp 0x69ec
leaq 0x16a51(%rip), %rdi     # 0x1d425
leaq 0x168c9(%rip), %rsi     # 0x1d2a4
movl $0x1ab5, %edx           # imm = 0x1AB5
leaq 0x16a5c(%rip), %rcx     # 0x1d443
callq 0x10b0
jmp 0x69ee
movl -0x1c(%rbp), %eax
shlq $0x2, %rax
movq %rax, -0x38(%rbp)
movq -0x28(%rbp), %rax
shlq $0x2, %rax
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x210(%rax), %rsi
movq -0x38(%rbp), %rdx
movq -0x40(%rbp), %rcx
callq 0x4f30
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x210(%rax)
movq -0x8(%rbp), %rax
movq 0x210(%rax), %rcx
movl -0x2c(%rbp), %eax
shlq $0x2, %rax
addq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x218(%rax)
movq -0x8(%rbp), %rax
movq 0x210(%rax), %rcx
movq -0x28(%rbp), %rax
shlq $0x2, %rax
addq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x220(%rax)
jmp 0x6a72
movl -0xc(%rbp), %ecx
movq -0x8(%rbp), %rdx
movq 0x218(%rdx), %rax
movq %rax, %rsi
addq $0x4, %rsi
movq %rsi, 0x218(%rdx)
movl %ecx, (%rax)
cmpl $0x0, -0xc(%rbp)
je 0x6aba
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl $0x1, %edx
callq 0x6af0
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x6c80
jmp 0x6ac3
movq -0x8(%rbp), %rdi
callq 0x6e20
movq -0x8(%rbp), %rax
cmpl $0x0, 0x35c(%rax)
je 0x6ad9
movq -0x8(%rbp), %rdi
callq 0x4910
movl -0x10(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)