LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_calendar.c
// Function: get_month_length
static uint8_t get_month_length(int32_t year, int32_t month)
{
    month--; /*Range of months id [1..12] but range of indexes is [0..11]*/
    if(month < 0) {
        year--;             /*Already in the previous year (won't be less then -12 to skip a whole year)*/
        month = 12 + month; /*`month` is negative, the result will be < 12*/
    }
    if(month >= 12) {
        year++;
        month -= 12;
    }

    /*month == 1 is february*/
    return (month == 1) ? (28 + is_leap_year(year)) : 31 - month % 7 % 2;
}

// Assembly:
xorl %edx, %edx
xorl %eax, %eax
testl %esi, %esi
setg %dl
setle %r8b
negl %edx
orl $0xb, %edx
leal (%rdx,%rsi), %r10d
xorl %ecx, %ecx
cmpl $0xc, %r10d
setge %r9b
leal -0xc(%rdx,%rsi), %edx
cmovll %r10d, %edx
cmpl $0x1, %edx
jne 0x14ef5
movb %r8b, %al
subl %eax, %edi
movb %r9b, %cl
addl %edi, %ecx
movb $0x1c, %al
testb $0x3, %cl
je 0x14f2d
retq
movslq %edx, %rax
imulq $-0x6db6db6d, %rax, %rcx # imm = 0x92492493
shrq $0x20, %rcx
addl %edx, %ecx
movl %ecx, %eax
shrl $0x1f, %eax
sarl $0x2, %ecx
addl %eax, %ecx
leal (,%rcx,8), %eax
subl %eax, %ecx
addl %edx, %ecx
movl %ecx, %eax
shrl $0x1f, %eax
addl %ecx, %eax
andl $0xfe, %eax
subl %eax, %ecx
movb $0x1f, %al
subb %cl, %al
retq
imull $0xc28f5c29, %ecx, %ecx # imm = 0xC28F5C29
movl %ecx, %edx
rorl $0x2, %edx
movb $0x1d, %al
cmpl $0x28f5c28, %edx        # imm = 0x28F5C28
ja 0x14ef4
rorl $0x4, %ecx
cmpl $0xa3d70b, %ecx         # imm = 0xA3D70B
setb %al
orb $0x1c, %al
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_calendar.c
// Function: is_highlighted
static bool is_highlighted(lv_obj_t * calendar, int32_t year, int32_t month, int32_t day)
{
    lv_calendar_ext_t * ext = lv_obj_get_ext_attr(calendar);

    if(ext->highlighted_dates == NULL || ext->highlighted_dates_num == 0) return false;

    uint32_t i;
    for(i = 0; i < ext->highlighted_dates_num; i++) {
        if(ext->highlighted_dates[i].year == year && ext->highlighted_dates[i].month == month &&
           ext->highlighted_dates[i].day == day) {
            return true;
        }
    }

    return false;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %ecx, %ebx
movl %edx, %ebp
movl %esi, %r14d
callq 0x6ad8
movq 0x8(%rax), %rcx
testq %rcx, %rcx
je 0x14f9d
movzwl 0x12(%rax), %eax
testq %rax, %rax
je 0x14f9d
xorl %edx, %edx
movzwl (%rcx,%rdx,4), %esi
cmpl %r14d, %esi
jne 0x14f90
movsbl 0x2(%rcx,%rdx,4), %esi
cmpl %ebp, %esi
jne 0x14f90
movsbl 0x3(%rcx,%rdx,4), %esi
cmpl %ebx, %esi
je 0x14fa4
incq %rdx
cmpq %rdx, %rax
jne 0x14f75
seta %al
jmp 0x14f9f
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
movb $0x1, %al
jmp 0x14f9f
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_signal
static lv_res_t lv_chart_signal(lv_obj_t * chart, lv_signal_t sign, void * param)
{
    /* Include the ancient signal function */
    lv_res_t res;
    res = ancestor_signal(chart, sign, param);
    if(res != LV_RES_OK) return res;
    if(sign == LV_SIGNAL_GET_TYPE) return lv_obj_handle_get_type_signal(param, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);

    if(sign == LV_SIGNAL_CLEANUP) {
        lv_coord_t ** datal;
        LV_LL_READ(ext->series_ll, datal)
        {
            lv_mem_free(*datal);
        }
        lv_ll_clear(&ext->series_ll);
    } else if(sign == LV_SIGNAL_REFR_EXT_DRAW_PAD) {
        /*Provide extra px draw area around the chart*/
        chart->ext_draw_pad = ext->margin;
    }

    return res;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r15
callq *0x4b1d5(%rip)          # 0x60388
movl %eax, %ebx
cmpb $0x1, %al
jne 0x15230
cmpb $0x7, %bpl
jne 0x151d8
leaq 0x2a521(%rip), %rsi     # 0x3f6e7
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x6bf5
movq %r15, %rdi
callq 0x6ad8
movq %rax, %r14
cmpb $0x6, %bpl
je 0x15226
movzbl %bpl, %eax
testl %eax, %eax
jne 0x15230
movq %r14, %rdi
callq 0x29cce
testq %rax, %rax
je 0x1521c
movq %rax, %r15
movq (%r15), %rdi
callq 0x29984
movq %r14, %rdi
movq %r15, %rsi
callq 0x29dfb
movq %rax, %r15
testq %rax, %rax
jne 0x15201
movq %r14, %rdi
callq 0x29e18
jmp 0x15230
movzwl 0x58(%r14), %eax
movw %ax, 0x5c(%r15)
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_add_series
lv_chart_series_t * lv_chart_add_series(lv_obj_t * chart, lv_color_t color)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext    = lv_obj_get_ext_attr(chart);
    lv_chart_series_t * ser = lv_ll_ins_head(&ext->series_ll);
    LV_ASSERT_MEM(ser);
    if(ser == NULL) return NULL;

    lv_coord_t def = LV_CHART_POINT_DEF;

    if(ser == NULL) return NULL;

    ser->color  = color;
    ser->points = lv_mem_alloc(sizeof(lv_coord_t) * ext->point_cnt);
    LV_ASSERT_MEM(ser->points);
    if(ser->points == NULL) {
        lv_ll_rem(&ext->series_ll, ser);
        lv_mem_free(ser);
        return NULL;
    }

    ser->start_point = 0;

    uint16_t i;
    lv_coord_t * p_tmp = ser->points;
    for(i = 0; i < ext->point_cnt; i++) {
        *p_tmp = def;
        p_tmp++;
    }

    ext->series.num++;

    return ser;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16097
movq %rbx, %rdi
callq 0x6ad8
movq %rax, %r14
movq %rax, %rdi
callq 0x29c08
movq %rax, %rbx
movq %rax, %rdi
callq 0x80d4
testb %al, %al
je 0x160a8
testq %rbx, %rbx
je 0x160da
movw %bp, 0x8(%rbx)
movzwl 0x1e(%r14), %edi
addl %edi, %edi
callq 0x298d9
movq %rax, (%rbx)
movq %rax, %rdi
callq 0x80d4
movq (%rbx), %rsi
testb %al, %al
je 0x160b9
testq %rsi, %rsi
je 0x160c7
movw $0x0, 0xa(%rbx)
cmpw $0x0, 0x1e(%r14)
je 0x16091
xorl %eax, %eax
movw $0x83e8, (%rsi,%rax,2)  # imm = 0x83E8
incq %rax
cmpw 0x1e(%r14), %ax
jb 0x16081
incb 0x5e(%r14)
jmp 0x160dc
leaq 0x29096(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x160a6
leaq 0x28f91(%rip), %rdi     # 0x3f040
movq %rbx, %rsi
callq 0x829e
jmp 0x160b7
leaq 0x28f80(%rip), %rdi     # 0x3f040
callq 0x829e
jmp 0x160c5
movq %r14, %rdi
movq %rbx, %rsi
callq 0x29d38
movq %rbx, %rdi
callq 0x29984
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_clear_serie
void lv_chart_clear_serie(lv_obj_t * chart, lv_chart_series_t * serie)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(serie);

    if(chart == NULL || serie == NULL) return;
    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext == NULL) return;

    uint32_t i;
    for(i = 0; i < ext->point_cnt; i++) {
        serie->points[i] = LV_CHART_POINT_DEF;
    }

    serie->start_point = 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x1614c
movq %rbx, %rdi
callq 0x80d4
testb %al, %al
je 0x1615d
testq %r14, %r14
sete %al
testq %rbx, %rbx
sete %cl
orb %al, %cl
jne 0x16144
movq %r14, %rdi
callq 0x6ad8
testq %rax, %rax
je 0x16144
cmpw $0x0, 0x1e(%rax)
je 0x1613e
movq (%rbx), %rcx
xorl %edx, %edx
movw $0x83e8, (%rcx,%rdx,2)  # imm = 0x83E8
incq %rdx
movzwl 0x1e(%rax), %esi
cmpq %rsi, %rdx
jb 0x1612c
movw $0x0, 0xa(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x28fe1(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x1615b
leaq 0x28fd0(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x1616c
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_div_line_count
void lv_chart_set_div_line_count(lv_obj_t * chart, uint8_t hdiv, uint8_t vdiv)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->hdiv_cnt == hdiv && ext->vdiv_cnt == vdiv) return;

    ext->hdiv_cnt = hdiv;
    ext->vdiv_cnt = vdiv;

    lv_obj_invalidate(chart);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movl %esi, %r14d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x1619c
movq %rbx, %rdi
callq 0x6ad8
cmpb %r14b, 0x1c(%rax)
jne 0x161ad
cmpb %bpl, 0x1d(%rax)
jne 0x161ad
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x28f91(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x161ab
movb %r14b, 0x1c(%rax)
movb %bpl, 0x1d(%rax)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_range
void lv_chart_set_range(lv_obj_t * chart, lv_coord_t ymin, lv_coord_t ymax)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->ymin == ymin && ext->ymax == ymax) return;

    ext->ymin = ymin;
    ext->ymax = ymax;

    lv_chart_refresh(chart);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movl %esi, %r14d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x161f0
movq %rbx, %rdi
callq 0x6ad8
cmpw %r14w, 0x18(%rax)
jne 0x16201
cmpw %bp, 0x1a(%rax)
jne 0x16201
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x28f3d(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x161ff
movw %r14w, 0x18(%rax)
movw %bp, 0x1a(%rax)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x16216
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_type
void lv_chart_set_type(lv_obj_t * chart, lv_chart_type_t type)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->type == type) return;

    ext->type = type;

    lv_chart_refresh(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16263
movq %rbx, %rdi
callq 0x6ad8
cmpb %bpl, 0x20(%rax)
jne 0x16274
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x28eca(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16272
movb %bpl, 0x20(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x16216
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_series_opa
void lv_chart_set_series_opa(lv_obj_t * chart, lv_opa_t opa)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->series.opa == opa) return;

    ext->series.opa = opa;
    lv_obj_invalidate(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x164b8
movq %rbx, %rdi
callq 0x6ad8
cmpb %bpl, 0x5f(%rax)
jne 0x164c9
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x28c75(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x164c7
movb %bpl, 0x5f(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_series_width
void lv_chart_set_series_width(lv_obj_t * chart, lv_coord_t width)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->series.width == width) return;

    ext->series.width = width;
    lv_obj_invalidate(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16501
movq %rbx, %rdi
callq 0x6ad8
cmpw %bp, 0x5c(%rax)
jne 0x16512
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x28c2c(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16510
movw %bp, 0x5c(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_series_darking
void lv_chart_set_series_darking(lv_obj_t * chart, lv_opa_t dark_eff)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->series.dark == dark_eff) return;

    ext->series.dark = dark_eff;
    lv_obj_invalidate(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x1654a
movq %rbx, %rdi
callq 0x6ad8
cmpb %bpl, 0x60(%rax)
jne 0x1655b
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x28be3(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16559
movb %bpl, 0x60(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_init_points
void lv_chart_init_points(lv_obj_t * chart, lv_chart_series_t * ser, lv_coord_t y)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(ser);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    uint16_t i;
    for(i = 0; i < ext->point_cnt; i++) {
        ser->points[i] = y;
    }
    ser->start_point = 0;
    lv_chart_refresh(chart);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x165c5
movq %r14, %rdi
callq 0x80d4
testb %al, %al
je 0x165d6
movq %rbx, %rdi
callq 0x6ad8
cmpw $0x0, 0x1e(%rax)
je 0x165b2
movq (%r14), %rcx
xorl %edx, %edx
movw %bp, (%rcx,%rdx,2)
incq %rdx
movzwl 0x1e(%rax), %esi
cmpq %rsi, %rdx
jb 0x165a2
movw $0x0, 0xa(%r14)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x16216
leaq 0x28b68(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x165d4
leaq 0x28b57(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x165e5
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_points
void lv_chart_set_points(lv_obj_t * chart, lv_chart_series_t * ser, lv_coord_t y_array[])
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(ser);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    memcpy(ser->points, y_array, ext->point_cnt * (sizeof(lv_coord_t)));
    ser->start_point = 0;
    lv_chart_refresh(chart);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16637
movq %r14, %rdi
callq 0x80d4
testb %al, %al
je 0x16648
movq %rbx, %rdi
callq 0x6ad8
movq (%r14), %rdi
movzwl 0x1e(%rax), %edx
addl %edx, %edx
movq %r15, %rsi
callq 0x20f0
movw $0x0, 0xa(%r14)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x16216
leaq 0x28af6(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16646
leaq 0x28ae5(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x16657
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_inv_lines
static void lv_chart_inv_lines(lv_obj_t * chart, uint16_t i)
{
    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);

    lv_coord_t w     = lv_obj_get_width(chart);
    lv_coord_t x_ofs = chart->coords.x1;

    if(i < ext->point_cnt) {
        lv_area_t coords;
        lv_obj_get_coords(chart, &coords);
        if(i < ext->point_cnt - 1) {
            coords.x1 = ((w * i) / (ext->point_cnt - 1)) + x_ofs - ext->series.width;
            coords.x2 = ((w * (i + 1)) / (ext->point_cnt - 1)) + x_ofs + ext->series.width;
            lv_inv_area(lv_obj_get_disp(chart), &coords);
        }

        if(i > 0) {
            coords.x1 = ((w * (i - 1)) / (ext->point_cnt - 1)) + x_ofs - ext->series.width;
            coords.x2 = ((w * i) / (ext->point_cnt - 1)) + x_ofs + ext->series.width;
            lv_inv_area(lv_obj_get_disp(chart), &coords);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
callq 0x6ad8
movq %rax, %r15
movq %rbx, %rdi
callq 0x5651
cmpw %r14w, 0x1e(%r15)
jbe 0x16928
movl %eax, %ebp
movzwl 0x20(%rbx), %r13d
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x5427
movzwl 0x1e(%r15), %ecx
decl %ecx
movswl %bp, %ebp
cmpl %r14d, %ecx
jle 0x168db
movl %ebp, %eax
imull %r14d, %eax
cltd
idivl %ecx
movl 0x5c(%r15), %esi
addl %r13d, %eax
subl %esi, %eax
movq %rsp, %r12
movw %ax, (%r12)
leal 0x1(%r14), %eax
imull %ebp, %eax
cltd
idivl %ecx
addl %r13d, %esi
addl %eax, %esi
movw %si, 0x4(%r12)
movq %rbx, %rdi
callq 0x5033
movq %rax, %rdi
movq %r12, %rsi
callq 0x7184
testw %r14w, %r14w
je 0x16928
leal -0x1(%r14), %eax
imull %ebp, %eax
movzwl 0x1e(%r15), %ecx
decl %ecx
cltd
idivl %ecx
movl 0x5c(%r15), %esi
addl %r13d, %eax
subl %esi, %eax
movq %rsp, %r15
movw %ax, (%r15)
imull %r14d, %ebp
movl %ebp, %eax
cltd
idivl %ecx
addl %r13d, %esi
addl %eax, %esi
movw %si, 0x4(%r15)
movq %rbx, %rdi
callq 0x5033
movq %rax, %rdi
movq %r15, %rsi
callq 0x7184
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_update_mode
void lv_chart_set_update_mode(lv_obj_t * chart, lv_chart_update_mode_t update_mode)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    if(ext->update_mode == update_mode) return;

    ext->update_mode = update_mode;
    lv_obj_invalidate(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16964
movq %rbx, %rdi
callq 0x6ad8
movb 0x5a(%rax), %cl
movl %ecx, %edx
andb $0x1, %dl
cmpb %bpl, %dl
jne 0x16975
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x287c9(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16973
andb $0x1, %bpl
andb $-0x2, %cl
orb %bpl, %cl
movb %cl, 0x5a(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_x_tick_length
void lv_chart_set_x_tick_length(lv_obj_t * chart, uint8_t major_tick_len, uint8_t minor_tick_len)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->x_axis.major_tick_len = major_tick_len;
    ext->x_axis.minor_tick_len = minor_tick_len;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x169b8
movq %r14, %rdi
callq 0x6ad8
movb %bpl, 0x42(%rax)
movb %bl, 0x43(%rax)
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x28775(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x169c7
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_y_tick_length
void lv_chart_set_y_tick_length(lv_obj_t * chart, uint8_t major_tick_len, uint8_t minor_tick_len)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->y_axis.major_tick_len = major_tick_len;
    ext->y_axis.minor_tick_len = minor_tick_len;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x169f1
movq %r14, %rdi
callq 0x6ad8
movb %bpl, 0x32(%rax)
movb %bl, 0x33(%rax)
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x2873c(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x16a00
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_secondary_y_tick_length
void lv_chart_set_secondary_y_tick_length(lv_obj_t * chart, uint8_t major_tick_len, uint8_t minor_tick_len)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->secondary_y_axis.major_tick_len = major_tick_len;
    ext->secondary_y_axis.minor_tick_len = minor_tick_len;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x16a2a
movq %r14, %rdi
callq 0x6ad8
movb %bpl, 0x52(%rax)
movb %bl, 0x53(%rax)
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x28703(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x16a39
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_x_tick_texts
void lv_chart_set_x_tick_texts(lv_obj_t * chart, const char * list_of_values, uint8_t num_tick_marks,
                               lv_chart_axis_options_t options)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(list_of_values);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->x_axis.num_tick_marks = num_tick_marks;
    ext->x_axis.list_of_values = list_of_values;
    ext->x_axis.options        = options;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %rbx
movq %rdi, %r15
callq 0x80d4
testb %al, %al
je 0x16a81
movq %rbx, %rdi
callq 0x80d4
testb %al, %al
je 0x16a92
movq %r15, %rdi
callq 0x6ad8
movb %r14b, 0x41(%rax)
movq %rbx, 0x38(%rax)
movb %bpl, 0x40(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x286ac(%rip), %rdi     # 0x3f134
movq %r15, %rsi
callq 0x829e
jmp 0x16a90
leaq 0x2869b(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16aa1
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_y_tick_texts
void lv_chart_set_y_tick_texts(lv_obj_t * chart, const char * list_of_values, uint8_t num_tick_marks,
                               lv_chart_axis_options_t options)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(list_of_values);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->y_axis.num_tick_marks = num_tick_marks;
    ext->y_axis.list_of_values = list_of_values;
    ext->y_axis.options        = options;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %rbx
movq %rdi, %r15
callq 0x80d4
testb %al, %al
je 0x16ae9
movq %rbx, %rdi
callq 0x80d4
testb %al, %al
je 0x16afa
movq %r15, %rdi
callq 0x6ad8
movb %r14b, 0x31(%rax)
movq %rbx, 0x28(%rax)
movb %bpl, 0x30(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x28644(%rip), %rdi     # 0x3f134
movq %r15, %rsi
callq 0x829e
jmp 0x16af8
leaq 0x28633(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16b09
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_secondary_y_tick_texts
void lv_chart_set_secondary_y_tick_texts(lv_obj_t * chart, const char * list_of_values, uint8_t num_tick_marks,
                                        lv_chart_axis_options_t options)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);
    LV_ASSERT_NULL(list_of_values);

    lv_chart_ext_t * ext       = lv_obj_get_ext_attr(chart);
    ext->secondary_y_axis.num_tick_marks = num_tick_marks;
    ext->secondary_y_axis.list_of_values = list_of_values;
    ext->secondary_y_axis.options        = options;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %rbx
movq %rdi, %r15
callq 0x80d4
testb %al, %al
je 0x16b51
movq %rbx, %rdi
callq 0x80d4
testb %al, %al
je 0x16b62
movq %r15, %rdi
callq 0x6ad8
movb %r14b, 0x51(%rax)
movq %rbx, 0x48(%rax)
movb %bpl, 0x50(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x285dc(%rip), %rdi     # 0x3f134
movq %r15, %rsi
callq 0x829e
jmp 0x16b60
leaq 0x285cb(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16b71
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_set_margin
void lv_chart_set_margin(lv_obj_t * chart, uint16_t margin)
{
    LV_ASSERT_OBJ(chart, LV_OBJX_NAME);

    lv_chart_ext_t * ext = lv_obj_get_ext_attr(chart);
    ext->margin          = margin;
    lv_obj_refresh_ext_draw_pad(chart);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x16b9e
movq %rbx, %rdi
callq 0x6ad8
movw %bp, 0x58(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x64f5
leaq 0x2858f(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x16bad
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_chart.c
// Function: lv_chart_get_next_label
static void lv_chart_get_next_label(lv_chart_label_iterator_t * iterator, char * buf)
{
    uint8_t label_len = 0;
    if (iterator->is_reverse_iter) {
        const char * label_start;
        /* count the length of the current label*/
        while ((*iterator->current_pos != '\n') &&
                (iterator->current_pos != iterator->list_start)) {
            iterator->current_pos--;
            label_len++;
        }

        label_start = iterator->current_pos;

        if (*iterator->current_pos == '\n') {
            /* do not copy \n symbol, +1 to skip it*/
            label_start++;
            /* skip newline*/
            iterator->current_pos--;
        } else {
            /* it is last label in list (first one from the beginning )*/
            label_len++;
        }

        /* do not allow output buffer overflow */
        if (label_len > LV_CHART_AXIS_TICK_LABEL_MAX_LEN) {
            label_len = LV_CHART_AXIS_TICK_LABEL_MAX_LEN;
        }

        strncpy(buf, label_start, label_len);
    } else {
        /* search for tick string */
        while(iterator->current_pos[label_len] != '\n' &&
            iterator->current_pos[label_len] != '\0') {
            /* do not overflow the buffer, but move to the end of the current label */
            if(label_len < LV_CHART_AXIS_TICK_LABEL_MAX_LEN) {
                buf[label_len] = iterator->current_pos[label_len];
                label_len++;
            } else {
                label_len++;
            }
        }

        iterator->current_pos += label_len;

        /* do not allow output buffer overflow */
        if (label_len > LV_CHART_AXIS_TICK_LABEL_MAX_LEN) {
            label_len = LV_CHART_AXIS_TICK_LABEL_MAX_LEN;
        }

        if(*iterator->current_pos == '\n') iterator->current_pos++;
    }

    /* terminate the string */
    buf[label_len] = '\0';
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
cmpb $0x0, 0x11(%rdi)
je 0x17269
movq 0x8(%rdi), %rax
cmpb $0xa, (%rax)
sete %r8b
jne 0x172ab
xorl %ecx, %ecx
jmp 0x172f0
xorl %eax, %eax
movq 0x8(%rdi), %rcx
movzbl %al, %eax
movzbl (%rcx,%rax), %edx
testl %edx, %edx
je 0x1728a
cmpl $0xa, %edx
je 0x1728a
cmpb $0x13, %al
ja 0x17286
movb %dl, (%rbx,%rax)
incb %al
jmp 0x1726b
leaq (%rcx,%rax), %rdx
movq %rdx, 0x8(%rdi)
cmpb $0x14, %al
movl $0x14, %ebp
cmovbl %eax, %ebp
cmpb $0xa, (%rcx,%rax)
jne 0x17314
incq %rdx
movq %rdx, 0x8(%rdi)
jmp 0x17314
movq (%rdi), %rdx
movq %rax, %rsi
cmpq %rdx, %rax
je 0x172db
leaq -0x1(%rax), %r9
movb $0x1, %cl
movq %r9, 0x8(%rdi)
cmpb $0xa, (%r9)
sete %r8b
je 0x172ed
leaq -0x1(%r9), %rsi
incb %cl
cmpq %rdx, %r9
movq %rsi, %r9
jne 0x172bc
incq %rsi
movl %eax, %ecx
subb %dl, %cl
testb %r8b, %r8b
je 0x172e9
movq %rsi, %rax
jmp 0x172f0
incb %cl
jmp 0x172fb
movq %r9, %rax
leaq 0x1(%rax), %rsi
decq %rax
movq %rax, 0x8(%rdi)
movzbl %cl, %eax
cmpb $0x14, %al
movl $0x14, %ebp
cmovbl %eax, %ebp
movzbl %bpl, %edx
movq %rbx, %rdi
callq 0x2030
movzbl %bpl, %eax
movb $0x0, (%rbx,%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_create
lv_obj_t * lv_canvas_create(lv_obj_t * par, const lv_obj_t * copy)
{
    LV_LOG_TRACE("canvas create started");

    /*Create the ancestor of canvas*/
    lv_obj_t * new_canvas = lv_img_create(par, copy);
    LV_ASSERT_MEM(new_canvas);
    if(new_canvas == NULL) return NULL;

    /*Allocate the canvas type specific extended data*/
    lv_canvas_ext_t * ext = lv_obj_allocate_ext_attr(new_canvas, sizeof(lv_canvas_ext_t));
    LV_ASSERT_MEM(ext);
    if(ext == NULL) return NULL;
    if(ancestor_signal == NULL) ancestor_signal = lv_obj_get_signal_cb(new_canvas);
    if(ancestor_design == NULL) ancestor_design = lv_obj_get_design_cb(new_canvas);

    /*Initialize the allocated 'ext' */
    ext->dsc.header.always_zero = 0;
    ext->dsc.header.cf          = LV_IMG_CF_TRUE_COLOR;
    ext->dsc.header.h           = 0;
    ext->dsc.header.w           = 0;
    ext->dsc.data_size          = 0;
    ext->dsc.data               = NULL;

    lv_img_set_src(new_canvas, &ext->dsc);

    /*The signal and design functions are not copied so set them here*/
    lv_obj_set_signal_cb(new_canvas, lv_canvas_signal);

    /*Init the new canvas canvas*/
    if(copy == NULL) {

    }
    /*Copy an existing canvas*/
    else {
        /*Refresh the style with new signal function*/
        lv_obj_refresh_style(new_canvas);
    }

    LV_LOG_INFO("canvas created");

    return new_canvas;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
callq 0x2350c
movq %rax, %rbx
movq %rax, %rdi
callq 0x80d4
testb %al, %al
je 0x173f5
testq %rbx, %rbx
je 0x17406
movq %rbx, %rdi
movl $0x28, %esi
callq 0x64bc
movq %rax, %r15
movq %rax, %rdi
callq 0x80d4
testb %al, %al
je 0x17411
testq %r15, %r15
je 0x17406
cmpq $0x0, 0x49012(%rip)     # 0x60390
jne 0x1738f
movq %rbx, %rdi
callq 0x6a6c
movq %rax, 0x49001(%rip)     # 0x60390
cmpq $0x0, 0x49001(%rip)     # 0x60398
jne 0x173a8
movq %rbx, %rdi
callq 0x6a90
movq %rax, 0x48ff0(%rip)     # 0x60398
movq %r15, %rsi
addq $0x18, %rsi
movl $0x300, %eax            # imm = 0x300
andl 0x18(%r15), %eax
orl $0x4, %eax
movl %eax, 0x18(%r15)
movl $0x0, 0x1c(%r15)
movq $0x0, 0x20(%r15)
movq %rbx, %rdi
callq 0x23916
leaq 0x44(%rip), %rsi        # 0x17422
movq %rbx, %rdi
callq 0x645c
testq %r14, %r14
je 0x17408
movq %rbx, %rdi
callq 0x5e38
jmp 0x17408
leaq 0x27c44(%rip), %rdi     # 0x3f040
movq %rbx, %rsi
callq 0x829e
jmp 0x17404
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
leaq 0x27c28(%rip), %rdi     # 0x3f040
movq %r15, %rsi
callq 0x829e
jmp 0x17420
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_set_buffer
void lv_canvas_set_buffer(lv_obj_t * canvas, void * buf, lv_coord_t w, lv_coord_t h, lv_img_cf_t cf)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);
    LV_ASSERT_NULL(buf);

    lv_canvas_ext_t * ext = lv_obj_get_ext_attr(canvas);

    ext->dsc.header.cf = cf;
    ext->dsc.header.w  = w;
    ext->dsc.header.h  = h;
    ext->dsc.data      = buf;
    ext->dsc.data_size = (lv_img_color_format_get_px_size(cf) * w * h) / 8;

    lv_img_set_src(canvas, &ext->dsc);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebp
movl %ecx, %r13d
movl %edx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x17520
movq %r14, %rdi
callq 0x80d4
testb %al, %al
je 0x17531
movq %rbx, %rdi
callq 0x6ad8
movq %rax, %r12
addq $0x18, %rax
movq %rax, (%rsp)
movl %ebp, %eax
andb $0x1f, %al
movzbl %al, %eax
movl $0x3e0, %ecx            # imm = 0x3E0
andl 0x18(%r12), %ecx
movswl %r15w, %r15d
movl %r15d, %edx
shll $0xa, %edx
movswl %r13w, %r13d
movl %r13d, %esi
shll $0x15, %esi
andl $0x1ffc00, %edx         # imm = 0x1FFC00
orl %esi, %edx
orl %eax, %edx
orl %ecx, %edx
movl %edx, 0x18(%r12)
movq %r14, 0x20(%r12)
movzbl %bpl, %edi
callq 0x3bfce
movzbl %al, %eax
imull %r15d, %r13d
imull %eax, %r13d
leal 0x7(%r13), %eax
testl %r13d, %r13d
cmovnsl %r13d, %eax
sarl $0x3, %eax
movl %eax, 0x1c(%r12)
movq %rbx, %rdi
movq (%rsp), %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x23916
leaq 0x27c0d(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x1752f
leaq 0x27bfc(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x17540
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_set_px
void lv_canvas_set_px(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y, lv_color_t c)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);

    lv_canvas_ext_t * ext = lv_obj_get_ext_attr(canvas);

    lv_img_buf_set_px_color(&ext->dsc, x, y, c);
    lv_obj_invalidate(canvas);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r15d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x1758a
movq %rbx, %rdi
callq 0x6ad8
leaq 0x18(%rax), %rdi
movswl %r15w, %esi
movswl %r14w, %edx
movl %ebp, %ecx
callq 0x3c106
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x4c36
leaq 0x27ba3(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x17599
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_set_palette
void lv_canvas_set_palette(lv_obj_t * canvas, uint8_t id, lv_color_t c)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);

    lv_canvas_ext_t * ext = lv_obj_get_ext_attr(canvas);

    lv_img_buf_set_palette(&ext->dsc, id, c);
    lv_obj_invalidate(canvas);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movl %esi, %r14d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x175d3
movq %rbx, %rdi
callq 0x6ad8
leaq 0x18(%rax), %rdi
movzbl %r14b, %esi
movl %ebp, %edx
callq 0x3c3de
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x4c36
leaq 0x27b5a(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x175e2
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_get_px
lv_color_t lv_canvas_get_px(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);

    lv_canvas_ext_t * ext    = lv_obj_get_ext_attr(canvas);
    const lv_style_t * style = lv_canvas_get_style(canvas, LV_CANVAS_STYLE_MAIN);

    return lv_img_buf_get_px_color(&ext->dsc, x, y, style);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x1766e
movq %r14, %rdi
callq 0x6ad8
movq %rax, %r15
movq %r14, %rdi
xorl %esi, %esi
callq 0x1767f
addq $0x18, %r15
movswl %bp, %esi
movswl %bx, %edx
movq %r15, %rdi
movq %rax, %rcx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x3be97
leaq 0x27abf(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x1767d
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_get_style
const lv_style_t * lv_canvas_get_style(const lv_obj_t * canvas, lv_canvas_style_t type)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);

    const lv_style_t * style = NULL;

    switch(type) {
        case LV_CANVAS_STYLE_MAIN: style = lv_img_get_style(canvas, LV_IMG_STYLE_MAIN); break;
        default: style = NULL;
    }

    return style;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x1769e
testb %bpl, %bpl
je 0x176af
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x27a8f(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x176ad
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x6697
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_copy_buf
void lv_canvas_copy_buf(lv_obj_t * canvas, const void * to_copy, lv_coord_t x, lv_coord_t y, lv_coord_t w, lv_coord_t h)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);
    LV_ASSERT_NULL(to_copy);

    lv_canvas_ext_t * ext = lv_obj_get_ext_attr(canvas);
    if(x + w >= (lv_coord_t)ext->dsc.header.w || y + h >= (lv_coord_t)ext->dsc.header.h) {
        LV_LOG_WARN("lv_canvas_copy_buf: x or y out of the canvas");
        return;
    }

    uint32_t px_size   = lv_img_color_format_get_px_size(ext->dsc.header.cf) >> 3;
    uint32_t px        = ext->dsc.header.w * y * px_size + x * px_size;
    uint8_t * to_copy8 = (uint8_t *)to_copy;
    lv_coord_t i;
    for(i = 0; i < h; i++) {
        memcpy((void *)&ext->dsc.data[px], to_copy8, w * px_size);
        px += ext->dsc.header.w * px_size;
        to_copy8 += w * px_size;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %ebp
movl %r8d, %r15d
movl %ecx, %r12d
movl %edx, %r13d
movq %rsi, %rbx
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x177d4
movq %rbx, %rdi
callq 0x80d4
testb %al, %al
je 0x177e5
movq %r14, %rdi
callq 0x6ad8
movq %rax, %r14
movswl %r13w, %r13d
movswl %r15w, %r15d
leal (%r15,%r13), %eax
movl 0x18(%r14), %edi
movl %edi, %ecx
shrl $0xa, %ecx
andl $0x7ff, %ecx            # imm = 0x7FF
cmpl %ecx, %eax
jge 0x177c5
movswl %r12w, %r12d
movswl %bp, %eax
addl %r12d, %eax
movl %edi, %ecx
shrl $0x15, %ecx
cmpl %ecx, %eax
jge 0x177c5
andl $0x1f, %edi
callq 0x3bfce
testw %bp, %bp
jle 0x177c5
shrb $0x3, %al
movl %r12d, %ecx
movzbl %al, %r12d
movq %r13, %rax
movl 0x18(%r14), %r13d
shrl $0xa, %r13d
andl $0x7ff, %r13d           # imm = 0x7FF
imull %ecx, %r13d
addl %eax, %r13d
imull %r12d, %r13d
imull %r12d, %r15d
movl %r13d, %edi
addq 0x20(%r14), %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x20f0
movl 0x18(%r14), %eax
shrl $0xa, %eax
andl $0x7ff, %eax            # imm = 0x7FF
imull %r12d, %eax
addl %eax, %r13d
addq %r15, %rbx
decw %bp
jne 0x17798
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27959(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x177e3
leaq 0x27948(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x177f4
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_canvas.c
// Function: lv_canvas_fill_bg
void lv_canvas_fill_bg(lv_obj_t * canvas, lv_color_t color)
{
    LV_ASSERT_OBJ(canvas, LV_OBJX_NAME);

    lv_img_dsc_t * dsc = lv_canvas_get_img(canvas);

    uint32_t x = dsc->header.w * dsc->header.h;
    uint32_t y;
    for(y = 0; y < dsc->header.h; y++) {
        for(x = 0; x < dsc->header.w; x++) {
            lv_img_buf_set_px_color(dsc, x, y, color);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x180d8
movq %r14, %rdi
callq 0x176bd
cmpl $0x200000, (%rax)       # imm = 0x200000
jb 0x180cf
movq %rax, %r14
xorl %r15d, %r15d
movzwl 0x1(%r14), %eax
testl $0x1ffc, %eax           # imm = 0x1FFC
je 0x180c1
xorl %r12d, %r12d
movswl %r15w, %ebp
movswl %r12w, %esi
movq %r14, %rdi
movl %ebp, %edx
movl %ebx, %ecx
callq 0x3c106
incl %r12d
movl (%r14), %eax
shrl $0xa, %eax
andl $0x7ff, %eax            # imm = 0x7FF
cmpl %eax, %r12d
jb 0x1809e
incl %r15d
movl (%r14), %eax
shrl $0x15, %eax
cmpl %eax, %r15d
jb 0x1808b
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27055(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x180e7
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_gauge.c
// Function: lv_gauge_signal
static lv_res_t lv_gauge_signal(lv_obj_t * gauge, lv_signal_t sign, void * param)
{
    lv_res_t res;

    /* Include the ancient signal function */
    res = ancestor_signal(gauge, sign, param);
    if(res != LV_RES_OK) return res;
    if(sign == LV_SIGNAL_GET_TYPE) return lv_obj_handle_get_type_signal(param, LV_OBJX_NAME);

    lv_gauge_ext_t * ext = lv_obj_get_ext_attr(gauge);
    if(sign == LV_SIGNAL_CLEANUP) {
        lv_mem_free(ext->values);
        ext->values = NULL;
    }

    return res;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r15
callq *0x476a1(%rip)          # 0x603a0
movl %eax, %ebx
cmpb $0x1, %al
jne 0x18d45
cmpb $0x7, %bpl
jne 0x18d24
leaq 0x269e8(%rip), %rsi     # 0x3f6fa
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x6bf5
movq %r15, %rdi
callq 0x6ad8
testb %bpl, %bpl
jne 0x18d45
movq %rax, %r14
movq 0x10(%rax), %rdi
callq 0x29984
movq $0x0, 0x10(%r14)
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_gauge.c
// Function: lv_gauge_set_scale
void lv_gauge_set_scale(lv_obj_t * gauge, uint16_t angle, uint8_t line_cnt, uint8_t label_cnt)
{
    LV_ASSERT_OBJ(gauge, LV_OBJX_NAME);

    lv_lmeter_set_scale(gauge, angle, line_cnt);

    lv_gauge_ext_t * ext = lv_obj_get_ext_attr(gauge);
    ext->label_count     = label_cnt;
    lv_obj_invalidate(gauge);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r15d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x194df
movzwl %r15w, %esi
movzbl %r14b, %edx
movq %rbx, %rdi
callq 0x24b35
movq %rbx, %rdi
callq 0x6ad8
movb %bpl, 0x21(%rax)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x4c36
leaq 0x25c4e(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x194ee
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_gauge.c
// Function: lv_gauge_set_needle_count
void lv_gauge_set_needle_count(lv_obj_t * gauge, uint8_t needle_cnt, const lv_color_t colors[])
{
    LV_ASSERT_OBJ(gauge, LV_OBJX_NAME);

    lv_gauge_ext_t * ext = lv_obj_get_ext_attr(gauge);

    if(ext->needle_count != needle_cnt) {
        if(ext->values != NULL) {
            lv_mem_free(ext->values);
            ext->values = NULL;
        }

        ext->values = lv_mem_realloc(ext->values, needle_cnt * sizeof(int16_t));
        LV_ASSERT_MEM(ext->values);
        if(ext->values == NULL) return;

        int16_t min = lv_gauge_get_min_value(gauge);
        uint8_t n;
        for(n = ext->needle_count; n < needle_cnt; n++) {
            ext->values[n] = min;
        }

        ext->needle_count = needle_cnt;
    }

    ext->needle_colors = colors;
    lv_obj_invalidate(gauge);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x19598
movq %rbx, %rdi
callq 0x6ad8
movq %rax, %r15
cmpb %bpl, 0x20(%rax)
je 0x19584
movq 0x10(%r15), %rdi
testq %rdi, %rdi
je 0x19534
callq 0x29984
movq $0x0, 0x10(%r15)
movq 0x10(%r15), %rdi
movzbl %bpl, %r12d
leal (%r12,%r12), %esi
callq 0x299f8
movq %rax, 0x10(%r15)
movq %rax, %rdi
callq 0x80d4
movq 0x10(%r15), %rsi
testb %al, %al
je 0x195a9
testq %rsi, %rsi
je 0x195b7
movq %rbx, %rdi
callq 0x24be0
movzbl 0x20(%r15), %ecx
cmpb %bpl, %cl
jae 0x19580
movq 0x10(%r15), %rdx
movw %ax, (%rdx,%rcx,2)
incq %rcx
cmpq %r12, %rcx
jb 0x19574
movb %bpl, 0x20(%r15)
movq %r14, 0x18(%r15)
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x4c36
leaq 0x25b95(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x195a7
leaq 0x25a90(%rip), %rdi     # 0x3f040
callq 0x829e
jmp 0x195b5
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_gauge.c
// Function: lv_gauge_set_value
void lv_gauge_set_value(lv_obj_t * gauge, uint8_t needle_id, int16_t value)
{
    LV_ASSERT_OBJ(gauge, LV_OBJX_NAME);

    lv_gauge_ext_t * ext = lv_obj_get_ext_attr(gauge);

    if(needle_id >= ext->needle_count) return;
    if(ext->values[needle_id] == value) return;

    int16_t min = lv_gauge_get_min_value(gauge);
    int16_t max = lv_gauge_get_max_value(gauge);

    if(value > max)
        value = max;
    else if(value < min)
        value = min;

    ext->values[needle_id] = value;

    lv_obj_invalidate(gauge);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x19602
movq %rbx, %rdi
callq 0x6ad8
cmpb %r15b, 0x20(%rax)
jbe 0x195f9
movq %rax, %r14
movq 0x10(%rax), %rax
movzbl %r15b, %r12d
cmpw %bp, (%rax,%r12,2)
jne 0x19613
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x25b2b(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x19611
movq %rbx, %rdi
callq 0x24be0
movl %eax, %r15d
movq %rbx, %rdi
callq 0x24c0c
cmpw %bp, %r15w
cmovlel %ebp, %r15d
cmpw %bp, %ax
cmovgel %r15d, %eax
movq 0x10(%r14), %rcx
movw %ax, (%rcx,%r12,2)
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x4c36
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_gauge.c
// Function: lv_gauge_get_value
int16_t lv_gauge_get_value(const lv_obj_t * gauge, uint8_t needle)
{
    LV_ASSERT_OBJ(gauge, LV_OBJX_NAME);

    lv_gauge_ext_t * ext = lv_obj_get_ext_attr(gauge);
    int16_t min          = lv_gauge_get_min_value(gauge);

    if(needle >= ext->needle_count) return min;

    return ext->values[needle];
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
callq 0x80d4
testb %al, %al
je 0x1968b
movq %r14, %rdi
callq 0x6ad8
movq %rax, %r15
movq %r14, %rdi
callq 0x24be0
cmpb %bl, 0x20(%r15)
jbe 0x19685
movq 0x10(%r15), %rax
movzbl %bl, %ecx
movzwl (%rax,%rcx,2), %eax
popq %rbx
popq %r14
popq %r15
retq
leaq 0x25aa2(%rip), %rdi     # 0x3f134
movq %r14, %rsi
callq 0x829e
jmp 0x1969a
// File: /workspace/github_c_makefile_star2_O1/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_label.c
// Function: lv_label_set_long_mode
void lv_label_set_long_mode(lv_obj_t * label, lv_label_long_mode_t long_mode)
{
    LV_ASSERT_OBJ(label, LV_OBJX_NAME);

    lv_label_ext_t * ext = lv_obj_get_ext_attr(label);

#if LV_USE_ANIMATION
    /*Delete the old animation (if exists)*/
    lv_anim_del(label, (lv_anim_exec_xcb_t)lv_obj_set_x);
    lv_anim_del(label, (lv_anim_exec_xcb_t)lv_obj_set_y);
    lv_anim_del(label, (lv_anim_exec_xcb_t)lv_label_set_offset_x);
    lv_anim_del(label, (lv_anim_exec_xcb_t)lv_label_set_offset_y);
#endif
    ext->offset.x = 0;
    ext->offset.y = 0;

    if(long_mode == LV_LABEL_LONG_SROLL || long_mode == LV_LABEL_LONG_SROLL_CIRC || long_mode == LV_LABEL_LONG_CROP)
        ext->expand = 1;
    else
        ext->expand = 0;

    /*Restore the character under the dots*/
    if(ext->long_mode == LV_LABEL_LONG_DOT && ext->dot_end != LV_LABEL_DOT_END_INV) {
        lv_label_revert_dots(label);
    }

    ext->long_mode = long_mode;
    lv_label_refr_text(label);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
callq 0x80d4
testb %al, %al
je 0x19f02
movq %rbx, %rdi
callq 0x6ad8
movq %rax, %r15
leaq -0x149a4(%rip), %rsi    # 0x54c3
movq %rbx, %rdi
callq 0x295b1
leaq -0x14975(%rip), %rsi    # 0x5501
movq %rbx, %rdi
callq 0x295b1
leaq 0xcb3(%rip), %rsi       # 0x1ab38
movq %rbx, %rdi
callq 0x295b1
leaq 0xcc5(%rip), %rsi       # 0x1ab59
movq %rbx, %rdi
callq 0x295b1
movl $0x0, 0x12(%r15)
leal -0x3(%r14), %eax
xorl %ecx, %ecx
cmpb $0x3, %al
setb %cl
movzwl 0x18(%r15), %eax
movl %eax, %edx
andl $0xff7f, %edx           # imm = 0xFF7F
shll $0x7, %ecx
orl %edx, %ecx
movw %cx, 0x18(%r15)
andl $0x7, %eax
cmpw $0x2, %ax
jne 0x19edf
cmpw $-0x1, 0x10(%r15)
je 0x19edf
movq %rbx, %rdi
callq 0x1ab7a
movl 0x18(%r15), %eax
andb $0x7, %r14b
movzbl %r14b, %ecx
andl $-0x8, %eax
orl %ecx, %eax
movw %ax, 0x18(%r15)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x1a365
leaq 0x2522b(%rip), %rdi     # 0x3f134
movq %rbx, %rsi
callq 0x829e
jmp 0x19f11