// File: mindbeast[P]rnes/bin/save.pb.cc
// Function: Rnes::SaveState::ByteSizeLong() const
size_t SaveState::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:Rnes.SaveState)
  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  if (cached_has_bits & 0x000000ffu) {
    // optional string saveDate = 1;
    if (cached_has_bits & 0x00000001u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
          this->_internal_savedate());
    }

    // optional .Rnes.DmaState dma = 7;
    if (cached_has_bits & 0x00000002u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *dma_);
    }

    // optional .Rnes.CpuState cpu = 8;
    if (cached_has_bits & 0x00000004u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *cpu_);
    }

    // optional .Rnes.ApuState apu = 9;
    if (cached_has_bits & 0x00000008u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *apu_);
    }

    // optional .Rnes.PpuState ppu = 10;
    if (cached_has_bits & 0x00000010u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *ppu_);
    }

    // optional .Rnes.ControllerState controller = 11;
    if (cached_has_bits & 0x00000020u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *controller_);
    }

    // optional .Rnes.CpuMemoryState cpuMem = 12;
    if (cached_has_bits & 0x00000040u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *cpumem_);
    }

    // optional .Rnes.VideoMemoryState vidMem = 13;
    if (cached_has_bits & 0x00000080u) {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *vidmem_);
    }

  }
  // optional uint64 gameTime = 2;
  if (cached_has_bits & 0x00000100u) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::UInt64Size(
        this->_internal_gametime());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize(
        _internal_metadata_, total_size, &_cached_size_);
  }
  int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x48(%rbp)
movq $0x0, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
addq $0x10, %rax
movq %rax, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
andl $0xff, %eax
cmpl $0x0, %eax
je 0x5d399
movl -0x3c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x5d299
movq -0x48(%rbp), %rdi
callq 0x63970
movq %rax, %rdi
callq 0x64cd0
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x5d2bd
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x64d00
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x4, %eax
cmpl $0x0, %eax
je 0x5d2e1
movq -0x48(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x64d30
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x8, %eax
cmpl $0x0, %eax
je 0x5d305
movq -0x48(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x64d60
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x10, %eax
cmpl $0x0, %eax
je 0x5d329
movq -0x48(%rbp), %rax
movq 0x38(%rax), %rdi
callq 0x64d90
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x5d34d
movq -0x48(%rbp), %rax
movq 0x40(%rax), %rdi
callq 0x64dc0
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x40, %eax
cmpl $0x0, %eax
je 0x5d371
movq -0x48(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x64df0
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x3c(%rbp), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0x5d397
movq -0x48(%rbp), %rax
movq 0x50(%rax), %rdi
callq 0x64e20
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x5d399
movl -0x3c(%rbp), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
je 0x5d3c3
movq -0x48(%rbp), %rdi
callq 0x64cb0
movq %rax, %rdi
callq 0x5f330
addq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x48(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
andq $0x1, %rax
cmpl $0x1, %eax
jne 0x5d405
movq -0x48(%rbp), %rdx
movq %rdx, %rdi
addq $0x8, %rdi
movq -0x38(%rbp), %rsi
addq $0x14, %rdx
callq 0xec20
movq %rax, -0x28(%rbp)
jmp 0x5d425
movq -0x38(%rbp), %rdi
callq 0x5f350
movq -0x48(%rbp), %rdi
movl %eax, -0x40(%rbp)
movl -0x40(%rbp), %esi
callq 0x5bbf0
movq -0x38(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nop