// File: /workspace/github_cpp_makefile_star2_O2/mindbeast[P]rnes/bin/save.pb.cc
// Function: Rnes::ApuState::MergeFrom(Rnes::ApuState const&)
void ApuState::MergeFrom(const ApuState& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:Rnes.ApuState)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  reg_.MergeFrom(from.reg_);
  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 0x000000ffu) {
    if (cached_has_bits & 0x00000001u) {
      _internal_mutable_pulsea()->::Rnes::PulseState::MergeFrom(from._internal_pulsea());
    }
    if (cached_has_bits & 0x00000002u) {
      _internal_mutable_pulseb()->::Rnes::PulseState::MergeFrom(from._internal_pulseb());
    }
    if (cached_has_bits & 0x00000004u) {
      _internal_mutable_triangle()->::Rnes::TriangleState::MergeFrom(from._internal_triangle());
    }
    if (cached_has_bits & 0x00000008u) {
      _internal_mutable_noise()->::Rnes::NoiseState::MergeFrom(from._internal_noise());
    }
    if (cached_has_bits & 0x00000010u) {
      samplerate_ = from.samplerate_;
    }
    if (cached_has_bits & 0x00000020u) {
      fourframecount_ = from.fourframecount_;
    }
    if (cached_has_bits & 0x00000040u) {
      fiveframecount_ = from.fiveframecount_;
    }
    if (cached_has_bits & 0x00000080u) {
      framedivider_ = from.framedivider_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
  if (cached_has_bits & 0x00003f00u) {
    if (cached_has_bits & 0x00000100u) {
      step_ = from.step_;
    }
    if (cached_has_bits & 0x00000200u) {
      halftimerdivider_ = from.halftimerdivider_;
    }
    if (cached_has_bits & 0x00000400u) {
      samplerdivider_ = from.samplerdivider_;
    }
    if (cached_has_bits & 0x00000800u) {
      clkspersample_ = from.clkspersample_;
    }
    if (cached_has_bits & 0x00001000u) {
      currentsampleclk_ = from.currentsampleclk_;
    }
    if (cached_has_bits & 0x00002000u) {
      nextsamplecountdown_ = from.nextsamplecountdown_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpq %rdi, %rsi
jne 0x2071b
leaq 0xc69e(%rip), %rdx      # 0x2cd81
leaq -0x58(%rbp), %r15
pushq $0x3
popq %rsi
movq %r15, %rdi
movl $0xb9c, %ecx            # imm = 0xB9C
callq 0xb460
leaq 0xc692(%rip), %rsi      # 0x2cd90
movq %r15, %rdi
callq 0xb980
leaq -0x19(%rbp), %rdi
movq %rax, %rsi
callq 0xb5e0
leaq -0x58(%rbp), %rdi
callq 0xb730
movq 0x8(%r14), %rsi
testb $0x1, %sil
je 0x20736
leaq 0x8(%rbx), %rdi
andq $-0x2, %rsi
addq $0x8, %rsi
callq 0x291a6
leaq 0x18(%rbx), %rdi
leaq 0x18(%r14), %rsi
callq 0xb420
movl 0x10(%r14), %r15d
testb %r15b, %r15b
je 0x20827
testb $0x1, %r15b
je 0x20778
movq %rbx, %rdi
callq 0x15118
movq 0x28(%r14), %rcx
testq %rcx, %rcx
leaq 0x210d4(%rip), %rsi     # 0x41840
cmovneq %rcx, %rsi
movq %rax, %rdi
callq 0x1e9c8
testb $0x2, %r15b
je 0x207a0
movq %rbx, %rdi
callq 0x15152
movq 0x30(%r14), %rcx
testq %rcx, %rcx
leaq 0x210ac(%rip), %rsi     # 0x41840
cmovneq %rcx, %rsi
movq %rax, %rdi
callq 0x1e9c8
testb $0x4, %r15b
je 0x207c8
movq %rbx, %rdi
callq 0x1518c
movq 0x38(%r14), %rcx
testq %rcx, %rcx
leaq 0x210bc(%rip), %rsi     # 0x41878
cmovneq %rcx, %rsi
movq %rax, %rdi
callq 0x1f10a
testb $0x8, %r15b
je 0x207f0
movq %rbx, %rdi
callq 0x151c6
movq 0x40(%r14), %rcx
testq %rcx, %rcx
leaq 0x210c4(%rip), %rsi     # 0x418a8
cmovneq %rcx, %rsi
movq %rax, %rdi
callq 0x1f876
testb $0x10, %r15b
je 0x207fd
movl 0x48(%r14), %eax
movl %eax, 0x48(%rbx)
testb $0x20, %r15b
je 0x2080a
movl 0x4c(%r14), %eax
movl %eax, 0x4c(%rbx)
testb $0x40, %r15b
je 0x20817
movl 0x50(%r14), %eax
movl %eax, 0x50(%rbx)
testb %r15b, %r15b
jns 0x20823
movl 0x54(%r14), %eax
movl %eax, 0x54(%rbx)
orl %r15d, 0x10(%rbx)
testw $0x3f00, %r15w          # imm = 0x3F00
je 0x2088f
btl $0x8, %r15d
jae 0x2083d
movl 0x58(%r14), %eax
movl %eax, 0x58(%rbx)
btl $0x9, %r15d
jae 0x2084b
movl 0x5c(%r14), %eax
movl %eax, 0x5c(%rbx)
btl $0xa, %r15d
jae 0x20859
movl 0x60(%r14), %eax
movl %eax, 0x60(%rbx)
btl $0xb, %r15d
jae 0x2086b
movss 0x64(%r14), %xmm0
movss %xmm0, 0x64(%rbx)
btl $0xc, %r15d
jae 0x2087d
movss 0x68(%r14), %xmm0
movss %xmm0, 0x68(%rbx)
btl $0xd, %r15d
jae 0x2088b
movl 0x6c(%r14), %eax
movl %eax, 0x6c(%rbx)
orl %r15d, 0x10(%rbx)
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2089c
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0xb730
movq %rbx, %rdi
callq 0xb4e0