LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_value_init_array
JSON_Value * json_value_init_array(void) {
    JSON_Value *new_value = (JSON_Value*)parson_malloc(sizeof(JSON_Value));
    if (!new_value) {
        return NULL;
    }
    new_value->parent = NULL;
    new_value->type = JSONArray;
    new_value->value.array = json_array_init(new_value);
    if (!new_value->value.array) {
        parson_free(new_value);
        return NULL;
    }
    return new_value;
}

// Assembly:
pushq %rbx
movl $0x18, %edi
callq *0x630f(%rip)           # 0xa190
testq %rax, %rax
je 0x3ecf
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x5, 0x8(%rax)
movl $0x20, %edi
callq *0x62ee(%rip)           # 0xa190
testq %rax, %rax
je 0x3ebb
movq %rbx, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movq $0x0, 0x18(%rax)
jmp 0x3ebd
xorl %eax, %eax
movq %rax, 0x10(%rbx)
testq %rax, %rax
jne 0x3ed1
movq %rbx, %rdi
callq *0x62b9(%rip)           # 0xa188
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_value_init_number
JSON_Value * json_value_init_number(double number) {
    JSON_Value *new_value = (JSON_Value*)parson_malloc(sizeof(JSON_Value));
    if (!new_value) {
        return NULL;
    }
    new_value->parent = NULL;
    new_value->type = JSONNumber;
    new_value->value.number = number;
    return new_value;
}

// Assembly:
pushq %rax
movsd %xmm0, (%rsp)
movl $0x18, %edi
callq *0x6012(%rip)           # 0xa190
testq %rax, %rax
je 0x419d
movq $0x0, (%rax)
movl $0x3, 0x8(%rax)
movsd (%rsp), %xmm0
movsd %xmm0, 0x10(%rax)
jmp 0x419f
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_value_init_boolean
JSON_Value * json_value_init_boolean(int boolean) {
    JSON_Value *new_value = (JSON_Value*)parson_malloc(sizeof(JSON_Value));
    if (!new_value) {
        return NULL;
    }
    new_value->parent = NULL;
    new_value->type = JSONBoolean;
    new_value->value.boolean = boolean ? 1 : 0;
    return new_value;
}

// Assembly:
pushq %rbx
movl %edi, %ebx
movl $0x18, %edi
callq *0x5fe1(%rip)           # 0xa190
testq %rax, %rax
je 0x41ce
movq $0x0, (%rax)
movl $0x6, 0x8(%rax)
xorl %ecx, %ecx
testl %ebx, %ebx
setne %cl
movl %ecx, 0x10(%rax)
jmp 0x41d0
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_value_init_null
JSON_Value * json_value_init_null(void) {
    JSON_Value *new_value = (JSON_Value*)parson_malloc(sizeof(JSON_Value));
    if (!new_value) {
        return NULL;
    }
    new_value->parent = NULL;
    new_value->type = JSONNull;
    return new_value;
}

// Assembly:
pushq %rax
movl $0x18, %edi
callq *0x5fb2(%rip)           # 0xa190
testq %rax, %rax
je 0x41f3
movq $0x0, (%rax)
movl $0x1, 0x8(%rax)
jmp 0x41f5
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_add
static JSON_Status json_array_add(JSON_Array *array, JSON_Value *value) {
    if (array->count >= array->capacity) {
        size_t new_capacity = MAX(array->capacity * 2, STARTING_CAPACITY);
        if (new_capacity > ARRAY_MAX_CAPACITY) {
            return JSONFailure;
        }
        if (json_array_resize(array, new_capacity) == JSONFailure) {
            return JSONFailure;
        }
    }
    value->parent = json_array_get_wrapping_value(array);
    array->items[array->count] = value;
    array->count++;
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rdi), %rax
cmpq %rax, 0x10(%rdi)
jb 0x450e
addq %rax, %rax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpq $0x1e000, %rax          # imm = 0x1E000
ja 0x4529
cmpq $0x10, %rax
movl $0xf, %esi
cmovaeq %rax, %rsi
movq %rbx, %rdi
callq 0x6335
cmpl $-0x1, %eax
je 0x4529
movq (%rbx), %rax
movq %rax, (%r14)
movq 0x8(%rbx), %rax
movq 0x10(%rbx), %rcx
movq %r14, (%rax,%rcx,8)
incq %rcx
movq %rcx, 0x10(%rbx)
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_add
static JSON_Status json_object_add(JSON_Object *object, const char *name, JSON_Value *value) {
    size_t index = 0;
    if (object == NULL || name == NULL || value == NULL) {
        return JSONFailure;
    }
    if (json_object_get_value(object, name) != NULL) {
        return JSONFailure;
    }
    if (object->count >= object->capacity) {
        size_t new_capacity = MAX(object->capacity * 2, STARTING_CAPACITY);
        if (new_capacity > OBJECT_MAX_CAPACITY) {
            return JSONFailure;
        }
        if (json_object_resize(object, new_capacity) == JSONFailure) {
            return JSONFailure;
        }
    }
    index = object->count;
    object->names[index] = parson_strdup(name);
    if (object->names[index] == NULL) {
        return JSONFailure;
    }
    value->parent = json_object_get_wrapping_value(object);
    object->values[index] = value;
    object->count++;
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
testq %rdi, %rdi
sete %al
testq %rsi, %rsi
sete %cl
orb %al, %cl
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jne 0x4561
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
callq 0x3936
testq %rax, %rax
je 0x456d
movl %ebx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq 0x20(%r15), %rax
cmpq %rax, 0x18(%r15)
jb 0x459c
addq %rax, %rax
cmpq $0x3c0, %rax            # imm = 0x3C0
ja 0x4561
cmpq $0x10, %rax
movl $0xf, %esi
cmovaeq %rax, %rsi
movq %r15, %rdi
callq 0x60fb
cmpl $-0x1, %eax
je 0x4561
movq 0x18(%r15), %r13
movq %r12, %rdi
callq 0x37b6
movq 0x8(%r15), %rcx
movq %rax, (%rcx,%r13,8)
movq 0x8(%r15), %rax
cmpq $0x0, (%rax,%r13,8)
je 0x4561
movq (%r15), %rax
movq %rax, (%r14)
movq 0x10(%r15), %rax
movq %r14, (%rax,%r13,8)
incq 0x18(%r15)
xorl %ebx, %ebx
jmp 0x4561
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_buffer
JSON_Status json_serialize_to_buffer(const JSON_Value *value, char *buf, size_t buf_size_in_bytes) {
    int written = -1;
    size_t needed_size_in_bytes = json_serialization_size(value);
    if (needed_size_in_bytes == 0 || buf_size_in_bytes < needed_size_in_bytes) {
        return JSONFailure;
    }
    written = json_serialize_to_buffer_r(value, buf, 0, 0, NULL);
    if (written < 0) {
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x458, %rsp            # imm = 0x458
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
xorl %r12d, %r12d
movq %rsp, %r8
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x45fd
leal 0x1(%rax), %ecx
testl %eax, %eax
cmovsl %r12d, %ecx
testl %ecx, %ecx
sete %al
cmpq %r15, %rcx
seta %cl
orb %al, %cl
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jne 0x4c4e
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45fd
sarl $0x1f, %eax
addq $0x458, %rsp            # imm = 0x458
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_file
JSON_Status json_serialize_to_file(const JSON_Value *value, const char *filename) {
    JSON_Status return_code = JSONSuccess;
    FILE *fp = NULL;
    char *serialized_string = json_serialize_to_string(value);
    if (serialized_string == NULL) {
        return JSONFailure;
    }
    fp = fopen (filename, "w");
    if (fp == NULL) {
        json_free_serialized_string(serialized_string);
        return JSONFailure;
    }
    if (fputs(serialized_string, fp) == EOF) {
        return_code = JSONFailure;
    }
    if (fclose(fp) == EOF) {
        return_code = JSONFailure;
    }
    json_free_serialized_string(serialized_string);
    return return_code;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
callq 0x4cce
testq %rax, %rax
je 0x4cb2
movq %rax, %rbx
leaq 0x2829(%rip), %rsi      # 0x74a1
movq %r14, %rdi
callq 0x22a0
testq %rax, %rax
je 0x4cb9
movq %rax, %r14
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2190
cmpl $-0x1, %eax
sete %bpl
movq %r14, %rdi
callq 0x20f0
cmpl $-0x1, %eax
sete %al
orb %bpl, %al
movzbl %al, %ebp
negl %ebp
jmp 0x4cbe
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
jmp 0x4cc7
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movq %rbx, %rdi
callq *0x54c1(%rip)           # 0xa188
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_string
char * json_serialize_to_string(const JSON_Value *value) {
    JSON_Status serialization_result = JSONFailure;
    size_t buf_size_bytes = json_serialization_size(value);
    char *buf = NULL;
    if (buf_size_bytes == 0) {
        return NULL;
    }
    buf = (char*)parson_malloc(buf_size_bytes);
    if (buf == NULL) {
        return NULL;
    }
    serialization_result = json_serialize_to_buffer(value, buf, buf_size_bytes);
    if (serialization_result == JSONFailure) {
        json_free_serialized_string(buf);
        return NULL;
    }
    return buf;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x450, %rsp            # imm = 0x450
movq %rdi, %r14
xorl %ebx, %ebx
movq %rsp, %r8
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x45fd
leal 0x1(%rax), %r15d
testl %eax, %eax
cmovsl %ebx, %r15d
testl %r15d, %r15d
je 0x4d2b
movq %r15, %rdi
callq *0x548b(%rip)           # 0xa190
testq %rax, %rax
je 0x4d29
movq %rax, %rbx
movq %r14, %rdi
movq %rax, %rsi
movq %r15, %rdx
callq 0x4bf4
cmpl $-0x1, %eax
jne 0x4d2b
movq %rbx, %rdi
callq *0x545f(%rip)           # 0xa188
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x450, %rsp            # imm = 0x450
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_buffer_pretty
JSON_Status json_serialize_to_buffer_pretty(const JSON_Value *value, char *buf, size_t buf_size_in_bytes) {
    int written = -1;
    size_t needed_size_in_bytes = json_serialization_size_pretty(value);
    if (needed_size_in_bytes == 0 || buf_size_in_bytes < needed_size_in_bytes) {
        return JSONFailure;
    }
    written = json_serialize_to_buffer_r(value, buf, 0, 1, NULL);
    if (written < 0) {
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x458, %rsp            # imm = 0x458
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
xorl %r12d, %r12d
movq %rsp, %r8
xorl %esi, %esi
xorl %edx, %edx
movl $0x1, %ecx
callq 0x45fd
leal 0x1(%rax), %ecx
testl %eax, %eax
cmovsl %r12d, %ecx
testl %ecx, %ecx
sete %al
cmpq %r15, %rcx
seta %cl
orb %al, %cl
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jne 0x4dd0
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
movl $0x1, %ecx
xorl %r8d, %r8d
callq 0x45fd
sarl $0x1f, %eax
addq $0x458, %rsp            # imm = 0x458
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_file_pretty
JSON_Status json_serialize_to_file_pretty(const JSON_Value *value, const char *filename) {
    JSON_Status return_code = JSONSuccess;
    FILE *fp = NULL;
    char *serialized_string = json_serialize_to_string_pretty(value);
    if (serialized_string == NULL) {
        return JSONFailure;
    }
    fp = fopen (filename, "w");
    if (fp == NULL) {
        json_free_serialized_string(serialized_string);
        return JSONFailure;
    }
    if (fputs(serialized_string, fp) == EOF) {
        return_code = JSONFailure;
    }
    if (fclose(fp) == EOF) {
        return_code = JSONFailure;
    }
    json_free_serialized_string(serialized_string);
    return return_code;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
callq 0x4e50
testq %rax, %rax
je 0x4e34
movq %rax, %rbx
leaq 0x26a7(%rip), %rsi      # 0x74a1
movq %r14, %rdi
callq 0x22a0
testq %rax, %rax
je 0x4e3b
movq %rax, %r14
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2190
cmpl $-0x1, %eax
sete %bpl
movq %r14, %rdi
callq 0x20f0
cmpl $-0x1, %eax
sete %al
orb %bpl, %al
movzbl %al, %ebp
negl %ebp
jmp 0x4e40
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
jmp 0x4e49
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movq %rbx, %rdi
callq *0x533f(%rip)           # 0xa188
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_serialize_to_string_pretty
char * json_serialize_to_string_pretty(const JSON_Value *value) {
    JSON_Status serialization_result = JSONFailure;
    size_t buf_size_bytes = json_serialization_size_pretty(value);
    char *buf = NULL;
    if (buf_size_bytes == 0) {
        return NULL;
    }
    buf = (char*)parson_malloc(buf_size_bytes);
    if (buf == NULL) {
        return NULL;
    }
    serialization_result = json_serialize_to_buffer_pretty(value, buf, buf_size_bytes);
    if (serialization_result == JSONFailure) {
        json_free_serialized_string(buf);
        return NULL;
    }
    return buf;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x450, %rsp            # imm = 0x450
movq %rdi, %r14
xorl %ebx, %ebx
movq %rsp, %r8
xorl %esi, %esi
xorl %edx, %edx
movl $0x1, %ecx
callq 0x45fd
leal 0x1(%rax), %r15d
testl %eax, %eax
cmovsl %ebx, %r15d
testl %r15d, %r15d
je 0x4eb0
movq %r15, %rdi
callq *0x5306(%rip)           # 0xa190
testq %rax, %rax
je 0x4eae
movq %rax, %rbx
movq %r14, %rdi
movq %rax, %rsi
movq %r15, %rdx
callq 0x4d70
cmpl $-0x1, %eax
jne 0x4eb0
movq %rbx, %rdi
callq *0x52da(%rip)           # 0xa188
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x450, %rsp            # imm = 0x450
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_remove
JSON_Status json_array_remove(JSON_Array *array, size_t ix) {
    size_t to_move_bytes = 0;
    if (array == NULL || ix >= json_array_get_count(array)) {
        return JSONFailure;
    }
    json_value_free(json_array_get_value(array, ix));
    to_move_bytes = (json_array_get_count(array) - 1 - ix) * sizeof(JSON_Value**);
    memmove(array->items + ix, array->items + ix + 1, to_move_bytes);
    array->count -= 1;
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x4f1b
movq %rsi, %r15
movq %rdi, %r14
cmpq %rsi, 0x10(%rdi)
jbe 0x4f1b
xorl %ebx, %ebx
cmpq %r15, 0x10(%r14)
jbe 0x4eed
movq 0x8(%r14), %rax
movq (%rax,%r15,8), %rdi
jmp 0x4eef
xorl %edi, %edi
callq 0x3d65
movq %r15, %rdx
notq %rdx
addq 0x10(%r14), %rdx
shlq $0x3, %rdx
movq 0x8(%r14), %rax
leaq (%rax,%r15,8), %rdi
leaq (%rax,%r15,8), %rsi
addq $0x8, %rsi
callq 0x2270
decq 0x10(%r14)
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_replace_value
JSON_Status json_array_replace_value(JSON_Array *array, size_t ix, JSON_Value *value) {
    if (array == NULL || value == NULL || value->parent != NULL || ix >= json_array_get_count(array)) {
        return JSONFailure;
    }
    json_value_free(json_array_get_value(array, ix));
    value->parent = json_array_get_wrapping_value(array);
    array->items[ix] = value;
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
sete %al
testq %rdx, %rdx
sete %cl
orb %al, %cl
movl $0xffffffff, %r14d      # imm = 0xFFFFFFFF
jne 0x4f82
movq %rdx, %rbx
cmpq $0x0, (%rdx)
jne 0x4f82
movq %rsi, %r15
movq %rdi, %r12
cmpq %rsi, 0x10(%rdi)
jbe 0x4f82
xorl %r14d, %r14d
cmpq %r15, 0x10(%r12)
jbe 0x4f6b
movq 0x8(%r12), %rax
movq (%rax,%r15,8), %rdi
jmp 0x4f6d
xorl %edi, %edi
callq 0x3d65
movq (%r12), %rax
movq %rax, (%rbx)
movq 0x8(%r12), %rax
movq %rbx, (%rax,%r15,8)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_replace_string
JSON_Status json_array_replace_string(JSON_Array *array, size_t i, const char* string) {
    JSON_Value *value = json_value_init_string(string);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_replace_value(array, i, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x3ed6
movq %rax, %rbx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x4fd5
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x4f23
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x4fd5
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_replace_number
JSON_Status json_array_replace_number(JSON_Array *array, size_t i, double number) {
    JSON_Value *value = json_value_init_number(number);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_replace_value(array, i, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, 0x8(%rsp)
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x5195(%rip)           # 0xa190
testq %rax, %rax
je 0x501e
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x3, 0x8(%rax)
movsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x10(%rax)
jmp 0x5020
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x504e
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x4f23
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x504e
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_replace_boolean
JSON_Status json_array_replace_boolean(JSON_Array *array, size_t i, int boolean) {
    JSON_Value *value = json_value_init_boolean(boolean);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_replace_value(array, i, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x511e(%rip)           # 0xa190
testq %rax, %rax
je 0x5094
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x6, 0x8(%rax)
xorl %eax, %eax
testl %ebp, %ebp
setne %al
movl %eax, 0x10(%rbx)
jmp 0x5096
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x50c4
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x4f23
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x50c4
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_replace_null
JSON_Status json_array_replace_null(JSON_Array *array, size_t i) {
    JSON_Value *value = json_value_init_null();
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_replace_value(array, i, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x50ab(%rip)           # 0xa190
testq %rax, %rax
je 0x50fd
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x1, 0x8(%rax)
jmp 0x50ff
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x512d
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x4f23
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x512d
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_clear
JSON_Status json_array_clear(JSON_Array *array) {
    size_t i = 0;
    if (array == NULL) {
        return JSONFailure;
    }
    for (i = 0; i < json_array_get_count(array); i++) {
        json_value_free(json_array_get_value(array, i));
    }
    array->count = 0;
    return JSONSuccess;
}

// Assembly:
testq %rdi, %rdi
je 0x517b
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpq $0x0, 0x10(%rdi)
je 0x5169
xorl %r14d, %r14d
cmpq %r14, 0x10(%rbx)
jbe 0x5159
movq 0x8(%rbx), %rax
movq (%rax,%r14,8), %rdi
jmp 0x515b
xorl %edi, %edi
callq 0x3d65
incq %r14
cmpq 0x10(%rbx), %r14
jb 0x5149
movq $0x0, 0x10(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_append_string
JSON_Status json_array_append_string(JSON_Array *array, const char *string) {
    JSON_Value *value = json_value_init_string(string);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_append_value(array, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq %rsi, %rdi
callq 0x3ed6
movq %rax, %rbx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x51d5
testq %r14, %r14
je 0x51c8
cmpq $0x0, (%rbx)
je 0x51dd
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x44d0
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x51d5
jmp 0x51c8
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_append_number
JSON_Status json_array_append_number(JSON_Array *array, double number) {
    JSON_Value *value = json_value_init_number(number);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_append_value(array, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movsd %xmm0, (%rsp)
movq %rdi, %r14
movl $0x18, %edi
callq *0x4f86(%rip)           # 0xa190
testq %rax, %rax
je 0x522c
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x3, 0x8(%rax)
movsd (%rsp), %xmm0
movsd %xmm0, 0x10(%rax)
jmp 0x522e
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x5250
testq %r14, %r14
je 0x5243
cmpq $0x0, (%rbx)
je 0x5258
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x44d0
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x5250
jmp 0x5243
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_append_boolean
JSON_Status json_array_append_boolean(JSON_Array *array, int boolean) {
    JSON_Value *value = json_value_init_boolean(boolean);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_append_value(array, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %r14
movl $0x18, %edi
callq *0x4f0e(%rip)           # 0xa190
testq %rax, %rax
je 0x52a4
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x6, 0x8(%rax)
xorl %eax, %eax
testl %ebp, %ebp
setne %al
movl %eax, 0x10(%rbx)
jmp 0x52a6
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x52c8
testq %r14, %r14
je 0x52bb
cmpq $0x0, (%rbx)
je 0x52cd
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %rbp
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x44d0
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x52c8
jmp 0x52bb
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_append_null
JSON_Status json_array_append_null(JSON_Array *array) {
    JSON_Value *value = json_value_init_null();
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_array_append_value(array, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x18, %edi
callq *0x4e9b(%rip)           # 0xa190
testq %rax, %rax
je 0x530d
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x1, 0x8(%rax)
jmp 0x530f
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x5331
testq %r14, %r14
je 0x5324
cmpq $0x0, (%rbx)
je 0x5339
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %r14, %rdi
movq %rbx, %rsi
callq 0x44d0
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x5331
jmp 0x5324
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_set_value
JSON_Status json_object_set_value(JSON_Object *object, const char *name, JSON_Value *value) {
    size_t i = 0;
    JSON_Value *old_value;
    if (object == NULL || name == NULL || value == NULL || value->parent != NULL) {
        return JSONFailure;
    }
    old_value = json_object_get_value(object, name);
    if (old_value != NULL) { /* free and overwrite old value */
        json_value_free(old_value);
        for (i = 0; i < json_object_get_count(object); i++) {
            if (strcmp(object->names[i], name) == 0) {
                value->parent = json_object_get_wrapping_value(object);
                object->values[i] = value;
                return JSONSuccess;
            }
        }
    }
    /* add new key value pair */
    return json_object_add(object, name, value);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
sete %al
testq %rsi, %rsi
sete %cl
orb %al, %cl
testq %rdx, %rdx
sete %al
orb %cl, %al
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jne 0x5380
movq %rdx, %rbx
cmpq $0x0, (%rdx)
je 0x538f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rsi, %r15
movq %rdi, %r14
callq 0x3936
testq %rax, %rax
je 0x53d0
movq %rax, %rdi
callq 0x3d65
movq 0x18(%r14), %r12
testq %r12, %r12
je 0x53d0
movq 0x8(%r14), %rbp
xorl %r13d, %r13d
movq (%rbp,%r13,8), %rdi
movq %r15, %rsi
callq 0x21f0
testl %eax, %eax
je 0x53ec
incq %r13
cmpq %r13, %r12
jne 0x53b7
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4530
movq (%r14), %rax
movq %rax, (%rbx)
movq 0x10(%r14), %rax
movq %rbx, (%rax,%r13,8)
xorl %eax, %eax
jmp 0x5380
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotset_value
JSON_Status json_object_dotset_value(JSON_Object *object, const char *name, JSON_Value *value) {
    const char *dot_pos = NULL;
    char *current_name = NULL;
    JSON_Object *temp_obj = NULL;
    JSON_Value *new_value = NULL;
    if (value == NULL || name == NULL || value == NULL) {
        return JSONFailure;
    }
    dot_pos = strchr(name, '.');
    if (dot_pos == NULL) {
        return json_object_set_value(object, name, value);
    } else {
        current_name = parson_strndup(name, dot_pos - name);
        temp_obj = json_object_get_object(object, current_name);
        if (temp_obj == NULL) {
            new_value = json_value_init_object();
            if (new_value == NULL) {
                parson_free(current_name);
                return JSONFailure;
            }
            if (json_object_add(object, current_name, new_value) == JSONFailure) {
                json_value_free(new_value);
                parson_free(current_name);
                return JSONFailure;
            }
            temp_obj = json_object_get_object(object, current_name);
        }
        parson_free(current_name);
        return json_object_dotset_value(temp_obj, dot_pos + 1, value);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r13
movq %rdi, %r15
testq %r13, %r13
je 0x5615
testq %rbx, %rbx
je 0x5615
movq %r13, %rdi
movl $0x2e, %esi
callq 0x2120
testq %rax, %rax
je 0x55e8
movq %rax, %r14
movq %rax, %rbp
subq %r13, %rbp
leaq 0x1(%rbp), %rdi
callq *0x4c41(%rip)           # 0xa190
testq %rax, %rax
je 0x556b
movq %rax, %r12
movb $0x0, (%rax,%rbp)
movq %rax, %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x2070
jmp 0x556e
xorl %r12d, %r12d
movq %r15, %rdi
movq %r12, %rsi
callq 0x3936
testq %rax, %rax
je 0x558a
cmpl $0x4, 0x8(%rax)
jne 0x558a
movq 0x10(%rax), %r13
jmp 0x558d
xorl %r13d, %r13d
testq %r13, %r13
jne 0x55d1
callq 0x3e18
testq %rax, %rax
je 0x560c
movq %rax, %r13
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x4530
cmpl $-0x1, %eax
je 0x5604
movq %r15, %rdi
movq %r12, %rsi
callq 0x3936
testq %rax, %rax
je 0x55ce
cmpl $0x4, 0x8(%rax)
jne 0x55ce
movq 0x10(%rax), %r13
jmp 0x55d1
xorl %r13d, %r13d
movq %r12, %rdi
callq *0x4bae(%rip)           # 0xa188
incq %r14
movq %r13, %r15
movq %r14, %r13
jmp 0x5514
movq %r15, %rdi
movq %r13, %rsi
movq %rbx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x534f
movq %r13, %rdi
callq 0x3d65
movq %r12, %rdi
callq *0x4b73(%rip)           # 0xa188
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotset_string
JSON_Status json_object_dotset_string(JSON_Object *object, const char *name, const char *string) {
    JSON_Value *value = json_value_init_string(string);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_object_dotset_value(object, name, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x3ed6
movq %rax, %rbx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x566d
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5500
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x566d
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotset_number
JSON_Status json_object_dotset_number(JSON_Object *object, const char *name, double number) {
    JSON_Value *value = json_value_init_number(number);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_object_dotset_value(object, name, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, 0x8(%rsp)
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x4afd(%rip)           # 0xa190
testq %rax, %rax
je 0x56b6
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x3, 0x8(%rax)
movsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x10(%rax)
jmp 0x56b8
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x56e6
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5500
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x56e6
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotset_boolean
JSON_Status json_object_dotset_boolean(JSON_Object *object, const char *name, int boolean) {
    JSON_Value *value = json_value_init_boolean(boolean);
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_object_dotset_value(object, name, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x4a86(%rip)           # 0xa190
testq %rax, %rax
je 0x572c
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x6, 0x8(%rax)
xorl %eax, %eax
testl %ebp, %ebp
setne %al
movl %eax, 0x10(%rbx)
jmp 0x572e
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x575c
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5500
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x575c
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotset_null
JSON_Status json_object_dotset_null(JSON_Object *object, const char *name) {
    JSON_Value *value = json_value_init_null();
    if (value == NULL) {
        return JSONFailure;
    }
    if (json_object_dotset_value(object, name, value) == JSONFailure) {
        json_value_free(value);
        return JSONFailure;
    }
    return JSONSuccess;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %r15
movl $0x18, %edi
callq *0x4a13(%rip)           # 0xa190
testq %rax, %rax
je 0x5795
movq %rax, %rbx
movq $0x0, (%rax)
movl $0x1, 0x8(%rax)
jmp 0x5797
xorl %ebx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x57c5
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5500
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x57c5
movq %rbx, %rdi
callq 0x3d65
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_remove
JSON_Status json_object_remove(JSON_Object *object, const char *name) {
    size_t i = 0, last_item_index = 0;
    if (object == NULL || json_object_get_value(object, name) == NULL) {
        return JSONFailure;
    }
    last_item_index = json_object_get_count(object) - 1;
    for (i = 0; i < json_object_get_count(object); i++) {
        if (strcmp(object->names[i], name) == 0) {
            parson_free(object->names[i]);
            json_value_free(object->values[i]);
            if (i != last_item_index) { /* Replace key value pair with one from the end */
                object->names[i] = object->names[last_item_index];
                object->values[i] = object->values[last_item_index];
            }
            object->count -= 1;
            return JSONSuccess;
        }
    }
    return JSONFailure; /* No execution path should end here */
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x5867
movq %rsi, %r14
movq %rdi, %rbx
callq 0x3936
testq %rax, %rax
je 0x5867
movq 0x18(%rbx), %r12
testq %r12, %r12
je 0x5867
movq 0x8(%rbx), %rbp
xorl %r13d, %r13d
movq (%rbp,%r13,8), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x21f0
testl %eax, %eax
je 0x5827
incq %r13
cmpq %r13, %r12
jne 0x5804
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
jmp 0x5867
movq %r15, %rdi
callq *0x4958(%rip)           # 0xa188
movq 0x10(%rbx), %rax
movq (%rax,%r13,8), %rdi
callq 0x3d65
leaq -0x1(%r12), %rax
cmpq %r13, %rax
je 0x5861
movq 0x8(%rbx), %rax
movq -0x8(%rax,%r12,8), %rcx
movq %rcx, (%rax,%r13,8)
movq 0x10(%rbx), %rax
movq -0x8(%rax,%r12,8), %rcx
movq %rcx, (%rax,%r13,8)
decq 0x18(%rbx)
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_dotremove
JSON_Status json_object_dotremove(JSON_Object *object, const char *name) {
    const char *dot_pos = strchr(name, '.');
    char *current_name = NULL;
    JSON_Object *temp_obj = NULL;
    if (dot_pos == NULL) {
        return json_object_remove(object, name);
    } else {
        current_name = parson_strndup(name, dot_pos - name);
        temp_obj = json_object_get_object(object, current_name);
        parson_free(current_name);
        if (temp_obj == NULL) {
            return JSONFailure;
        }
        return json_object_dotremove(temp_obj, dot_pos + 1);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r12
movq %rdi, %r14
movq %r12, %rdi
movl $0x2e, %esi
callq 0x2120
testq %rax, %rax
je 0x5901
movq %rax, %rbx
movq %rax, %r13
subq %r12, %r13
leaq 0x1(%r13), %rdi
callq *0x48e4(%rip)           # 0xa190
testq %rax, %rax
je 0x58c9
movq %rax, %r15
movb $0x0, (%rax,%r13)
movq %rax, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x2070
jmp 0x58cc
xorl %r15d, %r15d
movq %r14, %rdi
movq %r15, %rsi
callq 0x3936
testq %rax, %rax
je 0x58e8
cmpl $0x4, 0x8(%rax)
jne 0x58e8
movq 0x10(%rax), %r14
jmp 0x58eb
xorl %r14d, %r14d
movq %r15, %rdi
callq *0x4894(%rip)           # 0xa188
testq %r14, %r14
je 0x5915
incq %rbx
movq %rbx, %r12
jmp 0x5887
movq %r14, %rdi
movq %r12, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x57cb
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_clear
JSON_Status json_object_clear(JSON_Object *object) {
    size_t i = 0;
    if (object == NULL) {
        return JSONFailure;
    }
    for (i = 0; i < json_object_get_count(object); i++) {
        parson_free(object->names[i]);
        json_value_free(object->values[i]);
    }
    object->count = 0;
    return JSONSuccess;
}

// Assembly:
testq %rdi, %rdi
je 0x5970
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpq $0x0, 0x18(%rdi)
je 0x595e
xorl %r14d, %r14d
movq 0x8(%rbx), %rax
movq (%rax,%r14,8), %rdi
callq *0x4840(%rip)           # 0xa188
movq 0x10(%rbx), %rax
movq (%rax,%r14,8), %rdi
callq 0x3d65
incq %r14
cmpq 0x18(%rbx), %r14
jb 0x593a
movq $0x0, 0x18(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_object_resize
static JSON_Status json_object_resize(JSON_Object *object, size_t new_capacity) {
    char **temp_names = NULL;
    JSON_Value **temp_values = NULL;

    if ((object->names == NULL && object->values != NULL) ||
        (object->names != NULL && object->values == NULL) ||
        new_capacity == 0) {
            return JSONFailure; /* Shouldn't happen */
    }
    temp_names = (char**)parson_malloc(new_capacity * sizeof(char*));
    if (temp_names == NULL) {
        return JSONFailure;
    }
    temp_values = (JSON_Value**)parson_malloc(new_capacity * sizeof(JSON_Value*));
    if (temp_values == NULL) {
        parson_free(temp_names);
        return JSONFailure;
    }
    if (object->names != NULL && object->values != NULL && object->count > 0) {
        memcpy(temp_names, object->names, object->count * sizeof(char*));
        memcpy(temp_values, object->values, object->count * sizeof(JSON_Value*));
    }
    parson_free(object->names);
    parson_free(object->values);
    object->names = temp_names;
    object->values = temp_values;
    object->capacity = new_capacity;
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0x8(%rdi), %rax
testq %rax, %rax
je 0x61c3
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rbx, %rbx
je 0x61ec
cmpq $0x0, 0x10(%r14)
je 0x61ec
leaq (,%rbx,8), %r12
movq %r12, %rdi
callq *0x4050(%rip)           # 0xa190
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rax, %rax
je 0x61ec
movq %rax, %r15
movq %r12, %rdi
callq *0x4036(%rip)           # 0xa190
testq %rax, %rax
je 0x61e3
movq %rax, %r12
movq 0x8(%r14), %rsi
testq %rsi, %rsi
je 0x619f
cmpq $0x0, 0x10(%r14)
je 0x619f
movq 0x18(%r14), %rdx
testq %rdx, %rdx
je 0x619f
shlq $0x3, %rdx
movq %r15, %rdi
callq 0x2230
movq 0x10(%r14), %rsi
movq 0x18(%r14), %rdx
shlq $0x3, %rdx
movq %r12, %rdi
callq 0x2230
movq 0x8(%r14), %rdi
callq *0x3fdf(%rip)           # 0xa188
movq 0x10(%r14), %rdi
callq *0x3fd5(%rip)           # 0xa188
movq %r15, 0x8(%r14)
movq %r12, 0x10(%r14)
movq %rbx, 0x20(%r14)
xorl %ebp, %ebp
jmp 0x61ec
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpq $0x0, 0x10(%r14)
jne 0x61ec
testq %rax, %rax
jne 0x6116
testq %rbx, %rbx
jne 0x612f
jmp 0x61ec
movq %r15, %rdi
callq *0x3f9c(%rip)           # 0xa188
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: parse_utf16_hex
static int parse_utf16_hex(const char *s, unsigned int *result) {
    int x1, x2, x3, x4;
    if (s[0] == '\0' || s[1] == '\0' || s[2] == '\0' || s[3] == '\0') {
        return 0;
    }
    x1 = hex_char_to_int(s[0]);
    x2 = hex_char_to_int(s[1]);
    x3 = hex_char_to_int(s[2]);
    x4 = hex_char_to_int(s[3]);
    if (x1 == -1 || x2 == -1 || x3 == -1 || x4 == -1) {
        return 0;
    }
    *result = (unsigned int)((x1 << 12) | (x2 << 8) | (x3 << 4) | x4);
    return 1;
}

// Assembly:
movsbl (%rdi), %edx
xorl %eax, %eax
testl %edx, %edx
je 0x6334
movsbl 0x1(%rdi), %ecx
testl %ecx, %ecx
je 0x6334
movsbl 0x2(%rdi), %r8d
testl %r8d, %r8d
je 0x6334
movsbl 0x3(%rdi), %edi
testl %edi, %edi
je 0x6334
leal -0x30(%rdx), %r9d
cmpb $0x9, %r9b
ja 0x6239
addl $-0x30, %edx
jmp 0x6260
leal -0x61(%rdx), %r9d
cmpb $0x5, %r9b
ja 0x6248
addl $-0x57, %edx
jmp 0x6260
leal -0x41(%rdx), %r9d
addl $-0x37, %edx
cmpb $0x6, %r9b
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
cmovbl %edx, %r9d
movl %r9d, %edx
leal -0x30(%rcx), %r9d
cmpb $0x9, %r9b
ja 0x626f
addl $-0x30, %ecx
jmp 0x6296
leal -0x61(%rcx), %r9d
cmpb $0x5, %r9b
ja 0x627e
addl $-0x57, %ecx
jmp 0x6296
leal -0x41(%rcx), %r9d
addl $-0x37, %ecx
cmpb $0x6, %r9b
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
cmovbl %ecx, %r9d
movl %r9d, %ecx
leal -0x30(%r8), %r9d
cmpb $0x9, %r9b
ja 0x62a6
addl $-0x30, %r8d
jmp 0x62cf
leal -0x61(%r8), %r9d
cmpb $0x5, %r9b
ja 0x62b6
addl $-0x57, %r8d
jmp 0x62cf
leal -0x41(%r8), %r9d
addl $-0x37, %r8d
cmpb $0x6, %r9b
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
cmovbl %r8d, %r9d
movl %r9d, %r8d
leal -0x30(%rdi), %r9d
cmpb $0x9, %r9b
ja 0x62de
addl $-0x30, %edi
jmp 0x6305
leal -0x61(%rdi), %r9d
cmpb $0x5, %r9b
ja 0x62ed
addl $-0x57, %edi
jmp 0x6305
leal -0x41(%rdi), %r9d
addl $-0x37, %edi
cmpb $0x6, %r9b
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
cmovbl %edi, %r9d
movl %r9d, %edi
cmpl $-0x1, %edx
je 0x6334
cmpl $-0x1, %ecx
je 0x6334
cmpl $-0x1, %r8d
je 0x6334
cmpl $-0x1, %edi
je 0x6334
shll $0xc, %edx
shll $0x8, %ecx
orl %edx, %ecx
shll $0x4, %r8d
orl %edi, %r8d
orl %ecx, %r8d
movl %r8d, (%rsi)
movl $0x1, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: json_array_resize
static JSON_Status json_array_resize(JSON_Array *array, size_t new_capacity) {
    JSON_Value **new_items = NULL;
    if (new_capacity == 0) {
        return JSONFailure;
    }
    new_items = (JSON_Value**)parson_malloc(new_capacity * sizeof(JSON_Value*));
    if (new_items == NULL) {
        return JSONFailure;
    }
    if (array->items != NULL && array->count > 0) {
        memcpy(new_items, array->items, array->count * sizeof(JSON_Value*));
    }
    parson_free(array->items);
    array->items = new_items;
    array->capacity = new_capacity;
    return JSONSuccess;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rsi, %rsi
je 0x6394
movq %rsi, %rbx
movq %rdi, %r14
leaq (,%rsi,8), %rdi
callq *0x3e36(%rip)           # 0xa190
testq %rax, %rax
je 0x6394
movq %rax, %r15
movq 0x8(%r14), %rsi
testq %rsi, %rsi
je 0x6380
movq 0x10(%r14), %rdx
testq %rdx, %rdx
je 0x6380
shlq $0x3, %rdx
movq %r15, %rdi
callq 0x2230
movq 0x8(%r14), %rdi
callq *0x3dfe(%rip)           # 0xa188
movq %r15, 0x8(%r14)
movq %rbx, 0x18(%r14)
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/xapi-project[P]rrd-client-lib/parson/parson.c
// Function: append_indent
static int append_indent(char *buf, int level) {
    int i;
    int written = -1, written_total = 0;
    for (i = 0; i < level; i++) {
        APPEND_STRING("    ");
    }
    return written_total;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testl %esi, %esi
jle 0x63fa
movl %esi, %ebp
movq %rdi, %r14
xorl %ebx, %ebx
leaq 0x10ec(%rip), %r15      # 0x74c3
movq %r14, %rdi
movq %r15, %rsi
callq 0x63a1
testl %eax, %eax
js 0x63fe
movl %eax, %ecx
addq %r14, %rcx
testq %r14, %r14
cmovneq %rcx, %r14
addl %eax, %ebx
decl %ebp
jne 0x63d7
jmp 0x6403
xorl %ebx, %ebx
jmp 0x6403
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/desion[P]terminal/src/crc64.c
// Function: crc64
uint64_t crc64(uint8_t type, void *str, size_t len){
	uint64_t crc = crctab64[type];
	uint8_t *p = (uint8_t*)str;

	while (len--)
		crc = crctab64[(crc ^ *(p++)) & 0xff] ^ (crc >> 8);
	return crc;
}

// Assembly:
movl %edi, %eax
leaq 0x27db(%rip), %rcx      # 0x5010
movq (%rcx,%rax,8), %rax
testq %rdx, %rdx
je 0x285b
xorl %edi, %edi
movb (%rsi,%rdi), %r8b
xorb %al, %r8b
movzbl %r8b, %r8d
shrq $0x8, %rax
xorq (%rcx,%r8,8), %rax
incq %rdi
cmpq %rdi, %rdx
jne 0x2840
retq
// File: /workspace/github_c_makefile_star2_O1/desion[P]terminal/src/hdict.c
// Function: hdict_close
void hdict_close(hdict_t *hdict)
{
    if (hdict->fd > 0) close(hdict->fd);
    if (hdict->idx) free(hdict->idx);
    if (hdict->hdict_meta) free(hdict->hdict_meta);
    free(hdict->path);
    free(hdict);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl 0x38(%rdi), %edi
testl %edi, %edi
jle 0x2b11
callq 0x21a0
movq 0x30(%rbx), %rdi
testq %rdi, %rdi
je 0x2b1f
callq 0x2030
movq 0x58(%rbx), %rdi
testq %rdi, %rdi
je 0x2b2d
callq 0x2030
movq 0x20(%rbx), %rdi
callq 0x2030
movq %rbx, %rdi
popq %rbx
jmp 0x2030
// File: /workspace/github_c_makefile_star2_O1/desion[P]terminal/src/hdict.c
// Function: hdict_seek
int hdict_seek(hdict_t *hdict, const char* str_key, off_t *off, uint32_t *length)
{
    uint32_t low = 0;
    uint32_t high = hdict->idx_num;
    uint32_t mid;
    int hit = 0;
    int count = 0;
    uint64_t key = strtoull(str_key, NULL, 10);
    while (low < high) {
        ++count;
        mid = (low + high) / 2;
        if (hdict->idx[mid].key > key) {
            high = mid;
        } else if (hdict->idx[mid].key < key) {
            low = mid + 1;
        } else {
            *off = (hdict->idx[mid].pos & 0xFFFFFFFFFF);
            *length = (hdict->idx[mid].pos >> 40);
            hit = 1;
            break;
        }
    }
    return hit;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r14
movq %rdi, %r12
movl 0x28(%rdi), %r13d
xorl %r15d, %r15d
movq %rsi, %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x2200
testl %r13d, %r13d
je 0x2bc1
movq 0x30(%r12), %rcx
xorl %edx, %edx
leal (%rdx,%r13), %esi
shrl %esi
movq %rsi, %rdi
shlq $0x4, %rdi
leaq (%rcx,%rdi), %r8
cmpq %rax, (%rcx,%rdi)
jbe 0x2b8f
movl %esi, %r13d
jmp 0x2b95
jae 0x2b9f
incl %esi
movl %esi, %edx
cmpl %r13d, %edx
jb 0x2b73
xorl %r15d, %r15d
jmp 0x2bc1
movabsq $0xffffffffff, %rax     # imm = 0xFFFFFFFFFF
andq 0x8(%r8), %rax
movq %rax, (%r14)
movq 0x8(%rcx,%rdi), %rax
shrq $0x28, %rax
movl %eax, (%rbx)
movl $0x1, %r15d
movl %r15d, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq