LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelPointGraph.cpp
// Function: gaps::R3SurfelPointGraph::Draw(gaps::RNFlags) const
void R3SurfelPointGraph::
Draw(RNFlags flags) const
{
  // Draw surfels
  set.Draw(flags);

  // Draw lines between neighbors
  RNGrfxBegin(RN_GRFX_LINES);
  for (int i = 0; i < NPoints(); i++) {
    R3SurfelPoint *point0 = Point(i);
    for (int j = 0; j < NNeighbors(i); j++) {
      R3SurfelPoint *point1 = Neighbor(i,j);
      R3LoadPoint(point0->Position());
      R3LoadPoint(point1->Position());
    }
  }
  RNGrfxEnd();
}

// Assembly:
subq $0x78, %rsp
movq %rsi, 0x70(%rsp)
movq %rdi, 0x68(%rsp)
movq 0x68(%rsp), %rdi
movq %rdi, 0x8(%rsp)
addq $0x8, %rdi
movq 0x70(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x60(%rsp), %rsi
callq 0x59f90
movl $0x1, %edi
callq 0x4ff50
movl $0x0, 0x5c(%rsp)
movq 0x8(%rsp), %rdi
movl 0x5c(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x43e20
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x5ddc3
movq 0x8(%rsp), %rdi
movl 0x5c(%rsp), %esi
callq 0x43e40
movq %rax, 0x50(%rsp)
movl $0x0, 0x4c(%rsp)
movq 0x8(%rsp), %rdi
movl 0x4c(%rsp), %eax
movl %eax, (%rsp)
movl 0x5c(%rsp), %esi
callq 0x43ef0
movl %eax, %ecx
movl (%rsp), %eax
cmpl %ecx, %eax
jge 0x5ddb1
movq 0x8(%rsp), %rdi
movl 0x5c(%rsp), %esi
movl 0x4c(%rsp), %edx
callq 0x43f20
movq %rax, 0x40(%rsp)
movq 0x50(%rsp), %rsi
leaq 0x28(%rsp), %rdi
callq 0x18730
leaq 0x28(%rsp), %rdi
callq 0x50050
movq 0x40(%rsp), %rsi
leaq 0x10(%rsp), %rdi
callq 0x18730
leaq 0x10(%rsp), %rdi
callq 0x50050
movl 0x4c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4c(%rsp)
jmp 0x5dd3d
jmp 0x5ddb3
movl 0x5c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x5c(%rsp)
jmp 0x5dd02
callq 0x50070
addq $0x78, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::~R3SurfelNode()
R3SurfelNode::
~R3SurfelNode(void)
{
  // Remove blocks from node
  while (NBlocks() > 0) RemoveBlock(Block(NBlocks()-1));

  // Remove node from object
  if (object) object->RemoveNode(this);

  // Remove node from scan
  if (scan) scan->SetNode(NULL);

  // Delete parts
  while (NParts() > 0) delete (Part(NParts()-1));
  
  // Remove node from tree
  if (tree) tree->RemoveNode(this);

  // Delete name
  if (name) free(name);
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x28(%rsp)
leaq 0x18feb6(%rip), %rcx    # 0x1ee9c0
addq $0x10, %rcx
movq %rcx, (%rax)
movq 0x28(%rsp), %rdi
callq 0x186b0
movl %eax, 0x24(%rsp)
jmp 0x5eb21
movl 0x24(%rsp), %eax
cmpl $0x0, %eax
jle 0x5eb68
movq 0x28(%rsp), %rdi
callq 0x186b0
movl %eax, 0x20(%rsp)
jmp 0x5eb3a
movq 0x28(%rsp), %rdi
movl 0x20(%rsp), %esi
decl %esi
callq 0x186d0
movq %rax, 0x18(%rsp)
jmp 0x5eb51
movq 0x18(%rsp), %rsi
movq 0x28(%rsp), %rdi
movq (%rdi), %rax
movq 0x30(%rax), %rax
callq *%rax
jmp 0x5eb66
jmp 0x5eb11
movq 0x28(%rsp), %rax
cmpq $0x0, 0x8(%rax)
je 0x5eb86
movq 0x28(%rsp), %rsi
movq 0x8(%rsi), %rdi
callq 0x191d0
jmp 0x5eb84
jmp 0x5eb86
movq 0x28(%rsp), %rax
cmpq $0x0, 0x10(%rax)
je 0x5ebac
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rdi
movq (%rdi), %rax
movq 0x78(%rax), %rax
xorl %ecx, %ecx
movl %ecx, %esi
callq *%rax
jmp 0x5ebaa
jmp 0x5ebac
jmp 0x5ebae
movq 0x28(%rsp), %rdi
callq 0x31660
movl %eax, 0x14(%rsp)
jmp 0x5ebbe
movl 0x14(%rsp), %eax
cmpl $0x0, %eax
jle 0x5ec06
movq 0x28(%rsp), %rdi
callq 0x31660
movl %eax, 0x10(%rsp)
jmp 0x5ebd7
movq 0x28(%rsp), %rdi
movl 0x10(%rsp), %esi
decl %esi
callq 0x43680
movq %rax, 0x8(%rsp)
jmp 0x5ebee
movq 0x8(%rsp), %rax
cmpq $0x0, %rax
je 0x5ec04
movq 0x8(%rsp), %rdi
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x5ebae
movq 0x28(%rsp), %rax
cmpq $0x0, 0x18(%rax)
je 0x5ec24
movq 0x28(%rsp), %rsi
movq 0x18(%rsi), %rdi
callq 0x62370
jmp 0x5ec22
jmp 0x5ec24
movq 0x28(%rsp), %rax
cmpq $0x0, 0xb8(%rax)
je 0x5ec44
movq 0x28(%rsp), %rax
movq 0xb8(%rax), %rdi
callq 0x136a0
movq 0x28(%rsp), %rdi
addq $0x60, %rdi
callq 0x1b990
movq 0x28(%rsp), %rdi
addq $0x40, %rdi
callq 0x43730
movq 0x28(%rsp), %rdi
addq $0x30, %rdi
callq 0x1b9a0
addq $0x38, %rsp
retq
movq %rax, %rdi
callq 0x187d0
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::AverageRadius() const
RNLength R3SurfelNode::
AverageRadius(void) const
{
  // Sum average radius of surfels 
  RNLength total_radius = 0;
  RNLength total_weight = 0;
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    RNScalar weight = block->NSurfels();
    total_radius += weight * block->AverageRadius();
    total_weight += weight;
  }

  // Return weighted average
  return (total_weight > 0) ? total_radius / total_weight : 0;
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x20(%rsp)
xorps %xmm0, %xmm0
movsd %xmm0, 0x48(%rsp)
xorps %xmm0, %xmm0
movsd %xmm0, 0x40(%rsp)
movl $0x0, 0x3c(%rsp)
movq 0x20(%rsp), %rdi
movl 0x3c(%rsp), %eax
movl %eax, 0x1c(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x1c(%rsp), %eax
cmpl %ecx, %eax
jge 0x5edf5
movq 0x20(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x186d0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
callq 0x1c0e0
cvtsi2sd %eax, %xmm0
movsd %xmm0, 0x28(%rsp)
movsd 0x28(%rsp), %xmm0
movsd %xmm0, 0x10(%rsp)
movq 0x30(%rsp), %rdi
callq 0x60fc0
movaps %xmm0, %xmm2
movsd 0x10(%rsp), %xmm0
movsd 0x48(%rsp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, 0x48(%rsp)
movsd 0x28(%rsp), %xmm0
addsd 0x40(%rsp), %xmm0
movsd %xmm0, 0x40(%rsp)
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0x5ed5d
movsd 0x40(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x5ee18
movsd 0x48(%rsp), %xmm0
divsd 0x40(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
jmp 0x5ee23
xorps %xmm0, %xmm0
movsd %xmm0, 0x8(%rsp)
jmp 0x5ee23
movsd 0x8(%rsp), %xmm0
addq $0x58, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::HasSurfels(int) const
RNBoolean R3SurfelNode::
HasSurfels(RNBoolean leaf_level) const
{
  // Check blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    if (block->NSurfels() > 0) return TRUE;
  }

  // Check parts
  if (leaf_level) {
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      if (part->HasSurfels(leaf_level)) return TRUE;
    }
  }

  // Did not find anything
  return FALSE;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movl %esi, 0x34(%rsp)
movq 0x38(%rsp), %rax
movq %rax, 0x10(%rsp)
movl $0x0, 0x30(%rsp)
movq 0x10(%rsp), %rdi
movl 0x30(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x5efa9
movq 0x10(%rsp), %rdi
movl 0x30(%rsp), %esi
callq 0x186d0
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
callq 0x1c0e0
cmpl $0x0, %eax
jle 0x5ef9a
movl $0x1, 0x44(%rsp)
jmp 0x5f01d
jmp 0x5ef9c
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x5ef4f
cmpl $0x0, 0x34(%rsp)
je 0x5f015
movl $0x0, 0x24(%rsp)
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x8(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x8(%rsp), %eax
cmpl %ecx, %eax
jge 0x5f013
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x43680
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl 0x34(%rsp), %esi
callq 0x5ef30
cmpl $0x0, %eax
je 0x5f004
movl $0x1, 0x44(%rsp)
jmp 0x5f01d
jmp 0x5f006
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x5efb8
jmp 0x5f015
movl $0x0, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::TreeLevel() const
int R3SurfelNode::
TreeLevel(void) const
{
  // Return level in part tree (root is 0)
  int level = 0;
  R3SurfelNode *ancestor = parent;
  while (ancestor) { level++; ancestor = ancestor->parent; }
  return level;
}

// Assembly:
movq %rdi, -0x8(%rsp)
movq -0x8(%rsp), %rax
movl $0x0, -0xc(%rsp)
movq 0x28(%rax), %rax
movq %rax, -0x18(%rsp)
cmpq $0x0, -0x18(%rsp)
je 0x5f2ae
movl -0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rsp)
movq -0x18(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x18(%rsp)
jmp 0x5f28b
movl -0xc(%rsp), %eax
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::Object(int, int) const
R3SurfelObject *R3SurfelNode::
Object(RNBoolean search_ancestors, RNBoolean search_descendants) const
{
  // Return object, if there is one associated with this node
  if (object) return object;

  // Search descendants for object
  if (search_descendants) {
    RNScalar best_complexity = 0;
    R3SurfelObject *best_object = NULL;
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      R3SurfelObject *object = part->Object(FALSE, TRUE);
      if (object) {
        RNScalar complexity = object->Complexity();
        if (complexity > best_complexity) {
          best_complexity = complexity;
          best_object = object;
        }
      }
    }
    if (best_object) return best_object;
  }

  // Search ancestors for object
  if (search_ancestors) {
    const R3SurfelNode *node = this;
    while (node) {
      R3SurfelObject *object = node->Object(FALSE, FALSE);
      if (object) return object;
      node = node->Parent();
    }
  }

  // Object not found
  return NULL;
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x58(%rsp)
movl %esi, 0x54(%rsp)
movl %edx, 0x50(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rax)
je 0x5f2f5
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x60(%rsp)
jmp 0x5f421
cmpl $0x0, 0x50(%rsp)
je 0x5f3c5
xorps %xmm0, %xmm0
movsd %xmm0, 0x48(%rsp)
movq $0x0, 0x40(%rsp)
movl $0x0, 0x3c(%rsp)
movq 0x8(%rsp), %rdi
movl 0x3c(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x5f3af
movq 0x8(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x43680
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0x5f2c0
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0x5f39d
movq 0x28(%rsp), %rdi
callq 0x1c0f0
movsd %xmm0, 0x20(%rsp)
movsd 0x20(%rsp), %xmm0
ucomisd 0x48(%rsp), %xmm0
jbe 0x5f39b
movsd 0x20(%rsp), %xmm0
movsd %xmm0, 0x48(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x40(%rsp)
jmp 0x5f39d
jmp 0x5f39f
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0x5f31a
cmpq $0x0, 0x40(%rsp)
je 0x5f3c3
movq 0x40(%rsp), %rax
movq %rax, 0x60(%rsp)
jmp 0x5f421
jmp 0x5f3c5
cmpl $0x0, 0x54(%rsp)
je 0x5f418
movq 0x8(%rsp), %rax
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
je 0x5f416
movq 0x18(%rsp), %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x5f2c0
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x5f405
movq 0x10(%rsp), %rax
movq %rax, 0x60(%rsp)
jmp 0x5f421
movq 0x18(%rsp), %rdi
callq 0x31100
movq %rax, 0x18(%rsp)
jmp 0x5f3d6
jmp 0x5f418
movq $0x0, 0x60(%rsp)
movq 0x60(%rsp), %rax
addq $0x68, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::Scan(int) const
R3SurfelScan *R3SurfelNode::
Scan(RNBoolean search_ancestors) const
{
  // Check if should search ancestors
  if (!search_ancestors) return scan;

  // Search ancestors for scan
  const R3SurfelNode *node = this;
  while (node) {
    R3SurfelScan *scan = node->Scan(FALSE);
    if (scan) return scan;
    node = node->Parent();
  }

  // Scan not found
  return NULL;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
cmpl $0x0, 0x24(%rsp)
jne 0x5f45e
movq 0x8(%rsp), %rax
movq 0x10(%rax), %rax
movq %rax, 0x30(%rsp)
jmp 0x5f4af
movq 0x8(%rsp), %rax
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
je 0x5f4a6
movq 0x18(%rsp), %rdi
xorl %esi, %esi
callq 0x5f430
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x5f495
movq 0x10(%rsp), %rax
movq %rax, 0x30(%rsp)
jmp 0x5f4af
movq 0x18(%rsp), %rdi
callq 0x31100
movq %rax, 0x18(%rsp)
jmp 0x5f468
movq $0x0, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::PointSet(int, double) const
R3SurfelPointSet *R3SurfelNode::
PointSet(RNBoolean leaf_level, RNScalar max_resolution) const
{
  // Allocate point set
  R3SurfelPointSet *pointset = new R3SurfelPointSet();
  if (!pointset) {
    RNFail("Unable to allocate point set\n");
    return NULL;
  }

  // Insert surfels from this node into pointset
  InsertIntoPointSet(pointset, leaf_level, max_resolution);

  // Return pointset
  return pointset;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movl %esi, 0x34(%rsp)
movsd %xmm0, 0x28(%rsp)
movq 0x38(%rsp), %rax
movq %rax, (%rsp)
movl $0x60, %edi
callq 0x13570
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x8(%rsp)
callq 0x55df0
jmp 0x5f4f8
movq 0x8(%rsp), %rax
movq %rax, 0x20(%rsp)
cmpq $0x0, 0x20(%rsp)
jne 0x5f542
leaq 0x144e37(%rip), %rdi    # 0x1a4348
movb $0x0, %al
callq 0x1464b0
movq $0x0, 0x40(%rsp)
jmp 0x5f564
movq 0x8(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
movl $0x60, %esi
callq 0x13580
jmp 0x5f56e
movq (%rsp), %rdi
movq 0x20(%rsp), %rsi
movl 0x34(%rsp), %edx
movsd 0x28(%rsp), %xmm0
callq 0x5f580
movq 0x20(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rax
addq $0x48, %rsp
retq
movq 0x18(%rsp), %rdi
callq 0x13970
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::InsertIntoPointSet(gaps::R3SurfelPointSet*, int, double) const
void R3SurfelNode::
InsertIntoPointSet(R3SurfelPointSet *pointset, RNBoolean leaf_level, RNScalar max_resolution) const
{
  // Insert points
  if (leaf_level && (NParts() > 0)) {
    // Insert points from all decendent parts at leaf level
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      part->InsertIntoPointSet(pointset, leaf_level, max_resolution);
    }
  }
  else {
    // Insert points from all blocks in this node
    for (int i = 0; i < NBlocks(); i++) {
      R3SurfelBlock *block = Block(i);
      pointset->InsertPoints(block, max_resolution);
    }
  }
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movl %edx, 0x44(%rsp)
movsd %xmm0, 0x38(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x44(%rsp)
je 0x5f617
movq 0x10(%rsp), %rdi
callq 0x31660
cmpl $0x0, %eax
jle 0x5f617
movl $0x0, 0x34(%rsp)
movq 0x10(%rsp), %rdi
movl 0x34(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x5f615
movq 0x10(%rsp), %rdi
movl 0x34(%rsp), %esi
callq 0x43680
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movq 0x48(%rsp), %rsi
movl 0x44(%rsp), %edx
movsd 0x38(%rsp), %xmm0
callq 0x5f580
movl 0x34(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x34(%rsp)
jmp 0x5f5c0
jmp 0x5f673
movl $0x0, 0x24(%rsp)
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x8(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x8(%rsp), %eax
cmpl %ecx, %eax
jge 0x5f671
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x186d0
movq %rax, 0x18(%rsp)
movq 0x48(%rsp), %rdi
movq 0x18(%rsp), %rsi
movsd 0x38(%rsp), %xmm0
movq (%rdi), %rax
callq *0x38(%rax)
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x5f61f
jmp 0x5f673
addq $0x58, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::SetName(char const*)
void R3SurfelNode::
SetName(const char *name)
{
  // Delete previous name
  if (this->name) free(this->name);
  this->name = (name) ? RNStrdup(name) : NULL;

  // Mark scene as dirty
  if (Tree() && Tree()->Scene()) Tree()->Scene()->SetDirty();
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, 0xb8(%rax)
je 0x5f6b3
movq 0x10(%rsp), %rax
movq 0xb8(%rax), %rdi
callq 0x136a0
cmpq $0x0, 0x18(%rsp)
je 0x5f6cc
movq 0x18(%rsp), %rdi
callq 0x1461b0
movq %rax, 0x8(%rsp)
jmp 0x5f6d5
xorl %eax, %eax
movq %rax, 0x8(%rsp)
jmp 0x5f6d5
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rax
movq %rax, 0xb8(%rdi)
callq 0x61030
cmpq $0x0, %rax
je 0x5f723
movq 0x10(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
cmpq $0x0, %rax
je 0x5f723
movq 0x10(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
movq %rax, %rdi
callq 0x1bea0
addq $0x28, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::InsertBlock(gaps::R3SurfelBlock*)
void R3SurfelNode::
InsertBlock(R3SurfelBlock *block)
{
  // Just checking
  assert(block->node == NULL);
  assert(!blocks.FindEntry(block));

  // Insert block
  blocks.Insert(block);

  // Update properties
  R3SurfelNode *ancestor = this;
  while (ancestor) {
    if (ancestor->complexity == -1) break;
    ancestor->complexity = -1;
    ancestor->bbox[0][0] = FLT_MAX;
    ancestor->timestamp_range[0] = FLT_MAX;
    ancestor = ancestor->parent;
  }

  // Mark resolution out of date
  resolution = -1;

  // Update block
  block->UpdateAfterInsert(this);

  // Update object
  if (object) object->UpdateAfterInsertBlock(this, block);

  // Mark scene as dirty
  if (Tree() && Tree()->Scene()) Tree()->Scene()->SetDirty();
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
addq $0x40, %rdi
movq 0x18(%rsp), %rsi
callq 0x436c0
movq 0x8(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x5fa42
movq 0x10(%rsp), %rax
movsd 0x50(%rax), %xmm0
movsd 0x1447b2(%rip), %xmm1   # 0x1a4180
ucomisd %xmm1, %xmm0
jne 0x5f9d8
jp 0x5f9d8
jmp 0x5fa42
movq 0x10(%rsp), %rax
movsd 0x14479b(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x50(%rax)
movq 0x10(%rsp), %rdi
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd 0x144784(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x10(%rsp), %rdi
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd 0x144765(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x10(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, 0x10(%rsp)
jmp 0x5f9b0
movq 0x8(%rsp), %rsi
movsd 0x144731(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x58(%rsi)
movq 0x18(%rsp), %rdi
callq 0x4f760
movq 0x8(%rsp), %rax
cmpq $0x0, 0x8(%rax)
je 0x5fa7d
movq 0x8(%rsp), %rsi
movq 0x8(%rsi), %rdi
movq 0x18(%rsp), %rdx
callq 0x1b590
movq 0x8(%rsp), %rdi
callq 0x61030
cmpq $0x0, %rax
je 0x5fabf
movq 0x8(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
cmpq $0x0, %rax
je 0x5fabf
movq 0x8(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
movq %rax, %rdi
callq 0x1bea0
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::RemoveBlock(gaps::R3SurfelBlock*)
void R3SurfelNode::
RemoveBlock(R3SurfelBlock *block)
{
  // Just checking
  assert(block->node == this);
  assert(blocks.FindEntry(block));

  // Update object
  if (object) object->UpdateBeforeRemoveBlock(this, block);

  // Update block
  block->UpdateBeforeRemove(this);

  // Remove block
  blocks.Remove(block);

  // Mark resolution out of date
  resolution = -1;

  // Invalidate properties
  R3SurfelNode *ancestor = this;
  while (ancestor) {
    if (ancestor->complexity == -1) break;
    ancestor->complexity = -1;
    ancestor->bbox[0][0] = FLT_MAX;
    ancestor->timestamp_range[0] = FLT_MAX;
    ancestor = ancestor->parent;
  }

  // Mark scene as dirty
  if (Tree() && Tree()->Scene()) Tree()->Scene()->SetDirty();
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rax)
je 0x5fb02
movq 0x8(%rsp), %rsi
movq 0x8(%rsi), %rdi
movq 0x18(%rsp), %rdx
callq 0x1b6c0
movq 0x8(%rsp), %rsi
movq 0x18(%rsp), %rdi
callq 0x4f780
movq 0x8(%rsp), %rdi
addq $0x40, %rdi
movq 0x18(%rsp), %rsi
callq 0x61050
movq 0x8(%rsp), %rax
movsd 0x14464f(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x58(%rax)
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x5fbcd
movq 0x10(%rsp), %rax
movsd 0x50(%rax), %xmm0
movsd 0x144627(%rip), %xmm1   # 0x1a4180
ucomisd %xmm1, %xmm0
jne 0x5fb63
jp 0x5fb63
jmp 0x5fbcd
movq 0x10(%rsp), %rax
movsd 0x144610(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x50(%rax)
movq 0x10(%rsp), %rdi
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd 0x1445f9(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x10(%rsp), %rdi
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd 0x1445da(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x10(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, 0x10(%rsp)
jmp 0x5fb3b
movq 0x8(%rsp), %rdi
callq 0x61030
cmpq $0x0, %rax
je 0x5fc0f
movq 0x8(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
cmpq $0x0, %rax
je 0x5fc0f
movq 0x8(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
movq %rax, %rdi
callq 0x1bea0
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::Transform(gaps::R3Affine const&)
void R3SurfelNode::
Transform(const R3Affine& transformation) 
{
  // Transform all blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    block->Transform(transformation);
  }

  // Update resolution
  RNScalar scale = transformation.ScaleFactor();
  if ((resolution > 0) && (RNIsNotEqual(scale, 1.0))) resolution /= scale * scale;

  // Invalidate bounding boxes starting at this node
  R3SurfelNode *ancestor = this;
  while (ancestor) {
    ancestor->bbox[0][0] = FLT_MAX;
    ancestor->timestamp_range[0] = FLT_MAX;
    ancestor = ancestor->parent;
  }

  // Update object
  if (object) object->UpdateAfterTransform(this);

  // Mark scene as dirty
  if (Tree() && Tree()->Scene()) Tree()->Scene()->SetDirty();
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
movl $0x0, 0x34(%rsp)
movq 0x10(%rsp), %rdi
movl 0x34(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x5fc8b
movq 0x10(%rsp), %rdi
movl 0x34(%rsp), %esi
callq 0x186d0
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x4bd40
movl 0x34(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x34(%rsp)
jmp 0x5fc40
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0xc0(%rax)
movq 0x10(%rsp), %rax
movsd %xmm0, 0x20(%rsp)
movsd 0x58(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x5fcf4
movsd 0x20(%rsp), %xmm0
leaq 0x19c889(%rip), %rax    # 0x1fc548
movsd (%rax), %xmm2
movsd 0x14449d(%rip), %xmm1   # 0x1a4168
callq 0x547b0
cmpl $0x0, %eax
je 0x5fcf4
movq 0x10(%rsp), %rax
movsd 0x20(%rsp), %xmm1
mulsd 0x20(%rsp), %xmm1
movsd 0x58(%rax), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, 0x58(%rax)
movq 0x10(%rsp), %rax
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
je 0x5fd5b
movq 0x18(%rsp), %rdi
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd 0x144468(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x18(%rsp), %rdi
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd 0x144449(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq 0x18(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, 0x18(%rsp)
jmp 0x5fcfe
movq 0x10(%rsp), %rax
cmpq $0x0, 0x8(%rax)
je 0x5fd75
movq 0x10(%rsp), %rsi
movq 0x8(%rsi), %rdi
callq 0x1b7f0
movq 0x10(%rsp), %rdi
callq 0x61030
cmpq $0x0, %rax
je 0x5fdb7
movq 0x10(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
cmpq $0x0, %rax
je 0x5fdb7
movq 0x10(%rsp), %rdi
callq 0x61030
movq %rax, %rdi
callq 0x61040
movq %rax, %rdi
callq 0x1bea0
addq $0x48, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::SetMarks(int)
void R3SurfelNode::
SetMarks(RNBoolean mark)
{
  // Set mark for all blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    block->SetMarks(mark);
  }
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0x0, 0x18(%rsp)
movq 0x8(%rsp), %rdi
movl 0x18(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x5fe29
movq 0x8(%rsp), %rdi
movl 0x18(%rsp), %esi
callq 0x186d0
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movl 0x1c(%rsp), %esi
callq 0x4bcd0
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x5fddf
addq $0x28, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::ReadBlocks(int)
void R3SurfelNode::
ReadBlocks(RNBoolean entire_subtree)
{
  // Read blocks in node
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    R3SurfelDatabase *database = block->Database();
    if (database) database->ReadBlock(block);
  }

  // Read blocks in parts
  if (entire_subtree) {
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      part->ReadBlocks(entire_subtree);
    }
  }
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movl %esi, 0x3c(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
movl $0x0, 0x38(%rsp)
movq 0x10(%rsp), %rdi
movl 0x38(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x5feb3
movq 0x10(%rsp), %rdi
movl 0x38(%rsp), %esi
callq 0x186d0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
callq 0x43610
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0x5fea4
movq 0x28(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x31140
jmp 0x5fea6
movl 0x38(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x38(%rsp)
jmp 0x5fe4f
cmpl $0x0, 0x3c(%rsp)
je 0x5ff0e
movl $0x0, 0x24(%rsp)
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x8(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x8(%rsp), %eax
cmpl %ecx, %eax
jge 0x5ff0c
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x43680
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x5fe30
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x5fec2
jmp 0x5ff0e
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::ReleaseBlocks(int)
void R3SurfelNode::
ReleaseBlocks(RNBoolean entire_subtree)
{
  // Release blocks in node
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    R3SurfelDatabase *database = block->Database();
    if (database) database->ReleaseBlock(block);
  }

  // Release blocks in parts
  if (entire_subtree) {
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      part->ReleaseBlocks(entire_subtree);
    }
  }
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movl %esi, 0x3c(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
movl $0x0, 0x38(%rsp)
movq 0x10(%rsp), %rdi
movl 0x38(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x5ffa3
movq 0x10(%rsp), %rdi
movl 0x38(%rsp), %esi
callq 0x186d0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
callq 0x43610
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0x5ff94
movq 0x28(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x311c0
jmp 0x5ff96
movl 0x38(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x38(%rsp)
jmp 0x5ff3f
cmpl $0x0, 0x3c(%rsp)
je 0x5fffe
movl $0x0, 0x24(%rsp)
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x8(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x8(%rsp), %eax
cmpl %ecx, %eax
jge 0x5fffc
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x43680
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x5ff20
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x5ffb2
jmp 0x5fffe
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::AreBlocksResident() const
RNBoolean R3SurfelNode::
AreBlocksResident(void) const
{
  // Return whether blocks are in memory
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    R3SurfelDatabase *database = block->Database();
    if (!database->IsBlockResident(block)) return FALSE;
  }

  // All blocks are resident
  return TRUE;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0x0, 0x24(%rsp)
movq 0x8(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x60096
movq 0x8(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x186d0
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
callq 0x43610
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x43630
cmpl $0x0, %eax
jne 0x60087
movl $0x0, 0x34(%rsp)
jmp 0x6009e
jmp 0x60089
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x6002b
movl $0x1, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::Print(_IO_FILE*, char const*, char const*) const
void R3SurfelNode::
Print(FILE *fp, const char *prefix, const char *suffix) const
{
  // Check fp
  if (!fp) fp = stdout;

  // Print node
  if (prefix) fprintf(fp, "%s", prefix);
  fprintf(fp, "%d %s", TreeIndex(), (Name()) ? Name() : "-");
  if (suffix) fprintf(fp, "%s", suffix);
  fprintf(fp, "\n");

  // Print all surfel blocks
  if (prefix) fprintf(fp, "%s", prefix);
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    fprintf(fp, "%d ", block->DatabaseIndex());
  }
  if (suffix) fprintf(fp, "%s", suffix);
  fprintf(fp, "\n");
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq %rdx, 0x50(%rsp)
movq %rcx, 0x48(%rsp)
movq 0x60(%rsp), %rax
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x58(%rsp)
jne 0x600e9
movq 0x192eaf(%rip), %rax    # 0x1f2f90
movq (%rax), %rax
movq %rax, 0x58(%rsp)
cmpq $0x0, 0x50(%rsp)
je 0x60109
movq 0x58(%rsp), %rdi
movq 0x50(%rsp), %rdx
leaq 0x1474c1(%rip), %rsi    # 0x1a75c3
movb $0x0, %al
callq 0x13810
movq 0x30(%rsp), %rdi
movq 0x58(%rsp), %rax
movq %rax, 0x20(%rsp)
callq 0x31130
movq 0x30(%rsp), %rdi
movl %eax, 0x2c(%rsp)
callq 0x31110
cmpq $0x0, %rax
je 0x60142
movq 0x30(%rsp), %rdi
callq 0x31110
movq %rax, 0x18(%rsp)
jmp 0x60150
leaq 0x144223(%rip), %rax    # 0x1a436c
movq %rax, 0x18(%rsp)
jmp 0x60150
movl 0x2c(%rsp), %edx
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rcx
leaq 0x144201(%rip), %rsi    # 0x1a4366
movb $0x0, %al
callq 0x13810
cmpq $0x0, 0x48(%rsp)
je 0x6018c
movq 0x58(%rsp), %rdi
movq 0x48(%rsp), %rdx
leaq 0x14743e(%rip), %rsi    # 0x1a75c3
movb $0x0, %al
callq 0x13810
movq 0x58(%rsp), %rdi
leaq 0x14b55a(%rip), %rsi    # 0x1ab6f2
movb $0x0, %al
callq 0x13810
cmpq $0x0, 0x50(%rsp)
je 0x601bf
movq 0x58(%rsp), %rdi
movq 0x50(%rsp), %rdx
leaq 0x14740b(%rip), %rsi    # 0x1a75c3
movb $0x0, %al
callq 0x13810
movl $0x0, 0x44(%rsp)
movq 0x30(%rsp), %rdi
movl 0x44(%rsp), %eax
movl %eax, 0x14(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x14(%rsp), %eax
cmpl %ecx, %eax
jge 0x6022c
movq 0x30(%rsp), %rdi
movl 0x44(%rsp), %esi
callq 0x186d0
movq %rax, 0x38(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x38(%rsp), %rdi
callq 0x31b10
movq 0x8(%rsp), %rdi
movl %eax, %edx
leaq 0x144667(%rip), %rsi    # 0x1a487f
movb $0x0, %al
callq 0x13810
movl 0x44(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x44(%rsp)
jmp 0x601c7
cmpq $0x0, 0x48(%rsp)
je 0x6024c
movq 0x58(%rsp), %rdi
movq 0x48(%rsp), %rdx
leaq 0x14737e(%rip), %rsi    # 0x1a75c3
movb $0x0, %al
callq 0x13810
movq 0x58(%rsp), %rdi
leaq 0x14b49a(%rip), %rsi    # 0x1ab6f2
movb $0x0, %al
callq 0x13810
addq $0x68, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::Draw(gaps::RNFlags) const
void R3SurfelNode::
Draw(RNFlags flags) const
{
  // Draw all blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    block->Draw(flags);
  }
}

// Assembly:
subq $0x38, %rsp
movq %rsi, 0x30(%rsp)
movq %rdi, 0x28(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0x0, 0x24(%rsp)
movq 0x8(%rsp), %rdi
movl 0x24(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x602ea
movq 0x8(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x186d0
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rsi
movl $0x1, %edx
callq 0x4c560
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x60290
addq $0x38, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::DrawResidentDescendents(gaps::RNFlags) const
int R3SurfelNode::
DrawResidentDescendents(RNFlags draw_flags) const
{
  // Initialize return status
  int status = 0;

  // Draw parts
  if (NParts() > 0) {
    // Draw resident descendents of all parts
    status = 1;
    for (int i = 0; i < NParts(); i++) {
      R3SurfelNode *part = Part(i);
      status &= part->DrawResidentDescendents(draw_flags);
    }
  }

  // Draw node if resident
  if (status == 0) {
    if (AreBlocksResident()) {
      Draw(draw_flags);
      status = 1;
    }
  }

  // Return whether drew everything
  return status;
}

// Assembly:
subq $0x48, %rsp
movq %rsi, 0x40(%rsp)
movq %rdi, 0x38(%rsp)
movq 0x38(%rsp), %rdi
movq %rdi, 0x10(%rsp)
movl $0x0, 0x34(%rsp)
callq 0x31660
cmpl $0x0, %eax
jle 0x6038a
movl $0x1, 0x34(%rsp)
movl $0x0, 0x30(%rsp)
movq 0x10(%rsp), %rdi
movl 0x30(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x60388
movq 0x10(%rsp), %rdi
movl 0x30(%rsp), %esi
callq 0x43680
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
movq 0x40(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rsi
movq (%rdi), %rax
callq *0x58(%rax)
andl 0x34(%rsp), %eax
movl %eax, 0x34(%rsp)
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x6032a
jmp 0x6038a
cmpl $0x0, 0x34(%rsp)
jne 0x603c4
movq 0x10(%rsp), %rdi
callq 0x60010
cmpl $0x0, %eax
je 0x603c2
movq 0x10(%rsp), %rdi
movq 0x40(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rsi
movq (%rdi), %rax
callq *0x48(%rax)
movl $0x1, 0x34(%rsp)
jmp 0x603c4
movl 0x34(%rsp), %eax
addq $0x48, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateAfterInsert(gaps::R3SurfelTree*)
void R3SurfelNode::
UpdateAfterInsert(R3SurfelTree *tree)
{
  // Invalidate properties
  R3SurfelNode *ancestor = parent;
  while (ancestor) {
    if (ancestor->complexity == -1) break;
    ancestor->complexity = -1;
    ancestor->bbox[0][0] = FLT_MAX;
    ancestor->timestamp_range[0] = FLT_MAX;
    // while (ancestor->NBlocks()) { 
    //   R3SurfelBlock *block = ancestor->Block(0);
    //   ancestor->RemoveBlock(block);
    //   database->RemoveBlock(block);
    //   delete block;
    // }
    ancestor = ancestor->parent;
  }
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
je 0x60636
movq (%rsp), %rax
movsd 0x50(%rax), %xmm0
movsd 0x143bb9(%rip), %xmm1   # 0x1a4180
ucomisd %xmm1, %xmm0
jne 0x605d1
jp 0x605d1
jmp 0x60636
movq (%rsp), %rax
movsd 0x143ba3(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x50(%rax)
movq (%rsp), %rdi
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd 0x143b8d(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq (%rsp), %rdi
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd 0x143b6f(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq (%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, (%rsp)
jmp 0x605ab
addq $0x18, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateBeforeRemove(gaps::R3SurfelTree*)
void R3SurfelNode::
UpdateBeforeRemove(R3SurfelTree *tree)
{
  // Invalidate properties
  R3SurfelNode *ancestor = parent;
  while (ancestor) {
    if (ancestor->complexity == -1) break;
    ancestor->complexity = -1;
    ancestor->bbox[0][0] = FLT_MAX;
    ancestor->timestamp_range[0] = FLT_MAX;
    // while (ancestor->NBlocks()) { 
    //   R3SurfelBlock *block = ancestor->Block(0);
    //   ancestor->RemoveBlock(block);
    //   database->RemoveBlock(block);
    //   delete block;
    // }
    ancestor = ancestor->parent;
  }
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
je 0x606e6
movq (%rsp), %rax
movsd 0x50(%rax), %xmm0
movsd 0x143b09(%rip), %xmm1   # 0x1a4180
ucomisd %xmm1, %xmm0
jne 0x60681
jp 0x60681
jmp 0x606e6
movq (%rsp), %rax
movsd 0x143af3(%rip), %xmm0   # 0x1a4180
movsd %xmm0, 0x50(%rax)
movq (%rsp), %rdi
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd 0x143add(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq (%rsp), %rdi
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd 0x143abf(%rip), %xmm0   # 0x1a4190
movsd %xmm0, (%rax)
movq (%rsp), %rax
movq 0x28(%rax), %rax
movq %rax, (%rsp)
jmp 0x6065b
addq $0x18, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateProperties()
void R3SurfelNode::
UpdateProperties(void)
{
  // Update surfels
  UpdateSurfelNormals();

  // Update properties
  double dummy = 0;
  dummy += Complexity();
  dummy += Resolution();
  dummy += BBox().Min().X();
  dummy += ElevationRange().Min();
  dummy += TimestampRange().Min();
  if (dummy == 927612.21242) {
    printf("Amazing!\n");
  }
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq %rdi, (%rsp)
movq (%rdi), %rax
callq *0x98(%rax)
movq (%rsp), %rdi
xorps %xmm0, %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x5ecb0
movq (%rsp), %rdi
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x5ecf0
movq (%rsp), %rdi
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x5ee30
movq %rax, %rdi
callq 0x1c110
movq %rax, %rdi
callq 0x187b0
movq (%rsp), %rdi
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x5ee90
movq %rax, %rdi
callq 0x1bc30
movq (%rsp), %rdi
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x5eee0
movq %rax, %rdi
callq 0x1bc30
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x8(%rsp), %xmm0
movsd 0x143b95(%rip), %xmm1   # 0x1a4340
ucomisd %xmm1, %xmm0
jne 0x607c1
jp 0x607c1
leaq 0x143bb4(%rip), %rdi    # 0x1a436e
movb $0x0, %al
callq 0x13070
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateBBox()
void R3SurfelNode::
UpdateBBox(void)
{
  // Check if bounding box is uptodate
  if (bbox[0][0] != FLT_MAX) return;

  // Initialize bounding box
  bbox = R3null_box;

  // Union bounding boxes of blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    bbox.Union(block->BBox());
  }

  // Union bounding boxes of parts
  for (int i = 0; i < NParts(); i++) {
    R3SurfelNode *part = Part(i);
    bbox.Union(part->BBox());
  }
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq 0x50(%rsp), %rdi
movq %rdi, 0x28(%rsp)
addq $0x60, %rdi
xorl %esi, %esi
callq 0x1bda0
movq %rax, %rdi
xorl %esi, %esi
callq 0x1bde0
movsd (%rax), %xmm0
movsd 0x14398c(%rip), %xmm1   # 0x1a4190
ucomisd %xmm1, %xmm0
jne 0x6080e
jp 0x6080e
jmp 0x60813
jmp 0x60900
movq 0x28(%rsp), %rdi
addq $0x60, %rdi
leaq 0x19cae5(%rip), %rsi    # 0x1fd308
callq 0x1bd40
movl $0x0, 0x4c(%rsp)
movq 0x28(%rsp), %rdi
movl 0x4c(%rsp), %eax
movl %eax, 0x24(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x24(%rsp), %eax
cmpl %ecx, %eax
jge 0x60894
movq 0x28(%rsp), %rdi
movl 0x4c(%rsp), %esi
callq 0x186d0
movq %rax, %rcx
movq 0x28(%rsp), %rax
movq %rcx, 0x40(%rsp)
addq $0x60, %rax
movq %rax, 0x18(%rsp)
movq 0x40(%rsp), %rdi
callq 0x4a500
movq 0x18(%rsp), %rdi
movq %rax, %rsi
callq 0xcbc30
movl 0x4c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4c(%rsp)
jmp 0x60830
movl $0x0, 0x3c(%rsp)
movq 0x28(%rsp), %rdi
movl 0x3c(%rsp), %eax
movl %eax, 0x14(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x14(%rsp), %eax
cmpl %ecx, %eax
jge 0x60900
movq 0x28(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x43680
movq %rax, %rcx
movq 0x28(%rsp), %rax
movq %rcx, 0x30(%rsp)
addq $0x60, %rax
movq %rax, 0x8(%rsp)
movq 0x30(%rsp), %rdi
callq 0x5ee30
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0xcbc30
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0x6089c
addq $0x58, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateElevationRange()
void R3SurfelNode::
UpdateElevationRange(void)
{
  // Check if range is uptodate
  if (elevation_range[0] != FLT_MAX) return;

  // Initialize elevation range
  elevation_range.Reset(FLT_MAX,-FLT_MAX);

  // Compute elevation range
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    RNInterval block_range = block->ElevationRange();
    elevation_range.Union(block_range);
  }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x8(%rsp)
addq $0x98, %rdi
xorl %esi, %esi
callq 0x1be00
movsd (%rax), %xmm0
movsd 0x143853(%rip), %xmm1   # 0x1a4190
ucomisd %xmm1, %xmm0
jne 0x60947
jp 0x60947
jmp 0x6094c
jmp 0x609d6
movq 0x8(%rsp), %rdi
addq $0x98, %rdi
movsd 0x143830(%rip), %xmm0   # 0x1a4190
movsd 0x143820(%rip), %xmm1   # 0x1a4188
callq 0x1c150
movl $0x0, 0x2c(%rsp)
movq 0x8(%rsp), %rdi
movl 0x2c(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x609d6
movq 0x8(%rsp), %rdi
movl 0x2c(%rsp), %esi
callq 0x186d0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rsi
leaq 0x10(%rsp), %rdi
callq 0x4a6c0
movq 0x8(%rsp), %rdi
addq $0x98, %rdi
leaq 0x10(%rsp), %rsi
callq 0x1bbc0
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x60975
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateTimestampRange()
void R3SurfelNode::
UpdateTimestampRange(void)
{
  // Check if range is uptodate
  if (timestamp_range[0] != FLT_MAX) return;

  // Initialize timestamp range
  timestamp_range.Reset(FLT_MAX,-FLT_MAX);

  // Union timestamp ranges of blocks
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    timestamp_range.Union(block->TimestampRange());
  }

  // Union timestamp ranges of parts
  for (int i = 0; i < NParts(); i++) {
    R3SurfelNode *part = Part(i);
    timestamp_range.Union(part->TimestampRange());
  }
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq 0x50(%rsp), %rdi
movq %rdi, 0x28(%rsp)
addq $0xa8, %rdi
xorl %esi, %esi
callq 0x1be00
movsd (%rax), %xmm0
movsd 0x143783(%rip), %xmm1   # 0x1a4190
ucomisd %xmm1, %xmm0
jne 0x60a17
jp 0x60a17
jmp 0x60a1c
jmp 0x60b19
movq 0x28(%rsp), %rdi
addq $0xa8, %rdi
movsd 0x143760(%rip), %xmm0   # 0x1a4190
movsd 0x143750(%rip), %xmm1   # 0x1a4188
callq 0x1c150
movl $0x0, 0x4c(%rsp)
movq 0x28(%rsp), %rdi
movl 0x4c(%rsp), %eax
movl %eax, 0x24(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x24(%rsp), %eax
cmpl %ecx, %eax
jge 0x60aab
movq 0x28(%rsp), %rdi
movl 0x4c(%rsp), %esi
callq 0x186d0
movq %rax, %rcx
movq 0x28(%rsp), %rax
movq %rcx, 0x40(%rsp)
addq $0xa8, %rax
movq %rax, 0x18(%rsp)
movq 0x40(%rsp), %rdi
callq 0x4a780
movq 0x18(%rsp), %rdi
movq %rax, %rsi
callq 0x1bbc0
movl 0x4c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4c(%rsp)
jmp 0x60a45
movl $0x0, 0x3c(%rsp)
movq 0x28(%rsp), %rdi
movl 0x3c(%rsp), %eax
movl %eax, 0x14(%rsp)
callq 0x31660
movl %eax, %ecx
movl 0x14(%rsp), %eax
cmpl %ecx, %eax
jge 0x60b19
movq 0x28(%rsp), %rdi
movl 0x3c(%rsp), %esi
callq 0x43680
movq %rax, %rcx
movq 0x28(%rsp), %rax
movq %rcx, 0x30(%rsp)
addq $0xa8, %rax
movq %rax, 0x8(%rsp)
movq 0x30(%rsp), %rdi
callq 0x5eee0
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0x1bbc0
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0x60ab3
addq $0x58, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateComplexity()
void R3SurfelNode::
UpdateComplexity(void)
{
  // Check if complexity is uptodate
  if (complexity >= 0) return;

  // Sum complexity of blocks
  complexity = 0;
  for (int i = 0; i < NBlocks(); i++) {
    R3SurfelBlock *block = Block(i);
    complexity += block->NSurfels();
  }
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movsd 0x50(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x60b43
jmp 0x60bb3
movq 0x8(%rsp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, 0x50(%rax)
movl $0x0, 0x1c(%rsp)
movq 0x8(%rsp), %rdi
movl 0x1c(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x60bb3
movq 0x8(%rsp), %rdi
movl 0x1c(%rsp), %esi
callq 0x186d0
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
callq 0x1c0e0
movl %eax, %ecx
movq 0x8(%rsp), %rax
cvtsi2sd %ecx, %xmm0
addsd 0x50(%rax), %xmm0
movsd %xmm0, 0x50(%rax)
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x60b58
addq $0x28, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelNode.cpp
// Function: gaps::R3SurfelNode::UpdateResolution()
void R3SurfelNode::
UpdateResolution(void)
{
  // Check if resolution is uptodate
  if (resolution >= 0) return;

  // Initialize resolution
  resolution = 0;

  // Compute minimum of block resolutions
  if (Complexity() > 0) {
    resolution = FLT_MAX;
    assert(NBlocks() > 0);
    for (int i = 0; i < NBlocks(); i++) {
      R3SurfelBlock *block = Block(i);
      RNScalar block_resolution = block->Resolution();
      if (block_resolution < resolution) {
        resolution = block_resolution;
      }
    }
  }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movsd 0x58(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x60be6
jmp 0x60c95
movq 0x10(%rsp), %rdi
xorps %xmm0, %xmm0
movsd %xmm0, 0x58(%rdi)
callq 0x5ecb0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x60c95
movq 0x10(%rsp), %rax
movsd 0x14357e(%rip), %xmm0   # 0x1a4190
movsd %xmm0, 0x58(%rax)
movl $0x0, 0x2c(%rsp)
movq 0x10(%rsp), %rdi
movl 0x2c(%rsp), %eax
movl %eax, 0xc(%rsp)
callq 0x186b0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cmpl %ecx, %eax
jge 0x60c93
movq 0x10(%rsp), %rdi
movl 0x2c(%rsp), %esi
callq 0x186d0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rdi
callq 0x4aa00
movq 0x10(%rsp), %rax
movsd %xmm0, 0x18(%rsp)
movsd 0x18(%rsp), %xmm1
movsd 0x58(%rax), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x60c84
movq 0x10(%rsp), %rax
movsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x58(%rax)
jmp 0x60c86
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x60c1f
jmp 0x60c95
addq $0x38, %rsp
retq
nopw (%rax,%rax)