// File: /workspace/github_c_makefile_star2_O3/msteveb[P]autosetup/./jimsh0.c
// Function: SetDictFromAny
static int SetDictFromAny(Jim_Interp *interp, struct Jim_Obj *objPtr)
{
    int listlen;

    if (objPtr->typePtr == &dictObjType) {
        return JIM_OK;
    }

    if (Jim_IsList(objPtr) && Jim_IsShared(objPtr)) {
        Jim_String(objPtr);
    }

    listlen = Jim_ListLength(interp, objPtr);
    if (listlen % 2) {
        Jim_SetResultString(interp, "missing value to go with key", -1);
        return JIM_ERR;
    }
    else {

        Jim_Dict *dict = JimDictNew(interp, 0, listlen);
        int i;


        dict->table = objPtr->internalRep.listValue.ele;
        dict->maxLen = objPtr->internalRep.listValue.maxLen;


        for (i = 0; i < listlen; i += 2) {
            int tvoffset = JimDictAdd(dict, dict->table[i]);
            if (tvoffset) {


                Jim_DecrRefCount(interp, dict->table[tvoffset]);

                dict->table[tvoffset] = dict->table[i + 1];

                Jim_DecrRefCount(interp, dict->table[i]);
            }
            else {
                if (dict->len != i) {
                    dict->table[dict->len++] = dict->table[i];
                    dict->table[dict->len++] = dict->table[i + 1];
                }
                else {
                    dict->len += 2;
                }
            }
        }

        objPtr->typePtr = &dictObjType;
        objPtr->internalRep.dictValue = dict;

        return JIM_OK;
    }
}

// Assembly:
movq 0x8(%rsi), %rax
leaq 0x262f9(%rip), %rcx     # 0x35390
cmpq %rcx, %rax
je 0xf1fb
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x262ad(%rip), %rcx     # 0x35368
cmpq %rcx, %rax
jne 0xf0dd
cmpl $0x2, 0x10(%r14)
jl 0xf0dd
cmpq $0x0, (%r14)
jne 0xf0dd
movq 0x18(%r14), %rsi
movl 0x20(%r14), %edx
movq %r14, %rdi
callq 0x18f72
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe2fe
movl 0x20(%r14), %r15d
testb $0x1, %r15b
jne 0xf1fe
movl $0x30, %esi
xorl %edi, %edi
callq *0x28185(%rip)          # 0x37288
movq %rax, %r12
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movups %xmm0, 0x10(%rax)
movups %xmm0, 0x20(%rax)
testl %r15d, %r15d
je 0xf23b
movq %rbx, -0x30(%rbp)
movq %r12, %rdi
movl %r15d, %esi
callq 0x1943b
movq 0x18(%r14), %rax
movq %rax, 0x18(%r12)
movl 0x24(%r14), %eax
movl %eax, 0x24(%r12)
testl %r15d, %r15d
jle 0xf24d
xorl %r13d, %r13d
movq 0x18(%r12), %rax
movq (%rax,%r13,8), %rsi
movq %r12, %rdi
callq 0x193f8
testl %eax, %eax
je 0xf1b2
movq 0x18(%r12), %rcx
movslq %eax, %rbx
movq (%rcx,%rbx,8), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %edx
movl %edx, 0x10(%rsi)
cmpl $0x1, %eax
jg 0xf187
movq -0x30(%rbp), %rdi
callq 0x758c
movq 0x18(%r12), %rcx
movq 0x8(%rcx,%r13,8), %rax
movq %rax, (%rcx,%rbx,8)
movq 0x18(%r12), %rax
movq (%rax,%r13,8), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
cmpl $0x1, %eax
jg 0xf1ec
movq -0x30(%rbp), %rdi
callq 0x758c
jmp 0xf1ec
movl 0x20(%r12), %eax
cmpq %rax, %r13
jne 0xf1c6
addl $0x2, %eax
movl %eax, 0x20(%r12)
jmp 0xf1ec
cltq
movq 0x18(%r12), %rcx
movq (%rcx,%r13,8), %rdx
movq %rdx, (%rcx,%rax,8)
movq 0x18(%r12), %rcx
movq 0x8(%rcx,%r13,8), %rdx
leal 0x2(%rax), %esi
movl %esi, 0x20(%r12)
movq %rdx, 0x8(%rcx,%rax,8)
addq $0x2, %r13
cmpl %r13d, %r15d
jg 0xf14a
jmp 0xf24d
xorl %eax, %eax
retq
leaq 0x1cb16(%rip), %rsi     # 0x2bd1b
movq %rbx, %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x7508
movq %rax, %r14
incl 0x10(%rax)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
cmpl $0x1, %eax
jg 0xf231
movq %rbx, %rdi
callq 0x758c
movq %r14, (%rbx)
movl $0x1, %eax
jmp 0xf25e
movq 0x18(%r14), %rax
movq %rax, 0x18(%r12)
movl 0x24(%r14), %eax
movl %eax, 0x24(%r12)
leaq 0x2613c(%rip), %rax     # 0x35390
movq %rax, 0x8(%r14)
movq %r12, 0x18(%r14)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq