// File: /workspace/github_cpp_makefile_star2_O3/tdv[P]boss/boss/include/common/xml_property_bag.h
// Function: Boss::XmlPropertyBag::Save(Boss::IOStream*)
virtual RetCode BOSS_CALL Save(IOStream *stream)
    {
      if (!stream)
        return Status::InvalidArgument;
      try
      {
        std::lock_guard<std::recursive_mutex> Lock(Mtx);
        rapidxml::xml_document<> Doc;
        auto *RootNode = Doc.allocate_node(rapidxml::node_element, RootName.c_str());
        Doc.append_node(RootNode);
        for (auto &prop : Props)
          SerializeItem(prop.first, prop.second.Get(), &Doc, RootNode);
        std::stringstream Io;
        rapidxml::print(std::ostream_iterator<char>(Io), Doc, 0);
        std::string Xml(Io.str());
        return stream->Write(Xml.c_str(), Xml.length());
      }
      catch (...)
      {
        return Status::Fail;
      }
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10248, %rsp          # imm = 0x10248
testq %rsi, %rsi
je 0x1fd1f
movq %rsi, %r15
movq %rdi, %r12
addq $0x20, %rdi
movq %rdi, (%rsp)
callq 0x19620
testl %eax, %eax
jne 0x1fd38
xorl %eax, %eax
leaq 0x220(%rsp), %r14
movq %rax, -0x40(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, -0x60(%r14)
movl $0x0, -0x38(%r14)
movq %rax, -0x30(%r14)
movq %rax, -0x20(%r14)
leaq 0x10238(%rsp), %rax
leaq 0x238(%rsp), %rcx
movups %xmm0, (%rax)
movq %rcx, -0x18(%rcx)
movq %rcx, -0x10(%rcx)
movq %rax, -0x8(%rcx)
movq 0x80(%r12), %rbp
movl $0x60, %esi
movq %r14, %rdi
callq 0x2379e
movq %rax, %r13
xorl %eax, %eax
movq %rax, 0x20(%r13)
xorps %xmm0, %xmm0
movups %xmm0, (%r13)
movl $0x1, 0x28(%r13)
movq %rax, 0x30(%r13)
movq %rax, 0x40(%r13)
testq %rbp, %rbp
je 0x1fc45
movq $-0x1, %rax
cmpb $0x0, 0x1(%rbp,%rax)
leaq 0x1(%rax), %rax
jne 0x1fc32
movq %rbp, (%r13)
movq %rax, 0x10(%r13)
leaq 0x1c0(%rsp), %rdi
movq %r13, %rsi
callq 0x22c9c
leaq 0x58(%r12), %rbx
leaq 0x1c0(%rsp), %rbp
movq (%rbx), %rbx
testq %rbx, %rbx
je 0x1fc82
leaq 0x8(%rbx), %rsi
movq 0x28(%rbx), %rdx
movq %r12, %rdi
movq %rbp, %rcx
movq %r13, %r8
callq 0x244e2
jmp 0x1fc62
leaq 0x38(%rsp), %rdi
callq 0x9ff30
leaq 0x48(%rsp), %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movq $0x0, 0x8(%rsi)
leaq 0x28(%rsp), %rdi
leaq 0x1c0(%rsp), %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x250b6
leaq 0x50(%rsp), %rsi
leaq 0x8(%rsp), %rdi
callq 0x9c9d0
movq 0x8(%rsp), %rsi
movl 0x10(%rsp), %edx
movq (%r15), %rax
movq %r15, %rdi
callq *0x28(%rax)
movl %eax, %ebp
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1fcee
callq 0x29fe0
leaq 0xfe6bb(%rip), %rsi     # 0x11e3b0
leaq 0x38(%rsp), %rdi
callq 0xa09d0
leaq 0xb8(%rsp), %rdi
callq 0x78a20
movq %r14, %rdi
callq 0x2448a
movq (%rsp), %rdi
callq 0x19680
jmp 0x1fd24
movl $0x5, %ebp
movl %ebp, %eax
addq $0x10248, %rsp          # imm = 0x10248
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x1b2b1
movq %rax, %rdi
callq 0x1e4f5
movq %rax, %r15
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1fd64
callq 0x29fe0
jmp 0x1fd64
jmp 0x1fd61
movq %rax, %r15
leaq 0xfe645(%rip), %rsi     # 0x11e3b0
leaq 0x38(%rsp), %rdi
callq 0xa09d0
leaq 0xb8(%rsp), %rdi
callq 0x78a20
jmp 0x1fd90
jmp 0x1fd8d
movq %rax, %r15
jmp 0x1fda1
jmp 0x1fd8d
movq %rax, %r15
movq %r14, %rdi
callq 0x2448a
movq (%rsp), %rdi
callq 0x19680
movq %r15, %rdi
callq 0x2a440
callq 0x2a4b0
movl $0x2, %ebp
jmp 0x1fd24
jmp 0x1fd3f