// File: /workspace/github_c_makefile_star2_O0/zhou-yuxin[P]redis-aof-no-cow/src/redis-benchmark.c
// Function: showLatencyReport
static void showLatencyReport(void) {
    int i, curlat = 0;
    float perc, reqpersec;

    reqpersec = (float)config.requests_finished/((float)config.totlatency/1000);
    if (!config.quiet && !config.csv) {
        printf("====== %s ======\n", config.title);
        printf("  %d requests completed in %.2f seconds\n", config.requests_finished,
            (float)config.totlatency/1000);
        printf("  %d parallel clients\n", config.numclients);
        printf("  %d bytes payload\n", config.datasize);
        printf("  keep alive: %d\n", config.keepalive);
        printf("\n");

        qsort(config.latency,config.requests,sizeof(long long),compareLatency);
        for (i = 0; i < config.requests; i++) {
            if (config.latency[i]/1000 != curlat || i == (config.requests-1)) {
                curlat = config.latency[i]/1000;
                perc = ((float)(i+1)*100)/config.requests;
                printf("%.2f%% <= %d milliseconds\n", perc, curlat);
            }
        }
        printf("%.2f requests per second\n\n", reqpersec);
    } else if (config.csv) {
        printf("\"%s\",\"%.2f\"\n", config.title, reqpersec);
    } else {
        printf("%s: %.2f requests per second\n", config.title, reqpersec);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl $0x0, -0x8(%rbp)
cvtsi2ssl 0x932a1(%rip), %xmm0 # 0xa3448
cvtsi2ssq 0x932c0(%rip), %xmm1 # 0xa3470
movss 0x7e00c(%rip), %xmm2    # 0x8e1c4
divss %xmm2, %xmm1
divss %xmm1, %xmm0
movss %xmm0, -0x10(%rbp)
cmpl $0x0, 0x932c4(%rip)     # 0xa3490
jne 0x10358
cmpl $0x0, 0x932bb(%rip)     # 0xa3494
jne 0x10358
movq 0x9329a(%rip), %rsi     # 0xa3480
leaq 0x7ee63(%rip), %rdi     # 0x8f050
movb $0x0, %al
callq 0xb1a0
movl 0x9324e(%rip), %esi     # 0xa3448
cvtsi2ssq 0x9326d(%rip), %xmm0 # 0xa3470
movss 0x7dfb9(%rip), %xmm1    # 0x8e1c4
divss %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x7ee48(%rip), %rdi     # 0x8f062
movb $0x1, %al
callq 0xb1a0
movl 0x93211(%rip), %esi     # 0xa3438
leaq 0x7ee5d(%rip), %rdi     # 0x8f08b
movb $0x0, %al
callq 0xb1a0
movl 0x93215(%rip), %esi     # 0xa3450
leaq 0x7ee60(%rip), %rdi     # 0x8f0a2
movb $0x0, %al
callq 0xb1a0
movl 0x9320d(%rip), %esi     # 0xa345c
leaq 0x7ee60(%rip), %rdi     # 0x8f0b6
movb $0x0, %al
callq 0xb1a0
leaq 0x7ee98(%rip), %rdi     # 0x8f0fc
movb $0x0, %al
callq 0xb1a0
movq 0x93206(%rip), %rdi     # 0xa3478
movslq 0x931c7(%rip), %rsi     # 0xa3440
movl $0x8, %edx
leaq 0x17b(%rip), %rcx       # 0x10400
callq 0xb0c0
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
cmpl 0x931a6(%rip), %eax     # 0xa3440
jge 0x1033f
movq 0x931d1(%rip), %rax     # 0xa3478
movslq -0x4(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl $0x3e8, %ecx            # imm = 0x3E8
cqto
idivq %rcx
movslq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x102d2
movl -0x4(%rbp), %eax
movl 0x93175(%rip), %ecx     # 0xa3440
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x1032f
movq 0x9319f(%rip), %rax     # 0xa3478
movslq -0x4(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl $0x3e8, %ecx            # imm = 0x3E8
cqto
idivq %rcx
movl %eax, -0x8(%rbp)
movl -0x4(%rbp), %eax
addl $0x1, %eax
cvtsi2ss %eax, %xmm0
movss 0x7dec8(%rip), %xmm1    # 0x8e1c8
mulss %xmm1, %xmm0
cvtsi2ssl 0x93134(%rip), %xmm1 # 0xa3440
divss %xmm1, %xmm0
movss %xmm0, -0xc(%rbp)
movss -0xc(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
movl -0x8(%rbp), %esi
leaq 0x7eda0(%rip), %rdi     # 0x8f0c8
movb $0x1, %al
callq 0xb1a0
jmp 0x10331
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x10291
movss -0x10(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x7ed94(%rip), %rdi     # 0x8f0e3
movb $0x1, %al
callq 0xb1a0
jmp 0x103a1
cmpl $0x0, 0x93135(%rip)     # 0xa3494
je 0x10381
movq 0x93118(%rip), %rsi     # 0xa3480
movss -0x10(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x7ed86(%rip), %rdi     # 0x8f0fe
movb $0x1, %al
callq 0xb1a0
jmp 0x1039f
movq 0x930f8(%rip), %rsi     # 0xa3480
movss -0x10(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x7ed73(%rip), %rdi     # 0x8f10b
movb $0x1, %al
callq 0xb1a0
jmp 0x103a1
addq $0x10, %rsp
popq %rbp
retq
nopw (%rax,%rax)