// File: /workspace/github_c_makefile_star2_O1/msteveb[P]autosetup/./jimsh0.c
// Function: Jim_TimeCoreCommand
static int Jim_TimeCoreCommand(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{
    long i, count = 1;
    jim_wide start, elapsed;

    if (argc < 2) {
        Jim_WrongNumArgs(interp, 1, argv, "script ?count?");
        return JIM_ERR;
    }
    if (argc == 3) {
        if (Jim_GetLong(interp, argv[2], &count) != JIM_OK)
            return JIM_ERR;
    }
    if (count < 0)
        return JIM_OK;
    i = count;
    start = Jim_GetTimeUsec(CLOCK_MONOTONIC_RAW);
    while (i-- > 0) {
        int retval;

        retval = Jim_EvalObj(interp, argv[1]);
        if (retval != JIM_OK) {
            return retval;
        }
    }
    elapsed = Jim_GetTimeUsec(CLOCK_MONOTONIC_RAW) - start;
    if (elapsed < count * 10) {
        Jim_SetResult(interp, Jim_NewDoubleObj(interp, elapsed * 1.0 / count));
    }
    else {
        Jim_SetResultInt(interp, count == 0 ? 0 : elapsed / count);
    }
    Jim_AppendString(interp, Jim_GetResult(interp)," microseconds per iteration", -1);
    return JIM_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rdi, %rbx
cmpl $0x1, %esi
jg 0x1f5b5
leaq 0xe7ec(%rip), %rcx      # 0x2dd86
movl $0x1, %r15d
movq %rbx, %rdi
movl $0x1, %esi
movq %r14, %rdx
callq 0x7454
jmp 0x1f740
movl $0x1, %r12d
cmpl $0x3, %esi
jne 0x1f601
movq 0x10(%r14), %r15
leaq 0x16d15(%rip), %rax     # 0x362e0
cmpq %rax, 0x8(%r15)
je 0x1f5e9
movq %rbx, %rdi
movq %r15, %rsi
movl $0x1, %edx
callq 0xd6d7
testl %eax, %eax
je 0x1f5e9
xorl %eax, %eax
jmp 0x1f5ef
movq 0x18(%r15), %rcx
movb $0x1, %al
movl $0x1, %r15d
testb %al, %al
cmovneq %rcx, %r12
je 0x1f740
testq %r12, %r12
js 0x1f73d
leaq -0x48(%rbp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x6210
movq (%r15), %rax
movq %rax, -0x38(%rbp)
movq 0x8(%r15), %rax
movq %rax, -0x30(%rbp)
leaq 0x1(%r12), %r13
decq %r13
testq %r13, %r13
jle 0x1f64d
movq 0x8(%r14), %rsi
movq %rbx, %rdi
callq 0x9078
testl %eax, %eax
cmovnel %eax, %r15d
je 0x1f62c
jmp 0x1f740
leaq -0x48(%rbp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x6210
movq (%r14), %rax
subq -0x38(%rbp), %rax
movq 0x8(%r14), %rcx
subq -0x30(%rbp), %rcx
imulq $0xf4240, %rax, %rax    # imm = 0xF4240
addq %rcx, %rax
leaq (%r12,%r12), %rcx
leaq (%rcx,%rcx,4), %rcx
cmpq %rcx, %rax
jge 0x1f6d3
cvtsi2sd %rax, %xmm1
cvtsi2sd %r12, %xmm0
divsd %xmm0, %xmm1
movsd %xmm1, -0x30(%rbp)
movq %rbx, %rdi
callq 0xae58
movq %rax, %r14
leaq 0x16c8a(%rip), %rax     # 0x36330
movq %rax, 0x8(%r14)
movq $0x0, (%r14)
movsd -0x30(%rbp), %xmm0
movsd %xmm0, 0x18(%r14)
incl 0x10(%r14)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
cmpl $0x2, %eax
jl 0x1f71b
jmp 0x1f723
testq %r12, %r12
je 0x1f6e2
cqto
idivq %r12
movq %rax, %r15
jmp 0x1f6e5
xorl %r15d, %r15d
movq %rbx, %rdi
callq 0xae58
movq %rax, %r14
leaq 0x16be9(%rip), %rax     # 0x362e0
movq %rax, 0x8(%r14)
movq $0x0, (%r14)
movq %r15, 0x18(%r14)
incl 0x10(%r14)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
cmpl $0x1, %eax
jg 0x1f723
movq %rbx, %rdi
callq 0x759a
movq %r14, (%rbx)
leaq 0xe668(%rip), %rdx      # 0x2dd95
movq %rbx, %rdi
movq %r14, %rsi
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x8653
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq