LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelImage.cpp
// Function: gaps::R3SurfelImage::RollingShutterPoseAtTimestamp(double) const
R3CoordSystem R3SurfelImage::
RollingShutterPoseAtTimestamp(RNScalar t) const
{
  // Check rolling shutter parameters
  if (!HasRollingShutter()) return pose;
  double dt = rolling_shutter_timestamps[1] - rolling_shutter_timestamps[0];
  if (RNIsZero(dt)) return rolling_shutter_poses[0];

  // Get interpolation parameter
  double u = (t - rolling_shutter_timestamps[0]) / dt;
  if (u <= 0) return rolling_shutter_poses[0];
  if (u >= 1) return rolling_shutter_poses[1];
  
  // Return slerped pose
  return R3CoordSystemSlerp(rolling_shutter_poses[0], rolling_shutter_poses[1], u);
}

// Assembly:
pushq %rbx
movq %rsi, %rdx
movq %rdi, %rbx
testb $0x1, 0x1c8(%rsi)
jne 0x38b04
addq $0x30, %rdx
jmp 0x38b76
movsd 0x1b0(%rdx), %xmm2
movsd 0x1b8(%rdx), %xmm1
subsd %xmm2, %xmm1
leaq 0xec109(%rip), %rax     # 0x124c28
movsd (%rax), %xmm3
movapd 0x8f875(%rip), %xmm4    # 0xc83a0
xorpd %xmm3, %xmm4
ucomisd %xmm4, %xmm1
jb 0x38b3b
ucomisd %xmm1, %xmm3
jae 0x38b6f
subsd %xmm2, %xmm0
divsd %xmm1, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
jae 0x38b6f
ucomisd 0x8f5f3(%rip), %xmm0    # 0xc8148
jae 0x38b86
leaq 0xf0(%rdx), %rsi
addq $0x150, %rdx            # imm = 0x150
movq %rbx, %rdi
callq 0x670f5
jmp 0x38b81
addq $0xf0, %rdx
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x66ee8
movq %rbx, %rax
popq %rbx
retq
addq $0x150, %rdx            # imm = 0x150
jmp 0x38b76
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelImage.cpp
// Function: gaps::R3SurfelImage::RollingShutterTimestampAtImagePosition(gaps::R2Point const&) const
RNScalar R3SurfelImage::
RollingShutterTimestampAtImagePosition(const R2Point& image_position) const
{
  // Check rolling shutter parameters
  if (!HasRollingShutter()) return timestamp;
  if (image_width <= 1) return rolling_shutter_timestamps[0];

  // Get interpolation parameter
  double u = (double) image_position.X() / (double) (image_width-1);
  if (u <= 0) return rolling_shutter_timestamps[0];
  if (u >= 1) return rolling_shutter_timestamps[1];

  // Return interpolated timestamp
  return (1-u)*rolling_shutter_timestamps[0] + u*rolling_shutter_timestamps[1];
}

// Assembly:
testb $0x1, 0x1c8(%rdi)
jne 0x38ba2
movsd 0x90(%rdi), %xmm0
retq
movl 0x98(%rdi), %eax
cmpl $0x1, %eax
jle 0x38bf0
movsd (%rsi), %xmm1
decl %eax
cvtsi2sd %eax, %xmm0
divsd %xmm0, %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm1, %xmm0
jae 0x38bf0
ucomisd 0x8f57b(%rip), %xmm1    # 0xc8148
jae 0x38bf9
movsd 0x8f571(%rip), %xmm0    # 0xc8148
subsd %xmm1, %xmm0
mulsd 0x1b8(%rdi), %xmm1
mulsd 0x1b0(%rdi), %xmm0
addsd %xmm1, %xmm0
retq
movsd 0x1b0(%rdi), %xmm0
retq
movsd 0x1b8(%rdi), %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelImage.cpp
// Function: gaps::R3SurfelImage::Print(_IO_FILE*, char const*, char const*) const
void R3SurfelImage::
Print(FILE *fp, const char *prefix, const char *suffix) const
{
  // Check fp
  if (!fp) fp = stdout;

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

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %r14
movq %rsi, %rbx
movq %rdi, %r15
testq %rsi, %rsi
jne 0x38c1f
movq 0xeb364(%rip), %rax     # 0x123f80
movq (%rax), %rbx
testq %rdx, %rdx
je 0x38c2f
movq %rdx, %rdi
movq %rbx, %rsi
callq 0x135d0
movl 0x10(%r15), %edx
movq 0x1c0(%r15), %rax
testq %rax, %rax
leaq 0x8f702(%rip), %rcx     # 0xc8346
cmovneq %rax, %rcx
leaq 0x8f6f1(%rip), %rsi     # 0xc8340
movq %rbx, %rdi
xorl %eax, %eax
callq 0x13780
testq %r14, %r14
je 0x38c69
movq %r14, %rdi
movq %rbx, %rsi
callq 0x135d0
pushq $0xa
popq %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x13690
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelImage.cpp
// Function: gaps::R3SurfelImage::Draw(gaps::RNFlags, double) const
void R3SurfelImage::
Draw(RNFlags flags, RNScalar scale) const
{
#if 1
  // Draw towards and up
  RNGrfxBegin(RN_GRFX_LINES);
  const R3Point& viewpoint = Viewpoint();
  const R3Vector towards = Towards();
  const R3Vector up = Up();
  R3LoadPoint(viewpoint);
  R3LoadPoint(viewpoint + scale * towards);
  R3LoadPoint(viewpoint);
  R3LoadPoint(viewpoint + 0.5 * scale * up);
  RNGrfxEnd();
#else
  // Draw R3Camera approximation
  Camera().Draw(scale);
#endif
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x68, %rsp
movsd %xmm0, (%rsp)
movq %rdi, %r15
pushq $0x1
popq %rdi
callq 0x13130
leaq 0x30(%r15), %rbx
leaq 0x78(%r15), %rsi
leaq 0x50(%rsp), %r12
movq %r12, %rdi
callq 0x792e2
addq $0x60, %r15
leaq 0x38(%rsp), %r14
movq %r14, %rdi
movq %r15, %rsi
callq 0x7898c
movq %rbx, %rdi
callq 0x13150
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movq %r12, %rsi
movsd (%rsp), %xmm0
callq 0x79072
leaq 0x20(%rsp), %r12
movq %r12, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x78483
movq %r12, %rdi
callq 0x13150
movq %rbx, %rdi
callq 0x13150
movsd (%rsp), %xmm0
mulsd 0x8f42d(%rip), %xmm0    # 0xc8138
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x79072
leaq 0x20(%rsp), %r14
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x78483
movq %r14, %rdi
callq 0x13150
callq 0x136d0
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeature.cpp
// Function: gaps::R3SurfelFeature::operator=(gaps::R3SurfelFeature const&)
R3SurfelFeature& R3SurfelFeature::
operator=(const R3SurfelFeature& feature)
{
  // Assign properties
  this->name = (feature.name) ? RNStrdup(feature.name) : NULL;
  this->range = feature.range;
  this->weight = feature.weight;

  // Return this
  return *this;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rsi), %rdi
testq %rdi, %rdi
je 0x39600
callq 0x9cc91
jmp 0x39602
xorl %eax, %eax
movq %rax, 0x18(%rbx)
movups 0x20(%r14), %xmm0
movups %xmm0, 0x20(%rbx)
movsd 0x30(%r14), %xmm0
movsd %xmm0, 0x30(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeature.cpp
// Function: gaps::R3SurfelFeature::Print(_IO_FILE*, char const*, char const*) const
void R3SurfelFeature::
Print(FILE *fp, const char *prefix, const char *suffix) const
{
  // Check fp
  if (!fp) fp = stdout;

  // Print feature name
  if (prefix) fprintf(fp, "%s", prefix);
  fprintf(fp, "%s ", Name());
  if (suffix) fprintf(fp, "%s", suffix);
  fprintf(fp, "\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %r14
movq %rsi, %rbx
movq %rdi, %r15
testq %rsi, %rsi
jne 0x396af
movq 0xea8d4(%rip), %rax     # 0x123f80
movq (%rax), %rbx
testq %rdx, %rdx
je 0x396bf
movq %rdx, %rdi
movq %rbx, %rsi
callq 0x135d0
movq 0x18(%r15), %rdx
leaq 0x8f2a2(%rip), %rsi     # 0xc896c
movq %rbx, %rdi
xorl %eax, %eax
callq 0x13780
testq %r14, %r14
je 0x396e4
movq %r14, %rdi
movq %rbx, %rsi
callq 0x135d0
pushq $0xa
popq %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x13690
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::R3SurfelFeatureVector(int)
R3SurfelFeatureVector::
R3SurfelFeatureVector(int nvalues)
  : values(NULL),
    nvalues(nvalues)
{
  // Allocate values
  if (nvalues > 0) {
    values = new RNScalar [ nvalues ];
    for (int i = 0; i < nvalues; i++) {
      values[i] = RN_UNKNOWN;
    }
  }
}

// Assembly:
leaq 0xe670d(%rip), %rax     # 0x11fe08
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movl %esi, 0x10(%rdi)
testl %esi, %esi
jle 0x39746
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl %esi, %r14d
leaq (,%r14,8), %rdi
callq 0x13030
movq %rax, 0x8(%rbx)
xorl %ecx, %ecx
movabsq $-0x4010000000000000, %rdx # imm = 0xBFF0000000000000
cmpq %rcx, %r14
je 0x3973f
movq %rdx, (%rax,%rcx,8)
incq %rcx
jmp 0x39731
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::R3SurfelFeatureVector(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector::
R3SurfelFeatureVector(const R3SurfelFeatureVector& vector)
  : values(NULL),
    nvalues(vector.nvalues)
{
  // Allocate values
  if (nvalues > 0) {
    values = new RNScalar [ nvalues ];
    for (int i = 0; i < nvalues; i++) {
      values[i] = vector.values[i];
    }
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0xe66b4(%rip), %rax     # 0x11fe08
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movslq 0x10(%rsi), %r15
movl %r15d, 0x10(%rdi)
testq %r15, %r15
jle 0x3979a
movq %rdi, %rbx
movq %rsi, %r14
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x8(%rbx)
movq 0x8(%r14), %rcx
xorl %edx, %edx
cmpq %rdx, %r15
je 0x3979a
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x39786
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator=(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator=(const R3SurfelFeatureVector& vector)
{
  // Reallocate values
  if (nvalues != vector.nvalues) {
    nvalues = vector.nvalues;
    if (values) delete [] values;
    if (nvalues > 0) values = new RNScalar [ nvalues ];
    else values = NULL;
  }

  // Copy values
  for (int i = 0; i < nvalues; i++) {
    values[i] = vector.values[i];
  }

  // Return this
  return *this;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movl 0x10(%rdi), %edx
movl 0x10(%rsi), %ebp
cmpl %ebp, %edx
jne 0x397e8
movq 0x8(%rbx), %rax
jmp 0x3981a
movl %ebp, 0x10(%rbx)
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x397fc
callq 0x136a0
movl 0x10(%rbx), %ebp
testl %ebp, %ebp
jle 0x39811
movl %ebp, %edi
shlq $0x3, %rdi
callq 0x13030
movq %rax, 0x8(%rbx)
jmp 0x39818
andq $0x0, 0x8(%rbx)
xorl %eax, %eax
movl %ebp, %edx
movq 0x8(%r14), %rcx
movslq %edx, %rdx
xorl %esi, %esi
cmpq %rdx, %rsi
jge 0x39837
movsd (%rcx,%rsi,8), %xmm0
movsd %xmm0, (%rax,%rsi,8)
incq %rsi
jmp 0x39823
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator+=(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator+=(const R3SurfelFeatureVector& vector)
{
  // Check number of values
  assert(nvalues == vector.nvalues);

  // Add values
  for (int i = 0; i < nvalues; i++) {
    values[i] += vector.values[i];
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movslq 0x10(%rdi), %rcx
movq 0x8(%rsi), %rdx
movq 0x8(%rdi), %rsi
xorl %edi, %edi
cmpq %rcx, %rdi
jge 0x3986a
movsd (%rdx,%rdi,8), %xmm0
addsd (%rsi,%rdi,8), %xmm0
movsd %xmm0, (%rsi,%rdi,8)
incq %rdi
jmp 0x39851
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator-=(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator-=(const R3SurfelFeatureVector& vector)
{
  // Check number of values
  assert(nvalues == vector.nvalues);

  // Subtract values
  for (int i = 0; i < nvalues; i++) {
    values[i] -= vector.values[i];
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movslq 0x10(%rdi), %rcx
movq 0x8(%rsi), %rdx
movq 0x8(%rdi), %rsi
xorl %edi, %edi
cmpq %rcx, %rdi
jge 0x39896
movsd (%rsi,%rdi,8), %xmm0
subsd (%rdx,%rdi,8), %xmm0
movsd %xmm0, (%rsi,%rdi,8)
incq %rdi
jmp 0x3987d
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator*=(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator*=(const R3SurfelFeatureVector& vector)
{
  // Check number of values
  assert(nvalues == vector.nvalues);

  // Multiply values
  for (int i = 0; i < nvalues; i++) {
    values[i] *= vector.values[i];
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movslq 0x10(%rdi), %rcx
movq 0x8(%rsi), %rdx
movq 0x8(%rdi), %rsi
xorl %edi, %edi
cmpq %rcx, %rdi
jge 0x398c2
movsd (%rdx,%rdi,8), %xmm0
mulsd (%rsi,%rdi,8), %xmm0
movsd %xmm0, (%rsi,%rdi,8)
incq %rdi
jmp 0x398a9
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator/=(gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator/=(const R3SurfelFeatureVector& vector)
{
  // Check number of values
  assert(nvalues == vector.nvalues);

  // Divide values
  for (int i = 0; i < nvalues; i++) {
    if (RNIsNotZero(vector.values[i])) values[i] /= vector.values[i];
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movslq 0x10(%rdi), %rcx
movq 0x8(%rsi), %rdx
movq 0x8(%rdi), %rsi
xorl %edi, %edi
leaq 0xeb34c(%rip), %r8      # 0x124c28
movapd 0x8eabc(%rip), %xmm0    # 0xc83a0
cmpq %rcx, %rdi
jge 0x39916
movsd (%rdx,%rdi,8), %xmm1
movsd (%r8), %xmm2
ucomisd %xmm2, %xmm1
ja 0x39903
xorpd %xmm0, %xmm2
ucomisd %xmm1, %xmm2
jbe 0x39911
movsd (%rsi,%rdi,8), %xmm2
divsd %xmm1, %xmm2
movsd %xmm2, (%rsi,%rdi,8)
incq %rdi
jmp 0x398e4
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator+=(double)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator+=(RNScalar a)
{
  // Add values
  for (int i = 0; i < nvalues; i++) {
    values[i] += a;
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movl 0x10(%rdi), %ecx
movq 0x8(%rdi), %rdx
xorl %esi, %esi
testl %ecx, %ecx
cmovlel %esi, %ecx
cmpq %rsi, %rcx
je 0x39941
movsd (%rdx,%rsi,8), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, (%rdx,%rsi,8)
incq %rsi
jmp 0x39929
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator-=(double)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator-=(RNScalar a)
{
  // Subtract values
  for (int i = 0; i < nvalues; i++) {
    values[i] -= a;
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movslq 0x10(%rdi), %rcx
movq 0x8(%rdi), %rdx
xorl %esi, %esi
cmpq %rcx, %rsi
jge 0x39967
movsd (%rdx,%rsi,8), %xmm1
subsd %xmm0, %xmm1
movsd %xmm1, (%rdx,%rsi,8)
incq %rsi
jmp 0x3994f
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator*=(double)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator*=(RNScalar a)
{
  // Multiply values
  for (int i = 0; i < nvalues; i++) {
    values[i] *= a;
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
movl 0x10(%rdi), %ecx
movq 0x8(%rdi), %rdx
xorl %esi, %esi
testl %ecx, %ecx
cmovlel %esi, %ecx
cmpq %rsi, %rcx
je 0x39991
movsd (%rdx,%rsi,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%rdx,%rsi,8)
incq %rsi
jmp 0x39979
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::operator/=(double)
R3SurfelFeatureVector& R3SurfelFeatureVector::
operator/=(RNScalar a)
{
  // Check a
  if (RNIsZero(a)) return *this;

  // Divide values
  for (int i = 0; i < nvalues; i++) {
    values[i] /= a;
  }

  // Return this
  return *this;
}

// Assembly:
movq %rdi, %rax
leaq 0xeb28c(%rip), %rcx     # 0x124c28
movsd (%rcx), %xmm1
movapd 0x8e9f8(%rip), %xmm2    # 0xc83a0
xorpd %xmm1, %xmm2
ucomisd %xmm2, %xmm0
jb 0x399b9
ucomisd %xmm0, %xmm1
jb 0x399b9
retq
movl 0x10(%rax), %ecx
movq 0x8(%rax), %rdx
xorl %esi, %esi
testl %ecx, %ecx
cmovlel %esi, %ecx
cmpq %rsi, %rcx
je 0x399b8
movsd (%rdx,%rsi,8), %xmm1
divsd %xmm0, %xmm1
movsd %xmm1, (%rdx,%rsi,8)
incq %rsi
jmp 0x399c7
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::operator-(double, gaps::R3SurfelFeatureVector const&)
R3SurfelFeatureVector 
operator-(const RNScalar a, const R3SurfelFeatureVector& vector1)
{
  // Subtract from scalar
  R3SurfelFeatureVector vector;
  vector *= -1.0;
  vector += a;
  return vector;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0xe6308(%rip), %rax     # 0x11fe08
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movsd %xmm0, 0x8(%rsp)
andl $0x0, 0x10(%rdi)
movsd 0x8e646(%rip), %xmm0    # 0xc8160
callq 0x39968
movq %rbx, %rdi
movsd 0x8(%rsp), %xmm0
callq 0x39918
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::Resize(int)
void R3SurfelFeatureVector::
Resize(int size)
{
  // Save old stuff
  RNScalar *old_values = values;
  int old_nvalues = nvalues;

  // Set new stuff
  nvalues = size;
  values = NULL;

  // Copy values
  if (nvalues > 0) {
    values = new RNScalar [ nvalues ];
    int overlap = (nvalues > old_nvalues) ? old_nvalues : nvalues;
    for (int i = 0; i < overlap; i++) values[i] = old_values[i];
    for (int i = overlap; i < nvalues; i++) values[i] = RN_UNKNOWN;
  }

  // Delete old values
  if (old_values) delete [] old_values;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x8(%rdi), %rbx
movslq 0x10(%rdi), %r12
movl %esi, 0x10(%rdi)
andq $0x0, 0x8(%rdi)
testl %esi, %esi
jle 0x39c3d
movl %esi, %r14d
movq %rdi, %r15
movl %esi, %r13d
leaq (,%r13,8), %rdi
callq 0x13030
movq %rax, 0x8(%r15)
cmpl %r14d, %r12d
movl %r14d, %ecx
cmovll %r12d, %ecx
xorl %edx, %edx
testl %ecx, %ecx
movl $0x0, %esi
cmovgl %ecx, %esi
cmpq %rdx, %rsi
je 0x39c15
movsd (%rbx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x39c01
cmpq %r13, %r12
cmovlq %r12, %r13
subl %ecx, %r14d
leaq (%rax,%r13,8), %rax
xorl %ecx, %ecx
movabsq $-0x4010000000000000, %rdx # imm = 0xBFF0000000000000
cmpl %ecx, %r14d
je 0x39c3d
movq %rdx, (%rax,%rcx,8)
incq %rcx
jmp 0x39c2f
testq %rbx, %rbx
je 0x39c53
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x136a0
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::EuclideanDistanceSquared(gaps::R3SurfelFeatureVector const&) const
RNLength R3SurfelFeatureVector::
EuclideanDistanceSquared(const R3SurfelFeatureVector& vector) const
{
  // Compute sum of squared differences
  RNLength sum = 0;
  assert(NValues() == vector.NValues());
  for (int i = 0; i < NValues(); i++) {
    RNScalar delta = Value(i) - vector.Value(i);
    sum += delta * delta;
  }

  // Return squared Euclidean distance
  return sum;
}

// Assembly:
movl 0x10(%rdi), %eax
movq 0x8(%rdi), %rcx
movq 0x8(%rsi), %rdx
xorl %esi, %esi
testl %eax, %eax
cmovlel %esi, %eax
xorpd %xmm0, %xmm0
cmpq %rsi, %rax
je 0x39cb8
movsd (%rcx,%rsi,8), %xmm1
subsd (%rdx,%rsi,8), %xmm1
mulsd %xmm1, %xmm1
addsd %xmm1, %xmm0
incq %rsi
jmp 0x39c9c
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::Correlation(gaps::R3SurfelFeatureVector const&) const
RNScalar R3SurfelFeatureVector::
Correlation(const R3SurfelFeatureVector& vector) const
{
  // Compute sum of products (dot product)
  RNLength sum = 0;
  assert(NValues() == vector.NValues());
  for (int i = 0; i < NValues(); i++) {
    sum += Value(i) * vector.Value(i);
  }

  // Return correlation
  return sum;
}

// Assembly:
movl 0x10(%rdi), %eax
movq 0x8(%rdi), %rcx
movq 0x8(%rsi), %rdx
xorl %esi, %esi
testl %eax, %eax
cmovlel %esi, %eax
xorpd %xmm0, %xmm0
cmpq %rsi, %rax
je 0x39ce8
movsd (%rcx,%rsi,8), %xmm1
mulsd (%rdx,%rsi,8), %xmm1
addsd %xmm1, %xmm0
incq %rsi
jmp 0x39cd0
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelFeatureVector.cpp
// Function: gaps::R3SurfelFeatureVector::Print(_IO_FILE*, char const*, char const*) const
void R3SurfelFeatureVector::
Print(FILE *fp, const char *prefix, const char *suffix) const
{
  // Check fp
  if (!fp) fp = stdout;

  // Print feature values
  if (prefix) fprintf(fp, "%s", prefix);
  for (int i = 0; i < NValues(); i++) {
    fprintf(fp, "%g ", Value(i));
  }
  if (suffix) fprintf(fp, "%s", suffix);
  fprintf(fp, "\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rsi, %rbx
movq %rdi, %r15
testq %rsi, %rsi
jne 0x39d0b
movq 0xea278(%rip), %rax     # 0x123f80
movq (%rax), %rbx
testq %rdx, %rdx
je 0x39d1b
movq %rdx, %rdi
movq %rbx, %rsi
callq 0x135d0
xorl %r13d, %r13d
leaq 0x8eb89(%rip), %r12     # 0xc88ae
movslq 0x10(%r15), %rax
cmpq %rax, %r13
jge 0x39d4a
movq 0x8(%r15), %rax
movsd (%rax,%r13,8), %xmm0
movq %rbx, %rdi
movq %r12, %rsi
movb $0x1, %al
callq 0x13780
incq %r13
jmp 0x39d25
testq %r14, %r14
je 0x39d5a
movq %r14, %rdi
movq %rbx, %rsi
callq 0x135d0
pushq $0xa
popq %rdi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x13690
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::BBox() const
const R3Box& R3SurfelObjectSet::
BBox(void) const
{
  // Update bounding box
  if (bbox[0][0] == FLT_MAX) {
    R3SurfelObjectSet *objectset = (R3SurfelObjectSet *) this;
    objectset->bbox = R3null_box;
    for (int i = 0; i < NObjects(); i++) {
      R3SurfelObject *object = Object(i);
      objectset->bbox.Union(object->BBox());
    }
  }

  // Return bounding box
  return bbox;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x18(%rdi), %rbx
movsd 0x20(%rdi), %xmm0
ucomisd 0x8e2a8(%rip), %xmm0    # 0xc8168
jne 0x39eff
jp 0x39eff
movq %rdi, %r14
leaq 0xebb1a(%rip), %rsi     # 0x1259e8
movq %rbx, %rdi
callq 0x177ee
xorl %r15d, %r15d
movslq 0x14(%r14), %rax
cmpq %rax, %r15
jge 0x39eff
movq 0x8(%r14), %rax
movq (%rax,%r15,8), %rdi
callq 0x16860
movq %rbx, %rdi
movq %rax, %rsi
callq 0x646fe
incq %r15
jmp 0x39ed9
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::TimestampRange() const
const RNInterval& R3SurfelObjectSet::
TimestampRange(void) const
{
  // Update timestamp range
  if (timestamp_range.Min() == FLT_MAX) {
    R3SurfelObjectSet *objectset = (R3SurfelObjectSet *) this;
    objectset->timestamp_range.Reset(FLT_MAX,-FLT_MAX);
    for (int i = 0; i < NObjects(); i++) {
      R3SurfelObject *object = Object(i);
      objectset->timestamp_range.Union(object->TimestampRange());
    }
  }

  // Return timestamp range
  return timestamp_range;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x50(%rdi), %rbx
movsd 0x50(%rdi), %xmm0
ucomisd 0x8e24a(%rip), %xmm0    # 0xc8168
jne 0x39f5b
jp 0x39f5b
movq %rdi, %r14
movapd 0x8e403(%rip), %xmm0    # 0xc8330
movupd %xmm0, 0x50(%rdi)
xorl %r15d, %r15d
movslq 0x14(%r14), %rax
cmpq %rax, %r15
jge 0x39f5b
movq 0x8(%r14), %rax
movq (%rax,%r15,8), %rdi
callq 0x16996
movq %rbx, %rdi
movq %rax, %rsi
callq 0x177ca
incq %r15
jmp 0x39f35
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::RemoveObject(int)
void R3SurfelObjectSet::
RemoveObject(int k)
{
  // Copy last object over object
  RNArrayEntry *entry = objects.KthEntry(k);
  assert(entry);
  R3SurfelObject *tail = objects.Tail();
  objects.EntryContents(entry) = tail;
  objects.RemoveTail();

  // Update bounding box
  bbox[0][0] = FLT_MAX;

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

// Assembly:
pushq %rbx
movq %rdi, %rbx
addq $0x8, %rdi
movq 0x8(%rbx), %rax
movslq %esi, %rcx
movslq 0x14(%rbx), %rdx
movq -0x8(%rax,%rdx,8), %rdx
movq %rdx, (%rax,%rcx,8)
callq 0x17820
movabsq $0x47efffffe0000000, %rax # imm = 0x47EFFFFFE0000000
movq %rax, 0x20(%rbx)
movaps 0x8e342(%rip), %xmm0    # 0xc8330
movups %xmm0, 0x50(%rbx)
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::Empty()
void R3SurfelObjectSet::
Empty(void)
{
  // Remove objects
  objects.Empty();

  // Update bounding box
  bbox = R3Box(FLT_MAX, FLT_MAX, FLT_MAX, -FLT_MAX, -FLT_MAX, -FLT_MAX);

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

// Assembly:
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
addq $0x8, %rdi
xorl %esi, %esi
callq 0x9a9cc
movq %rsp, %r14
movsd 0x8e154(%rip), %xmm0    # 0xc8168
movsd 0x8e154(%rip), %xmm3    # 0xc8170
movq %r14, %rdi
movaps %xmm0, %xmm1
movaps %xmm0, %xmm2
movaps %xmm3, %xmm4
movaps %xmm3, %xmm5
callq 0x63d86
leaq 0x18(%rbx), %rdi
movq %r14, %rsi
callq 0x177ee
movq %rsp, %rdi
callq 0x649ae
movaps 0x8e2e5(%rip), %xmm0    # 0xc8330
movups %xmm0, 0x50(%rbx)
addq $0x38, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x649ae
movq %rbx, %rdi
callq 0x138f0
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::Draw(gaps::RNFlags) const
void R3SurfelObjectSet::
Draw(RNFlags flags) const
{
  // Draw objects
  for (int i = 0; i < NObjects(); i++) {
    R3SurfelObject *object = Object(i);
    object->Draw(flags);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
xorl %r15d, %r15d
movslq 0x14(%r14), %rax
cmpq %rax, %r15
jge 0x3a097
movq 0x8(%r14), %rax
movq (%rax,%r15,8), %rdi
movq (%rdi), %rax
movq %rbx, %rsi
callq *0x48(%rax)
incq %r15
jmp 0x3a078
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectSet.cpp
// Function: gaps::R3SurfelObjectSet::Print(_IO_FILE*, char const*, char const*) const
void R3SurfelObjectSet::
Print(FILE *fp, const char *prefix, const char *suffix) const
{
  // Check fp
  if (!fp) fp = stdout;

  // Print objects
  // Print all surfel objects
  if (prefix) fprintf(fp, "%s", prefix);
  for (int i = 0; i < NObjects(); i++) {
    R3SurfelObject *object = Object(i);
    fprintf(fp, "%d ", object->SceneIndex());
  }
  if (suffix) fprintf(fp, "%s", suffix);
  fprintf(fp, "\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rsi, %rbx
movq %rdi, %r15
testq %rsi, %rsi
jne 0x3a0bf
movq 0xe9ec4(%rip), %rax     # 0x123f80
movq (%rax), %rbx
testq %rdx, %rdx
je 0x3a0cf
movq %rdx, %rdi
movq %rbx, %rsi
callq 0x135d0
leaq 0x8e7cd(%rip), %r12     # 0xc88a3
xorl %r13d, %r13d
movslq 0x14(%r15), %rax
cmpq %rax, %r13
jge 0x3a0ff
movq 0x8(%r15), %rax
movq (%rax,%r13,8), %rax
movl 0x10(%rax), %edx
movq %rbx, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0x13780
incq %r13
jmp 0x3a0d9
testq %r14, %r14
je 0x3a10f
movq %r14, %rdi
movq %rbx, %rsi
callq 0x135d0
pushq $0xa
popq %rdi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x13690
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectProperty.cpp
// Function: gaps::R3SurfelObjectProperty::R3SurfelObjectProperty(int, gaps::R3SurfelObject*, double*, int)
R3SurfelObjectProperty::
R3SurfelObjectProperty(int type, R3SurfelObject *object, RNScalar *operands, int noperands)
  : scene(NULL),
    scene_index(-1),
    object(object),
    operands(NULL),
    noperands(0),
    type(type)
{
  // Check if operands were provided
  if ((noperands > 0) && (operands)) {
    // Copy operands
    this->noperands = noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = operands[i];
    }
  }
  else {
    // Compute operands
    UpdateOperands();
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
leaq 0xe5d85(%rip), %rax     # 0x11feb8
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
orl $-0x1, 0x10(%rdi)
movq %rdx, 0x18(%rdi)
andq $0x0, 0x20(%rdi)
andl $0x0, 0x28(%rdi)
movq %rcx, %rbx
movl %esi, 0x2c(%rdi)
testl %r8d, %r8d
setle %al
testq %rcx, %rcx
sete %cl
orb %al, %cl
jne 0x3a190
movl %r8d, 0x28(%r14)
movl %r8d, %r15d
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x20(%r14)
xorl %ecx, %ecx
cmpq %rcx, %r15
je 0x3a19d
movsd (%rbx,%rcx,8), %xmm0
movsd %xmm0, (%rax,%rcx,8)
incq %rcx
jmp 0x3a17c
movq %r14, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x3a1a4
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectProperty.cpp
// Function: gaps::R3SurfelObjectProperty::R3SurfelObjectProperty(gaps::R3SurfelObjectProperty const&)
R3SurfelObjectProperty::
R3SurfelObjectProperty(const R3SurfelObjectProperty& property)
  : scene(NULL),
    scene_index(-1),
    object(property.object),
    operands(NULL),
    noperands(0),
    type(property.type)
{
  // Initialize operands
  if ((property.noperands > 0) && (property.operands)) {
    this->noperands = property.noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = property.operands[i];
    }
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0xe58a0(%rip), %rax     # 0x11feb8
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
orl $-0x1, 0x10(%rdi)
movq 0x18(%rsi), %rax
movq %rax, 0x18(%rdi)
andq $0x0, 0x20(%rdi)
andl $0x0, 0x28(%rdi)
movl 0x2c(%rsi), %eax
movl %eax, 0x2c(%rdi)
movslq 0x28(%rsi), %r15
testq %r15, %r15
jle 0x3a680
movq %rsi, %rbx
cmpq $0x0, 0x20(%rsi)
je 0x3a680
movq %rdi, %r14
movl %r15d, 0x28(%rdi)
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x20(%r14)
movq 0x20(%rbx), %rcx
xorl %edx, %edx
cmpq %rdx, %r15
je 0x3a680
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x3a66c
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectProperty.cpp
// Function: gaps::R3SurfelObjectProperty::operator=(gaps::R3SurfelObjectProperty const&)
R3SurfelObjectProperty& R3SurfelObjectProperty::
operator=(const R3SurfelObjectProperty& property)
{
  // Assign stuff
  this->object = property.object;
  this->type = property.type;
  
  // Delete previous operands
  if (this->operands) {
    delete [] this->operands;
    this->operands = NULL;
    this->noperands = 0;
  }

  // Copy operands
  if ((property.noperands > 0) && (property.operands)) {
    this->noperands = property.noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = property.operands[i];
    }
  }

  // Return this
  return *this;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rsi), %rax
movq %rax, 0x18(%rdi)
movl 0x2c(%rsi), %eax
movl %eax, 0x2c(%rdi)
movq 0x20(%rdi), %rdi
testq %rdi, %rdi
je 0x3a706
callq 0x136a0
andq $0x0, 0x20(%rbx)
andl $0x0, 0x28(%rbx)
movslq 0x28(%r14), %r15
testq %r15, %r15
jle 0x3a745
cmpq $0x0, 0x20(%r14)
je 0x3a745
movl %r15d, 0x28(%rbx)
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x20(%rbx)
movq 0x20(%r14), %rcx
xorl %edx, %edx
cmpq %rdx, %r15
je 0x3a745
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x3a731
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectProperty.cpp
// Function: gaps::R3SurfelObjectProperty::ResetOperands(double*, int)
void R3SurfelObjectProperty::
ResetOperands(RNScalar *operands, int noperands)
{
  // Delete previous operands
  if (this->operands) delete [] this->operands;
  this->operands = NULL;
  this->noperands = 0;
  
  // Check if operands were provided
  if ((noperands > 0) && (operands)) {
    // Copy operands
    this->noperands = noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = operands[i];
    }
    
    // Mark scene as dirty
    if (scene) scene->SetDirty();
  }
  else {
    // Compute operands
    UpdateOperands();
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movq 0x20(%rdi), %rdi
testq %rdi, %rdi
je 0x3a76b
callq 0x136a0
andq $0x0, 0x20(%rbx)
andl $0x0, 0x28(%rbx)
testl %ebp, %ebp
setle %al
testq %r14, %r14
sete %cl
orb %al, %cl
jne 0x3a7b1
movl %ebp, 0x28(%rbx)
movl %ebp, %r15d
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x20(%rbx)
xorl %ecx, %ecx
cmpq %rcx, %r15
je 0x3a7c3
movsd (%r14,%rcx,8), %xmm0
movsd %xmm0, (%rax,%rcx,8)
incq %rcx
jmp 0x3a79c
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x3a1a4
movq 0x8(%rbx), %rax
testq %rax, %rax
je 0x3a7d3
orb $0x1, 0x1e8(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectRelationship.cpp
// Function: gaps::R3SurfelObjectRelationship::R3SurfelObjectRelationship(int, gaps::RNArray<gaps::R3SurfelObject*> const&, double*, int)
R3SurfelObjectRelationship::
R3SurfelObjectRelationship(int type, const RNArray<R3SurfelObject *>& objects, RNScalar *operands, int noperands)
  : scene(NULL),
    scene_index(-1),
    objects(objects),
    operands(NULL),
    noperands(0),
    type(type)
{
  // Check if operands were provided
  if ((noperands > 0) && (operands)) {
    // Copy operands
    this->noperands = noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = operands[i];
    }
  }
  else {
    // Compute operands
    UpdateOperands();
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r8d, %ebp
movq %rcx, %rbx
movl %esi, %r12d
movq %rdi, %r14
leaq 0xe4f85(%rip), %rax     # 0x11fef0
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
orl $-0x1, 0x10(%rdi)
leaq 0x18(%rdi), %r15
movq %r15, %rdi
movq %rdx, %rsi
callq 0x9a7b6
andq $0x0, 0x28(%r14)
andl $0x0, 0x30(%r14)
movl %r12d, 0x34(%r14)
testl %ebp, %ebp
setle %al
testq %rbx, %rbx
sete %cl
orb %al, %cl
jne 0x3afd1
movl %ebp, 0x30(%r14)
movl %ebp, %r12d
leaq (,%r12,8), %rdi
callq 0x13030
movq %rax, 0x28(%r14)
xorl %ecx, %ecx
cmpq %rcx, %r12
je 0x3afd1
movsd (%rbx,%rcx,8), %xmm0
movsd %xmm0, (%rax,%rcx,8)
incq %rcx
jmp 0x3afbd
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %r15, %rdi
callq 0x9a81c
movq %rbx, %rdi
callq 0x138f0
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectRelationship.cpp
// Function: gaps::R3SurfelObjectRelationship::R3SurfelObjectRelationship(int, gaps::R3SurfelObject*, gaps::R3SurfelObject*, double*, int)
R3SurfelObjectRelationship::
R3SurfelObjectRelationship(int type, R3SurfelObject *object0, R3SurfelObject *object1, RNScalar *operands, int noperands)
  : scene(NULL),
    scene_index(-1),
    objects(),
    operands(NULL),
    noperands(0),
    type(type)
{
  // Insert objects
  objects.Insert(object0);
  objects.Insert(object1);

  // Check if operands were provided
  if ((noperands > 0) && (operands)) {
    // Copy operands
    this->noperands = noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = operands[i];
    }
  }
  else {
    // Compute operands
    UpdateOperands();
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %ebp
movq %r8, %rbx
movq %rcx, (%rsp)
movq %rdx, %r13
movl %esi, %r12d
movq %rdi, %r14
leaq 0xe4edb(%rip), %rax     # 0x11fef0
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
orl $-0x1, 0x10(%rdi)
leaq 0x18(%rdi), %r15
movq %r15, %rdi
callq 0x9a7ae
andq $0x0, 0x28(%r14)
andl $0x0, 0x30(%r14)
movl %r12d, 0x34(%r14)
movq %r15, %rdi
movq %r13, %rsi
callq 0x1784c
movq %r15, %rdi
movq (%rsp), %rsi
callq 0x1784c
testl %ebp, %ebp
setle %al
testq %rbx, %rbx
sete %cl
orb %al, %cl
jne 0x3b08f
movl %ebp, 0x30(%r14)
movl %ebp, %r12d
leaq (,%r12,8), %rdi
callq 0x13030
movq %rax, 0x28(%r14)
xorl %ecx, %ecx
cmpq %rcx, %r12
je 0x3b08f
movsd (%rbx,%rcx,8), %xmm0
movsd %xmm0, (%rax,%rcx,8)
incq %rcx
jmp 0x3b07b
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %r15, %rdi
callq 0x9a81c
movq %rbx, %rdi
callq 0x138f0
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectRelationship.cpp
// Function: gaps::R3SurfelObjectRelationship::R3SurfelObjectRelationship(gaps::R3SurfelObjectRelationship const&)
R3SurfelObjectRelationship::
R3SurfelObjectRelationship(const R3SurfelObjectRelationship& relationship)
  : scene(NULL),
    scene_index(-1),
    objects(relationship.objects),
    operands(NULL),
    noperands(0),
    type(relationship.type)
{
  // Copy operands
  if ((relationship.noperands > 0) && (relationship.operands)) {
    this->noperands = relationship.noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = relationship.operands[i];
    }
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0xe4e2c(%rip), %rax     # 0x11fef0
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
orl $-0x1, 0x10(%rdi)
movq %rsi, %r15
leaq 0x18(%rdi), %r14
addq $0x18, %rsi
movq %r14, %rdi
callq 0x9a7b6
andq $0x0, 0x28(%rbx)
andl $0x0, 0x30(%rbx)
movl 0x34(%r15), %eax
movl %eax, 0x34(%rbx)
movslq 0x30(%r15), %r12
testq %r12, %r12
jle 0x3b132
cmpq $0x0, 0x28(%r15)
je 0x3b132
movl %r12d, 0x30(%rbx)
leaq (,%r12,8), %rdi
callq 0x13030
movq %rax, 0x28(%rbx)
movq 0x28(%r15), %rcx
xorl %edx, %edx
cmpq %rdx, %r12
je 0x3b132
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x3b11e
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
movq %r14, %rdi
callq 0x9a81c
movq %rbx, %rdi
callq 0x138f0
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectRelationship.cpp
// Function: gaps::R3SurfelObjectRelationship::operator=(gaps::R3SurfelObjectRelationship const&)
R3SurfelObjectRelationship& R3SurfelObjectRelationship::
operator=(const R3SurfelObjectRelationship& relationship)
{
  // Copy stuff
  this->objects = relationship.objects;
  this->type = relationship.type;

  // Delete previous operands
  if (this->operands) {
    delete [] this->operands;
    this->operands = NULL;
    this->noperands =0;
  }
  
  // Copy operands
  if ((relationship.noperands > 0) && (relationship.operands)) {
    this->noperands = relationship.noperands;
    this->operands = new RNScalar [ this->noperands ];
    for (int i = 0; i < this->noperands; i++) {
      this->operands[i] = relationship.operands[i];
    }
  }

  // Return this
  return *this;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
addq $0x18, %rsi
addq $0x18, %rdi
callq 0x9a7c2
movl 0x34(%r14), %eax
movl %eax, 0x34(%rbx)
movq 0x28(%rbx), %rdi
testq %rdi, %rdi
je 0x3b1e2
callq 0x136a0
andq $0x0, 0x28(%rbx)
andl $0x0, 0x30(%rbx)
movslq 0x30(%r14), %r15
testq %r15, %r15
jle 0x3b221
cmpq $0x0, 0x28(%r14)
je 0x3b221
movl %r15d, 0x30(%rbx)
leaq (,%r15,8), %rdi
callq 0x13030
movq %rax, 0x28(%rbx)
movq 0x28(%r14), %rcx
xorl %edx, %edx
cmpq %rdx, %r15
je 0x3b221
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
jmp 0x3b20d
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelObjectRelationship.cpp
// Function: gaps::R3SurfelObjectRelationship::Draw(gaps::RNFlags) const
void R3SurfelObjectRelationship::
Draw(RNFlags flags) const
{
  // Draw property based on type
  switch (type) {
  case R3_SURFEL_OBJECT_OVERLAP_RELATIONSHIP: 
    // Draw line between objects
    if (objects.NEntries() == 2) {
      if (flags[R3_SURFEL_COLOR_DRAW_FLAG]) RNLoadRgb(0, 1, 0);
      RNGrfxBegin(RN_GRFX_LINES);
      R3LoadPoint(objects[0]->Centroid());
      R3LoadPoint(objects[1]->Centroid());
      RNGrfxEnd();
      break;
    }
  }
}

// Assembly:
cmpl $0x2, 0x34(%rdi)
jne 0x3b2a2
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
cmpl $0x2, 0x24(%rdi)
jne 0x3b29b
testb $0x1, %sil
je 0x3b259
movss 0x8e586(%rip), %xmm1    # 0xc97d4
xorps %xmm0, %xmm0
xorps %xmm2, %xmm2
callq 0x13a20
pushq $0x1
popq %rdi
callq 0x13130
movq 0x18(%rbx), %rax
movq (%rax), %rsi
movq %rsp, %r14
movq %r14, %rdi
callq 0x16342
movq %r14, %rdi
callq 0x13150
movq 0x18(%rbx), %rax
movq 0x8(%rax), %rsi
movq %rsp, %rbx
movq %rbx, %rdi
callq 0x16342
movq %rbx, %rdi
callq 0x13150
callq 0x136d0
addq $0x18, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::~R3SurfelLabel()
R3SurfelLabel::
~R3SurfelLabel(void)
{
  // Delete label properties
  while (NLabelProperties() > 0) {
    R3SurfelLabelProperty *property = LabelProperty(NLabelProperties()-1);
    delete property;
  }

  // Delete label relationships
  while (NLabelRelationships() > 0) {
    R3SurfelLabelRelationship *relationship = LabelRelationship(NLabelRelationships()-1);
    delete relationship;
  }

  // Delete label assignments
  while (NLabelAssignments() > 0) {
    R3SurfelLabelAssignment *assignment = LabelAssignment(NLabelAssignments()-1);
    delete assignment;
  }

  // Delete parts
  while (NParts() > 0) {
    R3SurfelLabel *part = Part(NParts()-1);
    delete part;
  }

  // Remove from parent
  SetParent(NULL);

  // Remove label from scene (handles all removals)
  if (scene) scene->RemoveLabel(this);

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

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %r14
leaq 0xe4aab(%rip), %rax     # 0x11ff28
movq %rax, (%rdi)
leaq 0x30(%rdi), %rbx
movslq 0x3c(%r14), %rax
testq %rax, %rax
jle 0x3b4a2
movq (%rbx), %rcx
movq -0x8(%rcx,%rax,8), %rdi
testq %rdi, %rdi
je 0x3b484
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x3b484
leaq 0x40(%r14), %r15
movslq 0x4c(%r14), %rax
testq %rax, %rax
jle 0x3b4c4
movq (%r15), %rcx
movq -0x8(%rcx,%rax,8), %rdi
testq %rdi, %rdi
je 0x3b4a6
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x3b4a6
leaq 0x50(%r14), %r12
movslq 0x5c(%r14), %rax
testq %rax, %rax
jle 0x3b4e7
movq (%r12), %rcx
movq -0x8(%rcx,%rax,8), %rdi
testq %rdi, %rdi
je 0x3b4c8
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x3b4c8
leaq 0x20(%r14), %r13
movslq 0x2c(%r14), %rax
testq %rax, %rax
jle 0x3b50a
movq (%r13), %rcx
movq -0x8(%rcx,%rax,8), %rdi
testq %rdi, %rdi
je 0x3b4eb
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x3b4eb
movq (%r14), %rax
movq %r14, %rdi
xorl %esi, %esi
callq *0x10(%rax)
movq 0x8(%r14), %rdi
testq %rdi, %rdi
je 0x3b527
movq (%rdi), %rax
movq %r14, %rsi
callq *0x38(%rax)
movq 0x60(%r14), %rdi
callq 0x13600
movq %r12, %rdi
callq 0x9a81c
movq %r15, %rdi
callq 0x9a81c
movq %rbx, %rdi
callq 0x9a81c
movq %r13, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x9a81c
movq %rax, %rdi
callq 0x177bf
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::FindLabelProperty(int) const
R3SurfelLabelProperty *R3SurfelLabel::
FindLabelProperty(int type) const
{
  // Search for property of type
  for (int i = 0; i < NLabelProperties(); i++) {
    R3SurfelLabelProperty *property = LabelProperty(i);
    if (property->Type() == type) return property;
  }

  // Property not found
  return NULL;
}

// Assembly:
movl 0x3c(%rdi), %ecx
movq 0x30(%rdi), %rdx
xorl %edi, %edi
testl %ecx, %ecx
cmovlel %edi, %ecx
cmpq %rdi, %rcx
je 0x3b59a
movq (%rdx,%rdi,8), %rax
incq %rdi
cmpl %esi, 0x2c(%rax)
jne 0x3b588
retq
xorl %eax, %eax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::Identifier() const
int R3SurfelLabel::
Identifier(void) const
{
  // Update ID 
  if (identifier < 0) {
    ((R3SurfelLabel *) this)->identifier = R3surfel_next_label_identifier++;
  }

  // Return identifier 
  return identifier;
}

// Assembly:
movl 0x68(%rdi), %eax
testl %eax, %eax
js 0x3b5a6
retq
movl 0xe9714(%rip), %eax     # 0x124cc0
leal 0x1(%rax), %ecx
movl %ecx, 0xe970b(%rip)     # 0x124cc0
movl %eax, 0x68(%rdi)
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::InsertIntoPointSet(gaps::R3SurfelPointSet*, int) const
void R3SurfelLabel::
InsertIntoPointSet(R3SurfelPointSet *pointset, RNBoolean leaf_level) const
{
  // Check scene
  if (!Scene()) return;

  // Insert points
  if (leaf_level && (NParts() > 0)) {
    // Insert points from leaf level of all parts of label
    for (int i = 0; i < NParts(); i++) {
      R3SurfelLabel *part = Part(i);
      part->InsertIntoPointSet(pointset, leaf_level);     
    }
  }
  else {
    // Insert points from all objects
    for (int i = 0; i < NLabelAssignments(); i++) {
      R3SurfelLabelAssignment *assignment = LabelAssignment(i);
      R3SurfelObject *object = assignment->Object();
      if (!object) continue;
      if (object->Parent() != scene->RootObject()) continue;
      object->InsertIntoPointSet(pointset, leaf_level);
    }
  }
}

// Assembly:
cmpq $0x0, 0x8(%rdi)
je 0x3b6a9
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
testl %edx, %edx
je 0x3b65e
movl 0x2c(%r15), %eax
testl %eax, %eax
jle 0x3b65e
xorl %r12d, %r12d
cltq
cmpq %rax, %r12
jge 0x3b69e
movq 0x20(%r15), %rax
movq (%rax,%r12,8), %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0x3b612
incq %r12
movl 0x2c(%r15), %eax
jmp 0x3b63c
xorl %r12d, %r12d
movslq 0x5c(%r15), %rax
cmpq %rax, %r12
jge 0x3b69e
movq 0x50(%r15), %rax
movq (%rax,%r12,8), %rax
movq 0x18(%rax), %rdi
testq %rdi, %rdi
je 0x3b699
movq 0x18(%rdi), %rax
movq 0x8(%r15), %rcx
movq 0x10(%rcx), %rcx
cmpq (%rcx), %rax
jne 0x3b699
xorps %xmm0, %xmm0
movq %r14, %rsi
movl %ebx, %edx
callq 0x16bf8
incq %r12
jmp 0x3b661
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::operator=(gaps::R3SurfelLabel const&)
R3SurfelLabel& R3SurfelLabel::
operator=(const R3SurfelLabel& label)
{
  // Copy properties
  this->name = (label.name) ? RNStrdup(label.name) : NULL;
  this->identifier = label.identifier;
  this->assignment_keystroke = label.assignment_keystroke;
  this->color = label.color;
  this->flags = label.flags;

  // Return this
  return *this;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq 0x60(%rsi), %rdi
testq %rdi, %rdi
je 0x3b6c4
callq 0x9cc91
jmp 0x3b6c6
xorl %eax, %eax
movq %rax, 0x60(%rbx)
movq 0x68(%r14), %rax
movq %rax, 0x68(%rbx)
leaq 0x70(%r14), %rsi
leaq 0x70(%rbx), %rdi
callq 0x9a6b6
movq 0x88(%r14), %rax
movq %rax, 0x88(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/tomfunkhouser[P]gaps/pkgs/R3Surfels/R3SurfelLabel.cpp
// Function: gaps::R3SurfelLabel::SetParent(gaps::R3SurfelLabel*)
void R3SurfelLabel::
SetParent(R3SurfelLabel *parent)
{
  // Just checking
  // assert(parent);
  // assert(this->parent);
  assert(!this->parent || (scene == this->parent->scene));
  assert(!parent || !this->parent || (parent->scene == this->parent->scene));
  if (parent == this->parent) return;

  // Update hierarchy
  if (this->parent) this->parent->parts.Remove(this);
  if (parent) parent->parts.Insert(this);
  this->parent = parent;

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

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
cmpq %rsi, %rdi
je 0x3b741
movq %rsi, %r14
testq %rdi, %rdi
je 0x3b71c
addq $0x20, %rdi
movq %rbx, %rsi
callq 0x1782a
testq %r14, %r14
je 0x3b72d
leaq 0x20(%r14), %rdi
movq %rbx, %rsi
callq 0x1784c
movq %r14, 0x18(%rbx)
movq 0x8(%rbx), %rax
testq %rax, %rax
je 0x3b741
orb $0x1, 0x1e8(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop