// File: /workspace/github_c_makefile_star2_O0/albinoloverats[P]hide/common/src/cli.c
// Function: cli_display_bar
static void cli_display_bar(char *name, cli_progress_s *p, double percent)
{
	int name_width = CLI_TRUNCATED_DISPLAY_SHORT + strlen(CLI_TRUNCATED_ELLIPSE) + (cli_width > CLI_DEFAULT ? CLI_TRUNCATED_DISPLAY_SHORT : 0);
	fprintf(stderr, "\r%-*s : ", name_width, name);
	if (cli_width > CLI_SMALL)
		fprintf(stderr, "%'13" PRIu64 "/%-'13" PRIu64 " (", p->offset, p->size);
	fprintf(stderr, "%3.0f%%", isnan(percent) ? 0.0f : (percent > PERCENT ? PERCENT : percent));
	if (cli_width > CLI_SMALL)
		fprintf(stderr, ")");

	if (cli_width > CLI_DEFAULT)
	{
		int progress_bar_width = cli_width - CLI_LARGE;
		fprintf(stderr, " [");
		/*
		 * display overall progress bar
		 */
		for (int i = 0; i < progress_bar_width; i++)
			fprintf(stderr, "%c", i < progress_bar_width * percent  / PERCENT ? '=' : ' ');
		fprintf(stderr, "]");
	}
	return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movsd %xmm0, -0x18(%rbp)
movl 0x3081(%rip), %edx      # 0x81ec
xorl %eax, %eax
movl $0xa, %ecx
cmpl $0x50, %edx
cmovgl %ecx, %eax
cltq
addq $0xe, %rax
movl %eax, -0x1c(%rbp)
movq 0x2e70(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
movl -0x1c(%rbp), %edx
movq -0x8(%rbp), %rcx
leaq 0x121c(%rip), %rsi      # 0x63b5
movb $0x0, %al
callq 0x2200
cmpl $0x3e, 0x3045(%rip)     # 0x81ec
jle 0x51d0
movq 0x2e48(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rdx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
leaq 0x11f5(%rip), %rsi      # 0x63be
movb $0x0, %al
callq 0x2200
movq 0x2e21(%rip), %rax      # 0x7ff8
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movsd -0x18(%rbp), %xmm0
ucomisd %xmm0, %xmm0
setp %al
testb $0x1, %al
jne 0x51f0
jmp 0x51fa
xorps %xmm0, %xmm0
movsd %xmm0, -0x38(%rbp)
jmp 0x5230
movsd -0x18(%rbp), %xmm0
movsd 0x10c9(%rip), %xmm1     # 0x62d0
ucomisd %xmm1, %xmm0
jbe 0x521c
movsd 0x10bb(%rip), %xmm0     # 0x62d0
movsd %xmm0, -0x40(%rbp)
jmp 0x5226
movsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x40(%rbp)
movsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x30(%rbp), %rdi
movsd -0x38(%rbp), %xmm0
leaq 0x118f(%rip), %rsi      # 0x63cf
movb $0x1, %al
callq 0x2200
cmpl $0x3e, 0x2f9e(%rip)     # 0x81ec
jle 0x5268
movq 0x2da1(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
leaq 0x1142(%rip), %rsi      # 0x63a3
movb $0x0, %al
callq 0x2200
cmpl $0x50, 0x2f7d(%rip)     # 0x81ec
jle 0x530f
movl 0x2f71(%rip), %eax      # 0x81ec
subl $0x4b, %eax
movl %eax, -0x20(%rbp)
movq 0x2d70(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
leaq 0x102a(%rip), %rsi      # 0x62bc
movb $0x0, %al
callq 0x2200
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x20(%rbp), %eax
jge 0x52f7
movq 0x2d49(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
cvtsi2sdl -0x24(%rbp), %xmm1
cvtsi2sdl -0x20(%rbp), %xmm0
mulsd -0x18(%rbp), %xmm0
movsd 0x1007(%rip), %xmm2     # 0x62d0
divsd %xmm2, %xmm0
movl $0x20, %edx
movl $0x3d, %eax
ucomisd %xmm1, %xmm0
cmoval %eax, %edx
leaq 0x10f2(%rip), %rsi      # 0x63d7
movb $0x0, %al
callq 0x2200
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x52a0
movq 0x2cfa(%rip), %rax      # 0x7ff8
movq (%rax), %rdi
leaq 0x115c(%rip), %rsi      # 0x6464
movb $0x0, %al
callq 0x2200
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)