// File: jacky860226[P]JinkelaSat/src/include/JinkelaSat.hpp
// Function: MiniSat::JinkelaSat::propagate()
Clause *propagate() {
    Clause *confl = nullptr;
    int num_props = 0;
    while (qhead < trail.size()) {
      Literal p = trail[qhead++];
      std::vector<Watcher> &ws = watches[p];
      std::vector<Watcher>::iterator i, j;
      for (i = j = ws.begin(); i != ws.end();) {
        Literal blocker = i->blocker;
        if (value(blocker) == Status::True) {
          *j++ = *i++;
          continue;
        }
        auto cr = i->cref;
        Clause &c = *cr;
        if (c[0] == ~p)
          std::swap(c[0], c[1]);
        ++i;

        Literal first = c[0];
        Watcher w = Watcher(cr, first);
        if (first != blocker && value(first) == Status::True) {
          *j++ = w;
          continue;
        }

        for (size_t k = 2; k < c.size(); k++) {
          if (value(c[k]) != Status::False) {
            std::swap(c[1], c[k]);
            watches[~c[1]].emplace_back(w);
            goto NextClause;
          }
        }
        *j++ = w;
        if (value(first) == Status::False) {
          confl = cr;
          qhead = trail.size();
          while (i != ws.end())
            *j++ = *i++;
        } else
          uncheckedEnqueue(first, cr);
      NextClause:;
      }
      ws.resize(j - ws.begin());
    }
    simpDB_props -= num_props;
    return confl;
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x150, %rsp            # imm = 0x150
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xf0(%rbp)
movq $0x0, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
movq -0xf0(%rbp), %rdi
movq (%rdi), %rax
movq %rax, -0xf8(%rbp)
addq $0x8, %rdi
callq 0x3b30
movq %rax, %rcx
movq -0xf8(%rbp), %rax
cmpq %rcx, %rax
jae 0x4148
movq -0xf0(%rbp), %rax
movq %rax, %rdi
addq $0x8, %rdi
movq (%rax), %rsi
movq %rsi, %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
callq 0x3a20
movq %rax, %rcx
movq -0xf0(%rbp), %rax
movl (%rcx), %ecx
movl %ecx, -0x18(%rbp)
addq $0x120, %rax            # imm = 0x120
movq %rax, -0x100(%rbp)
leaq -0x18(%rbp), %rdi
callq 0x39e0
movq -0x100(%rbp), %rdi
movl %eax, -0x24(%rbp)
leaq -0x24(%rbp), %rsi
callq 0xc180
movq %rax, -0x20(%rbp)
leaq -0x30(%rbp), %rdi
callq 0xc1b0
leaq -0x38(%rbp), %rdi
callq 0xc1b0
movq -0x20(%rbp), %rdi
callq 0xc1d0
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rdi
callq 0xc240
movq %rax, -0x48(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0xc200
testb $0x1, %al
jne 0x3d14
jmp 0x4109
leaq -0x30(%rbp), %rdi
callq 0xc270
movq -0xf0(%rbp), %rdi
movl 0x8(%rax), %eax
movl %eax, -0x4c(%rbp)
movl -0x4c(%rbp), %eax
movl %eax, -0x50(%rbp)
movl -0x50(%rbp), %esi
callq 0x3960
movsbl %al, %eax
cmpl $0x1, %eax
jne 0x3d8f
leaq -0x30(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0x58(%rbp)
leaq -0x58(%rbp), %rdi
callq 0xc2d0
movq %rax, -0x108(%rbp)
leaq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0x60(%rbp)
leaq -0x60(%rbp), %rdi
callq 0xc2d0
movq -0x108(%rbp), %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movl 0x8(%rcx), %ecx
movl %ecx, 0x8(%rax)
jmp 0x3cf1
leaq -0x30(%rbp), %rdi
callq 0xc270
movq (%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x3a20
movq %rax, %rdi
callq 0x39e0
movl %eax, -0x10c(%rbp)
leaq -0x18(%rbp), %rdi
callq 0x39f0
movl %eax, -0x74(%rbp)
leaq -0x74(%rbp), %rdi
callq 0x39e0
movl %eax, %ecx
movl -0x10c(%rbp), %eax
cmpl %ecx, %eax
jne 0x3e14
movq -0x70(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x3a20
movq %rax, -0x118(%rbp)
movq -0x70(%rbp), %rdi
movl $0x1, %esi
callq 0x3a20
movq -0x118(%rbp), %rdi
movq %rax, %rsi
callq 0xa4a0
leaq -0x30(%rbp), %rdi
callq 0xc2f0
movq -0x70(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x3a20
movl (%rax), %eax
movl %eax, -0x78(%rbp)
movq -0x68(%rbp), %rsi
movl -0x78(%rbp), %eax
movl %eax, -0x8c(%rbp)
movl -0x8c(%rbp), %edx
leaq -0x88(%rbp), %rdi
callq 0xc310
leaq -0x78(%rbp), %rdi
callq 0x39e0
movl %eax, -0x11c(%rbp)
leaq -0x4c(%rbp), %rdi
callq 0x39e0
movl %eax, %ecx
movl -0x11c(%rbp), %eax
cmpl %ecx, %eax
je 0x3ec8
movq -0xf0(%rbp), %rdi
movl -0x78(%rbp), %eax
movl %eax, -0x90(%rbp)
movl -0x90(%rbp), %esi
callq 0x3960
movsbl %al, %eax
cmpl $0x1, %eax
jne 0x3ec8
leaq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0x98(%rbp)
leaq -0x98(%rbp), %rdi
callq 0xc2d0
movq -0x88(%rbp), %rcx
movq %rcx, (%rax)
movl -0x80(%rbp), %ecx
movl %ecx, 0x8(%rax)
jmp 0x3cf1
movq $0x2, -0xa0(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, -0x128(%rbp)
movq -0x70(%rbp), %rdi
callq 0x3b30
movq %rax, %rcx
movq -0x128(%rbp), %rax
cmpq %rcx, %rax
jae 0x3fe9
movq -0x70(%rbp), %rdi
movq -0xa0(%rbp), %rsi
callq 0x3a20
movq -0xf0(%rbp), %rdi
movl (%rax), %eax
movl %eax, -0xa4(%rbp)
movl -0xa4(%rbp), %esi
callq 0x3960
movsbl %al, %eax
cmpl $0x0, %eax
je 0x3fd0
movq -0x70(%rbp), %rdi
movl $0x1, %esi
callq 0x3a20
movq %rax, -0x138(%rbp)
movq -0x70(%rbp), %rdi
movq -0xa0(%rbp), %rsi
callq 0x3a20
movq -0x138(%rbp), %rdi
movq %rax, %rsi
callq 0xa4a0
movq -0xf0(%rbp), %rax
addq $0x120, %rax            # imm = 0x120
movq %rax, -0x130(%rbp)
movq -0x70(%rbp), %rdi
movl $0x1, %esi
callq 0x3a20
movq %rax, %rdi
callq 0x39f0
movl %eax, -0xac(%rbp)
leaq -0xac(%rbp), %rdi
callq 0x39e0
movq -0x130(%rbp), %rdi
movl %eax, -0xa8(%rbp)
leaq -0xa8(%rbp), %rsi
callq 0xc180
movq %rax, %rdi
leaq -0x88(%rbp), %rsi
callq 0xc340
jmp 0x4104
jmp 0x3fd2
movq -0xa0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xa0(%rbp)
jmp 0x3ed3
leaq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0xb8(%rbp)
leaq -0xb8(%rbp), %rdi
callq 0xc2d0
movq -0xf0(%rbp), %rdi
movq -0x88(%rbp), %rcx
movq %rcx, (%rax)
movl -0x80(%rbp), %ecx
movl %ecx, 0x8(%rax)
movl -0x78(%rbp), %eax
movl %eax, -0xbc(%rbp)
movl -0xbc(%rbp), %esi
callq 0x3960
movsbl %al, %eax
cmpl $0x0, %eax
jne 0x40e3
movq -0xf0(%rbp), %rdi
movq -0x68(%rbp), %rax
movq %rax, -0x10(%rbp)
addq $0x8, %rdi
callq 0x3b30
movq %rax, %rcx
movq -0xf0(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rdi
callq 0xc240
movq %rax, -0xc8(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0xc8(%rbp), %rsi
callq 0xc200
testb $0x1, %al
jne 0x4089
jmp 0x40e1
leaq -0x30(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0xd0(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0xc2d0
movq %rax, -0x140(%rbp)
leaq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0xc290
movq %rax, -0xd8(%rbp)
leaq -0xd8(%rbp), %rdi
callq 0xc2d0
movq -0x140(%rbp), %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movl 0x8(%rcx), %ecx
movl %ecx, 0x8(%rax)
jmp 0x4063
jmp 0x4102
movq -0xf0(%rbp), %rdi
movl -0x78(%rbp), %eax
movl %eax, -0xdc(%rbp)
movq -0x68(%rbp), %rdx
movl -0xdc(%rbp), %esi
callq 0x3b50
jmp 0x4104
jmp 0x3cf1
movq -0x20(%rbp), %rax
movq %rax, -0x148(%rbp)
movq -0x20(%rbp), %rdi
callq 0xc1d0
movq %rax, -0xe8(%rbp)
leaq -0x38(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
callq 0xc450
movq -0x148(%rbp), %rdi
movq %rax, %rsi
callq 0xc3c0
jmp 0x3c39
movq -0xf0(%rbp), %rax
movslq -0x14(%rbp), %rdx
movq 0x1e0(%rax), %rcx
subq %rdx, %rcx
movq %rcx, 0x1e0(%rax)
movq -0x10(%rbp), %rax
addq $0x150, %rsp            # imm = 0x150
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)