// File: /workspace/github_cpp_makefile_star2_O3/adamnovak[P]rlcsa/docarray.cpp
// Function: CSA::STNode::verifyTree()
bool
STNode::verifyTree()
{
  if(this->child == 0) { return true; }

  usint expect = this->range.first, last = 0;
  for(STNode* temp = this->child; temp != 0; temp = temp->sibling)
  {
    if(!(temp->verifyTree())) { return false; }
    if(temp->range.first != expect)
    {
      std::cerr << "Error: node " << *this << ", expected " << expect << ", got " << *temp << std::endl;
      std::cerr << "Children:";
      for(temp = this->child; temp != 0; temp = temp->sibling) { std::cerr << " " << *temp; }
      std::cerr << std::endl;
      if(this->parent) { std::cerr << "Parent: " << *(this->parent) << std::endl; }
      return false;
    }
    expect = temp->range.second + 1;
    last = temp->range.second;
  }
  if(last != this->range.second)
  {
    std::cerr << "Error: node " << *this << ", children end at " << last << std::endl;
    return false;
  }

  return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x18(%rdi), %r15
movb $0x1, %bpl
testq %r15, %r15
je 0x11633
movq %rdi, %rbx
movl 0x4(%rdi), %r12d
movq %r15, %rdi
callq 0x1143e
testb %al, %al
je 0x11631
cmpl %r12d, 0x4(%r15)
jne 0x114de
movl 0x8(%r15), %r14d
leal 0x1(%r14), %r12d
movq 0x20(%r15), %r15
testq %r15, %r15
jne 0x11460
cmpl 0x8(%rbx), %r14d
je 0x11633
movq 0x16b58(%rip), %r15     # 0x27ff0
leaq 0xd491(%rip), %rsi      # 0x1e930
movl $0xc, %edx
movq %r15, %rdi
callq 0x32b0
movq %r15, %rdi
movq %rbx, %rsi
callq 0x11644
leaq 0xd4a5(%rip), %rsi      # 0x1e963
movl $0x12, %edx
movq %r15, %rdi
callq 0x32b0
movq %r15, %rdi
movq %r14, %rsi
callq 0x3180
movq %rax, %r14
jmp 0x1160a
movq 0x16b0b(%rip), %r14     # 0x27ff0
leaq 0xd444(%rip), %rsi      # 0x1e930
movl $0xc, %edx
movq %r14, %rdi
callq 0x32b0
movq %r14, %rdi
movq %rbx, %rsi
callq 0x11644
leaq 0xd432(%rip), %rsi      # 0x1e93d
movl $0xb, %edx
movq %r14, %rdi
callq 0x32b0
movl %r12d, %esi
movq %r14, %rdi
callq 0x3180
movq %rax, %r12
leaq 0xd41c(%rip), %rsi      # 0x1e949
movl $0x6, %edx
movq %rax, %rdi
callq 0x32b0
movq %r12, %rdi
movq %r15, %rsi
callq 0x11644
movq (%r12), %rax
movq -0x18(%rax), %rdi
addq %r12, %rdi
movl $0xa, %esi
callq 0x3240
movsbl %al, %esi
movq %r12, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3190
leaq 0xd3dc(%rip), %rsi      # 0x1e950
movl $0x9, %edx
movq %r14, %rdi
callq 0x32b0
movq 0x18(%rbx), %r15
testq %r15, %r15
je 0x115bc
movq 0x16a5f(%rip), %r12     # 0x27ff0
leaq 0xd356(%rip), %r13      # 0x1e8ee
movl $0x1, %edx
movq %r12, %rdi
movq %r13, %rsi
callq 0x32b0
movq %r12, %rdi
movq %r15, %rsi
callq 0x11644
movq 0x20(%r15), %r15
testq %r15, %r15
jne 0x11598
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x3240
movsbl %al, %esi
movq %r14, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3190
cmpq $0x0, 0x10(%rbx)
je 0x11631
leaq 0xd369(%rip), %rsi      # 0x1e95a
movl $0x8, %edx
movq %r14, %rdi
callq 0x32b0
movq 0x10(%rbx), %rsi
movq %r14, %rdi
callq 0x11644
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x3240
movsbl %al, %esi
movq %r14, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3190
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq