// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/dataprov/dataprov_fs2.cc
// Function: scdc_dataset_fs2_store::do_cmd_put(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, _scdc_dataset_inout_t*, _scdc_dataset_inout_t*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
bool do_cmd_put(const string &params, scdc_dataset_input_t *input, scdc_dataset_output_t *output, scdc_result &result)
    {
      SCDC_TRACE("do_cmd_put: '" << params << "'");

      scdc_dataprov_fs2 *dataprov_fs2 = static_cast<scdc_dataprov_fs2 *>(dataprov);

      if (params.empty())
      {
        result = "empty path";
        SCDC_FAIL(__func__ << ": writing to store failed: " << result);
        return false;

      } else if (admin)
      {
        SCDC_TRACE("do_cmd_put: creating store '" << params << "'");

        string store_path;
        dataprov_fs2->do_full_path(0, store_path);

        store_path += DIR_STORE_PREFIX + string(params) + "/";

        SCDC_TRACE("do_cmd_put: store_path: '" << store_path << "'");

        if (!z_fs_mkdir(store_path.c_str()))
        {
          result = string("creating store failed: ") + strerror(errno);
          SCDC_FAIL(__func__ << ": making store '" << store_path << "' failed: " << result);
          return false;
        }

      } else if (pwd.size() == 0)
      {
        result = "no store selected";
        SCDC_FAIL(__func__ << ": creating entry failed: " << result);
        return false;

      } else
      {
        SCDC_TRACE("do_cmd_put: creating entry '" << params << "'");

        string store_path;
        dataprov_fs2->do_full_path(0, store_path);

        store_path += DIR_STORE_PREFIX + pwd + "/";

        SCDC_TRACE("do_cmd_put: store_path: '" << store_path << "'");

        string entry_path = store_path + DIR_ENTRY_PREFIX + params + DIR_ENTRY_SUFFIX;

        SCDC_TRACE("do_cmd_put: entry_path: '" << entry_path.c_str() << "'");

        if (!input)
        {
          result = "no input available";
          SCDC_FAIL("do_cmd_put: creating entry failed: " << result);
          return false;
        }

        if (scdc_dataset_input_redirect(input, "to:file", entry_path.c_str()) != SCDC_SUCCESS)
        {
          result = " input redirection failed";
          SCDC_FAIL("do_cmd_put: creating entry failed: " << result);
          return false;
        }
      }

      return true;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %r8, %rbx
cmpq $0x0, 0x8(%rsi)
je 0x3983c
movq %rsi, %r15
movq %rdi, %r12
movq 0x8(%rdi), %rdi
cmpb $0x1, 0x6c(%r12)
leaq 0x58(%rsp), %rax
jne 0x398a6
leaq 0x48(%rsp), %rdx
movq %rax, (%rdx)
andq $0x0, 0x8(%rdx)
movb $0x0, 0x10(%rdx)
xorl %esi, %esi
callq 0x3783e
leaq 0x68(%rsp), %rdi
movq %r15, %rsi
callq 0xb750
leaq 0x19ebc(%rip), %rsi     # 0x5359f
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rdx
callq 0x218cd
leaq 0x17c54(%rip), %rdx     # 0x5134d
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1cb18
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0xba90
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x8(%rsp), %rdi
callq 0xb230
leaq 0x68(%rsp), %rdi
callq 0xb230
movq 0x48(%rsp), %rdi
callq 0x2da96
testq %rax, %rax
jne 0x399a3
leaq 0x19e9b(%rip), %rsi     # 0x535ea
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rdx
callq 0x1a132
callq 0xb060
movl (%rax), %edi
callq 0xb180
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
movq %rax, %rdx
callq 0x1cb18
leaq 0x28(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb690
movq %r14, %rdi
callq 0xb230
leaq 0x8(%rsp), %rdi
callq 0xb230
leaq 0x3bddb(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x39ae0
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x179be(%rip), %rsi     # 0x51188
callq 0xb520
leaq 0x19d8c(%rip), %rsi     # 0x53562
movq %rax, %rdi
callq 0xb520
leaq 0x182b4(%rip), %rsi     # 0x51a99
movq %rax, %rdi
callq 0xb520
leaq 0x19e0e(%rip), %rsi     # 0x53602
movq %rax, %rdi
callq 0xb520
leaq 0x48(%rsp), %rsi
movq %rax, %rdi
callq 0xb490
leaq 0x18195(%rip), %rsi     # 0x519a5
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb490
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
jmp 0x39ae0
leaq 0x19d80(%rip), %rsi     # 0x535c3
movq %rbx, %rdi
callq 0xba40
leaq 0x3bd2e(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x39aea
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x17911(%rip), %rsi     # 0x51188
callq 0xb520
leaq 0x19cdf(%rip), %rsi     # 0x53562
movq %rax, %rdi
callq 0xb520
leaq 0x18207(%rip), %rsi     # 0x51a99
movq %rax, %rdi
callq 0xb520
leaq 0x19d2d(%rip), %rsi     # 0x535ce
jmp 0x39a19
cmpq $0x0, 0x20(%r12)
je 0x399b4
movq %rdx, %r14
leaq 0x48(%rsp), %rdx
movq %rax, (%rdx)
andq $0x0, 0x8(%rdx)
movb $0x0, 0x10(%rdx)
xorl %esi, %esi
callq 0x3783e
addq $0x18, %r12
leaq 0x19cc7(%rip), %rsi     # 0x5359f
leaq 0x8(%rsp), %rdi
movq %r12, %rdx
callq 0x19ae2
leaq 0x17a61(%rip), %rdx     # 0x5134d
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1cb18
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0xba90
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x8(%rsp), %rdi
callq 0xb230
leaq 0x19c88(%rip), %rdx     # 0x535ad
leaq 0x68(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x1d867
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
movq %r15, %rdx
callq 0x1eeb2
leaq 0x18b70(%rip), %rdx     # 0x524bd
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1cb18
leaq 0x8(%rsp), %rdi
callq 0xb230
leaq 0x68(%rsp), %rdi
callq 0xb230
testq %r14, %r14
je 0x39a45
movq 0x28(%rsp), %rdx
leaq 0x19cd7(%rip), %rsi     # 0x5365c
movq %r14, %rdi
xorl %eax, %eax
callq 0x273af
cmpq $0x1, %rax
jne 0x39a56
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x48(%rsp), %rdi
callq 0xb230
movb $0x1, %al
jmp 0x39aec
leaq 0x19c58(%rip), %rsi     # 0x53613
movq %rbx, %rdi
callq 0xba40
leaq 0x3bbb6(%rip), %r14     # 0x75580
movq (%r14), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x39aea
addq $0x20, %rdi
callq 0xb800
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x17799(%rip), %rsi     # 0x51188
callq 0xb520
leaq 0x19b67(%rip), %rsi     # 0x53562
movq %rax, %rdi
callq 0xb520
leaq 0x1808f(%rip), %rsi     # 0x51a99
movq %rax, %rdi
callq 0xb520
leaq 0x19c29(%rip), %rsi     # 0x53642
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb490
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
jmp 0x39aea
leaq 0x19bd9(%rip), %rsi     # 0x53625
movq %rbx, %rdi
callq 0xba40
jmp 0x39a65
leaq 0x19c07(%rip), %rsi     # 0x53664
movq %rbx, %rdi
callq 0xba40
leaq 0x3bb14(%rip), %rax     # 0x75580
movq (%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x39ad6
addq $0x20, %rdi
callq 0xb800
leaq 0x3bafa(%rip), %r14     # 0x75580
movq (%r14), %rax
movq 0x8(%rax), %rdi
leaq 0x176f4(%rip), %rsi     # 0x51188
callq 0xb520
leaq 0x19ac2(%rip), %rsi     # 0x53562
movq %rax, %rdi
callq 0xb520
leaq 0x19b89(%rip), %rsi     # 0x53638
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %rbx, %rsi
callq 0xb490
movq %rax, %rdi
callq 0xb270
movq (%r14), %rdi
addq $0x20, %rdi
callq 0xb3e0
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x48(%rsp), %rdi
callq 0xb230
xorl %eax, %eax
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x39b14
jmp 0x39b5b
jmp 0x39b31
jmp 0x39b40
jmp 0x39b5b
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xb230
jmp 0x39b17
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
jmp 0x39b54
jmp 0x39b5b
jmp 0x39b5b
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xb230
jmp 0x39b34
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xb230
jmp 0x39b43
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
jmp 0x39b54
jmp 0x39b5b
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xb230
jmp 0x39b5e
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0