// File: /workspace/github_cpp_makefile_star2_O2/mh0fm4[P]SCDC/src/components/dataprov/dataprov_jobrun_relay.cc
// Function: scdc_dataset_jobrun_relay::do_cmd_ls(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_ls(const std::string &params, scdc_dataset_input_t *input, scdc_dataset_output_t *output, scdc_result &result)
    {
      string p = params;
      string jobid = pwd;
      bool have_remote = (remote_dataset != SCDC_DATASET_NULL);

      if (jobid.empty())
      {
        stringlist plist(' ', p);

        jobid = safe_jobid(plist.front_pop());

        p += plist.offset();

        if (jobid.size() == 0) return dataprov_jobrun_relay()->do_cmd_ls(p, input, output, result);

        remote_dataset_open(jobid, false);
      }

      if (remote_dataset == SCDC_DATASET_NULL)
      {
        result = "no remote dataset available";
        SCDC_FAIL(__func__ << ": listing remote dataset failed: " << result);
        return false;
      }

      string cmd = "ls ";
      if (!have_remote) cmd += jobid + " ";
      cmd += p;

      if (scdc_dataset_cmd(remote_dataset, cmd.c_str(), input, output) != SCDC_SUCCESS)
      {
        result = "remote command failed";
        SCDC_FAIL(__func__ << ": listing remote dataset failed: " << result);
        return false;
      }

      if (!have_remote) remote_dataset_close();

      return true;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %r8, %r13
movq %rcx, %r15
movq %rdx, %r12
movq %rdi, %r14
leaq 0x68(%rsp), %rdi
callq 0xb750
leaq 0x18(%r14), %rsi
leaq 0x28(%rsp), %rdi
callq 0xb750
movq 0x38(%r14), %rbx
cmpq $0x0, 0x30(%rsp)
movq %rbx, %rax
jne 0x451cc
leaq 0xc8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0xb750
movq %rsp, %rdi
pushq $0x20
popq %rsi
leaq 0xc8(%rsp), %rdx
callq 0x2f05c
leaq 0xc8(%rsp), %rdi
callq 0xb230
leaq 0xa8(%rsp), %rdi
movq %rsp, %rsi
callq 0x19ba0
movq %r13, %rbp
leaq 0x48(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x44fd5
leaq 0x28(%rsp), %rdi
leaq 0x48(%rsp), %r13
movq %r13, %rsi
callq 0xb690
movq %r13, %rdi
callq 0xb230
leaq 0xa8(%rsp), %rdi
callq 0xb230
leaq 0x20(%rsp), %rax
movq -0x20(%rax), %rcx
addq $0x30, %rcx
cmpq $0x0, -0x10(%rax)
cmoveq %rax, %rcx
movsbl (%rcx), %esi
leaq 0x68(%rsp), %rdi
callq 0xb450
movq 0x30(%rsp), %r13
testq %r13, %r13
je 0x451a8
leaq 0x88(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0xb750
leaq 0x88(%rsp), %rsi
movq %r14, %rdi
xorl %edx, %edx
callq 0x46228
leaq 0x88(%rsp), %rdi
callq 0xb230
jmp 0x451b4
movq 0x8(%r14), %rdi
movq %rbp, %r8
callq 0x445a8
movq %rsp, %rdi
callq 0x19ef4
testq %r13, %r13
je 0x45382
movq 0x38(%r14), %rax
movq %rbp, %r13
testq %rax, %rax
je 0x45261
leaq 0xf2ea(%rip), %rsi      # 0x544c6
movq %rsp, %rdi
leaq 0x48(%rsp), %rdx
callq 0x1a132
testq %rbx, %rbx
jne 0x4521b
leaq 0xee0b(%rip), %rdx      # 0x54000
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x1d867
movq %rsp, %rdi
leaq 0x48(%rsp), %rsi
callq 0xba90
leaq 0x48(%rsp), %rdi
callq 0xb230
movq %rsp, %rdi
leaq 0x68(%rsp), %rsi
callq 0xba90
movq 0x38(%r14), %rdi
movq (%rsp), %rsi
movq %r12, %rdx
movq %r15, %rcx
xorl %eax, %eax
callq 0x1909c
cmpq $0x1, %rax
sete %bpl
jne 0x452f0
testq %rbx, %rbx
jne 0x45378
movq %r14, %rdi
callq 0x463c6
jmp 0x45378
leaq 0xf209(%rip), %rsi      # 0x54471
movq %r13, %rdi
callq 0xba40
leaq 0x30309(%rip), %rbx     # 0x75580
movq (%rbx), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x452e9
addq $0x20, %rdi
callq 0xb800
movq (%rbx), %rax
movq 0x8(%rax), %rdi
leaq 0xbef0(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0xf1e9(%rip), %rsi      # 0x5448d
movq %rax, %rdi
callq 0xb520
leaq 0xcb43(%rip), %rsi      # 0x51df6
movq %rax, %rdi
callq 0xb520
leaq 0xf1e2(%rip), %rsi      # 0x544a4
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %r13, %rsi
callq 0xb490
movq %rax, %rdi
callq 0xb270
movq (%rbx), %rdi
addq $0x20, %rdi
callq 0xb3e0
xorl %ebp, %ebp
jmp 0x45385
leaq 0xf1d3(%rip), %rsi      # 0x544ca
movq %r13, %rdi
callq 0xba40
leaq 0x3027a(%rip), %rbx     # 0x75580
movq (%rbx), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x45378
addq $0x20, %rdi
callq 0xb800
movq (%rbx), %rax
movq 0x8(%rax), %rdi
leaq 0xbe61(%rip), %rsi      # 0x51188
callq 0xb520
leaq 0xf15a(%rip), %rsi      # 0x5448d
movq %rax, %rdi
callq 0xb520
leaq 0xcab4(%rip), %rsi      # 0x51df6
movq %rax, %rdi
callq 0xb520
leaq 0xf153(%rip), %rsi      # 0x544a4
movq %rax, %rdi
callq 0xb520
movq %rax, %rdi
movq %r13, %rsi
callq 0xb490
movq %rax, %rdi
callq 0xb270
movq (%rbx), %rdi
addq $0x20, %rdi
callq 0xb3e0
movq %rsp, %rdi
callq 0xb230
jmp 0x45385
movb $0x1, %bpl
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x68(%rsp), %rdi
callq 0xb230
movl %ebp, %eax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xb230
jmp 0x4540a
jmp 0x45407
movq %rax, %rbx
leaq 0x88(%rsp), %rdi
jmp 0x453d6
movq %rax, %rbx
leaq 0xa8(%rsp), %rdi
callq 0xb230
jmp 0x453f3
jmp 0x453f0
movq %rax, %rbx
leaq 0xc8(%rsp), %rdi
jmp 0x4540d
jmp 0x45402
jmp 0x45402
movq %rax, %rbx
movq %rsp, %rdi
callq 0x19ef4
jmp 0x45412
movq %rax, %rbx
jmp 0x4541c
movq %rax, %rbx
jmp 0x45412
movq %rax, %rbx
movq %rsp, %rdi
callq 0xb230
leaq 0x28(%rsp), %rdi
callq 0xb230
leaq 0x68(%rsp), %rdi
callq 0xb230
movq %rbx, %rdi
callq 0xb9a0