// File: /workspace/github_c_makefile_star2_O0/pencode-lab[P]Shoit/shoit_progress.c
// Function: shoit_progress_show
void shoit_progress_show(progress_t *progress, float bit)
{
    int val = (int)(bit * progress->max);

    switch ( progress->style )
    {
        case PROGRESS_NUM_STYLE:                                                                                                     
            fprintf(stderr,"\033[?25l\033[31m\033[1m%s%d%%\033[?25h\033[0m\r",                                                       
                progress->title, (int)(progress->offset * val));                                                                               
            fflush(stderr);                                                                                                          
            break;                                                                                                                   
                                                                                                                                     
        case PROGRESS_CHR_STYLE:                                                                                                     
            memset(progress->pro, '.', val);                                                                                              
            fprintf(stderr,"\033[?25l\033[31m\033[1m%s  %-s| %d%%\033[?25h\033[0m\r",                                                
                progress->title, progress->pro, (int)(progress->offset * val));                                                                     
            fflush(stderr);                                                                                                          
            break;                                                                                                                   
                                                                                                                                     
        case PROGRESS_BGC_STYLE:                                                                                                     
            memset(progress->pro, 32, val);                                                                                               
            fprintf(stderr,"\033[?25l\033[31m\033[1m%s\033[41m %d%% %s\033[?25h\033[0m\r",                                           
                progress->title, (int)(progress->offset * val), progress->pro);                                                                     
            fflush(stderr);                                                                                                          
            break;                                                                                                                   
    }                                                                                                                                
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movss %xmm0, -0xc(%rbp)
movss -0xc(%rbp), %xmm0
movq -0x8(%rbp), %rax
cvtsi2ssl 0x14(%rax), %xmm1
mulss %xmm1, %xmm0
cvttss2si %xmm0, %eax
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x14(%rbp)
testl %eax, %eax
je 0x42f5
jmp 0x42da
movl -0x14(%rbp), %eax
subl $0x1, %eax
je 0x433f
jmp 0x42e4
movl -0x14(%rbp), %eax
subl $0x2, %eax
je 0x43a5
jmp 0x4408
movq 0x7cfc(%rip), %rax      # 0xbff8
movq (%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdx
movq -0x8(%rbp), %rax
movss 0x18(%rax), %xmm0
cvtsi2ssl -0x10(%rbp), %xmm1
mulss %xmm1, %xmm0
cvttss2si %xmm0, %ecx
leaq 0x52fc(%rip), %rsi      # 0x9620
movb $0x0, %al
callq 0x2250
movq 0x7cc6(%rip), %rax      # 0xbff8
movq (%rax), %rdi
callq 0x22f0
jmp 0x4408
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
movslq -0x10(%rbp), %rdx
movl $0x2e, %esi
callq 0x21a0
movq 0x7c9c(%rip), %rax      # 0xbff8
movq (%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdx
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rcx
movq -0x8(%rbp), %rax
movss 0x18(%rax), %xmm0
cvtsi2ssl -0x10(%rbp), %xmm1
mulss %xmm1, %xmm0
cvttss2si %xmm0, %r8d
leaq 0x52b4(%rip), %rsi      # 0x9641
movb $0x0, %al
callq 0x2250
movq 0x7c5d(%rip), %rax      # 0xbff8
movq (%rax), %rdi
callq 0x22f0
jmp 0x4408
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
movslq -0x10(%rbp), %rdx
movl $0x20, %esi
callq 0x21a0
movq 0x7c36(%rip), %rax      # 0xbff8
movq (%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdx
movq -0x8(%rbp), %rax
movss 0x18(%rax), %xmm0
cvtsi2ssl -0x10(%rbp), %xmm1
mulss %xmm1, %xmm0
cvttss2si %xmm0, %ecx
movq -0x8(%rbp), %rax
movq 0x20(%rax), %r8
leaq 0x5277(%rip), %rsi      # 0x9669
movb $0x0, %al
callq 0x2250
movq 0x7bf8(%rip), %rax      # 0xbff8
movq (%rax), %rdi
callq 0x22f0
addq $0x20, %rsp
popq %rbp
retq
nop