// File: /workspace/github_c_makefile_star2_O0/msteveb[P]autosetup/./jimsh0.c
// Function: clock_cmd_format
static int clock_cmd_format(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{

    char buf[100];
    time_t t;
    jim_wide seconds;
    struct clock_options options = { 0, "%a %b %d %H:%M:%S %Z %Y" };
    struct tm *tm;

    if (Jim_GetWide(interp, argv[0], &seconds) != JIM_OK) {
        return JIM_ERR;
    }
    if (argc % 2 == 0) {
        return -1;
    }
    if (parse_clock_options(interp, argc - 1, argv + 1, &options) == JIM_ERR) {
        return JIM_ERR;
    }

    t = seconds;
    tm = options.gmt ? gmtime(&t) : localtime(&t);

    if (tm == NULL || strftime(buf, sizeof(buf), options.format, tm) == 0) {
        Jim_SetResultString(interp, "format string too long or invalid time", -1);
        return JIM_ERR;
    }

    Jim_SetResultString(interp, buf, -1);

    return JIM_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movq 0x2a743(%rip), %rax     # 0x46d60
movq %rax, -0xb0(%rbp)
movq 0x2a73d(%rip), %rax     # 0x46d68
movq %rax, -0xa8(%rbp)
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rax
movq (%rax), %rsi
leaq -0xa0(%rbp), %rdx
callq 0xf640
cmpl $0x0, %eax
je 0x1c65a
movl $0x1, -0x4(%rbp)
jmp 0x1c7f3
movl -0x14(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
cmpl $0x0, %edx
jne 0x1c676
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1c7f3
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
subl $0x1, %esi
movq -0x20(%rbp), %rdx
addq $0x8, %rdx
leaq -0xb0(%rbp), %rcx
callq 0x1c9a0
cmpl $0x1, %eax
jne 0x1c6a5
movl $0x1, -0x4(%rbp)
jmp 0x1c7f3
movq -0xa0(%rbp), %rax
movq %rax, -0x98(%rbp)
cmpl $0x0, -0xb0(%rbp)
je 0x1c6d1
leaq -0x98(%rbp), %rdi
callq 0x6460
movq %rax, -0xd0(%rbp)
jmp 0x1c6e4
leaq -0x98(%rbp), %rdi
callq 0x6060
movq %rax, -0xd0(%rbp)
movq -0xd0(%rbp), %rax
movq %rax, -0xb8(%rbp)
cmpq $0x0, -0xb8(%rbp)
je 0x1c721
leaq -0x90(%rbp), %rdi
movq -0xa8(%rbp), %rdx
movq -0xb8(%rbp), %rcx
movl $0x64, %esi
callq 0x63f0
cmpq $0x0, %rax
jne 0x1c78b
jmp 0x1c723
movq -0x10(%rbp), %rdi
leaq 0x1f6f1(%rip), %rsi     # 0x3be1f
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x7990
movq %rax, -0xc0(%rbp)
movq -0xc0(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movl 0x10(%rcx), %eax
addl $-0x1, %eax
movl %eax, 0x10(%rcx)
cmpl $0x0, %eax
jg 0x1c774
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
callq 0x7a10
movq -0xc0(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movl $0x1, -0x4(%rbp)
jmp 0x1c7f3
jmp 0x1c78d
movq -0x10(%rbp), %rdi
leaq -0x90(%rbp), %rsi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x7990
movq %rax, -0xc8(%rbp)
movq -0xc8(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movl 0x10(%rcx), %eax
addl $-0x1, %eax
movl %eax, 0x10(%rcx)
cmpl $0x0, %eax
jg 0x1c7de
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
callq 0x7a10
movq -0xc8(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0xd0, %rsp
popq %rbp
retq
nop