// File: /workspace/github_cpp_makefile_star2_O2/ctz[P]openssl-bench/bench.cc
// Function: print_results(char const*, char const*, std::vector<Timings, std::allocator<Timings>> const&, double, char const*)
static void print_results(const char *server, const char *client,
                          const std::vector<Timings> &thread_timings,
                          const double thread_work, const char *units) {
  const size_t n_threads = thread_timings.size();
  if (n_threads > 1) {
    printf("%s\tthreads\t%zu\t", server, n_threads);
    double total_server = 0.;

    for (unsigned i = 0; i < n_threads; i++) {
      const double server = thread_work / thread_timings[i].server.load();
      total_server += server;
      printf("%g\t", server);
    }
    printf("total\t%g\tper-thread\t%g\t%s\n", total_server,
           total_server / n_threads, units);
    printf("%s\tthreads\t%zu\t", client, n_threads);
    double total_client = 0.;

    for (unsigned i = 0; i < n_threads; i++) {
      const double client = thread_work / thread_timings[i].client.load();
      total_client += client;
      printf("%g\t", client);
    }
    printf("total\t%g\tper-thread\t%g\t%s\n", total_client,
           total_client / n_threads, units);
  } else {
    printf("%s\t%g\t%s\n", server,
           thread_work / thread_timings[0].server.load(), units);
    printf("%s\t%g\t%s\n", client,
           thread_work / thread_timings[0].client.load(), units);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rsi
movq (%rdx), %rax
movq 0x8(%rdx), %r15
subq %rax, %r15
sarq $0x4, %r15
cmpq $0x2, %r15
movsd %xmm0, 0x8(%rsp)
jb 0x474d
leaq 0x2e56(%rip), %rdi      # 0x7496
xorl %ebp, %ebp
movq %r15, %rdx
xorl %eax, %eax
callq 0x3050
xorpd %xmm0, %xmm0
movsd %xmm0, (%rsp)
leaq 0x2e4a(%rip), %r13      # 0x74a6
movl %ebp, %ebp
cmpq %rbp, %r15
movsd 0x8(%rsp), %xmm0
jbe 0x4695
movq (%r14), %rax
movq %rbp, %rcx
shlq $0x4, %rcx
divsd 0x8(%rax,%rcx), %xmm0
movsd (%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
movq %r13, %rdi
movb $0x1, %al
callq 0x3050
incl %ebp
jmp 0x465c
cvtsi2sd %r15, %xmm2
movsd (%rsp), %xmm0
movapd %xmm0, %xmm1
movsd %xmm2, 0x10(%rsp)
divsd %xmm2, %xmm1
leaq 0x2df6(%rip), %rdi      # 0x74aa
movq %rbx, %rsi
movb $0x2, %al
callq 0x3050
leaq 0x2dd1(%rip), %rdi      # 0x7496
xorl %ebp, %ebp
movq %r12, %rsi
movq %r15, %rdx
xorl %eax, %eax
callq 0x3050
xorpd %xmm0, %xmm0
movsd %xmm0, (%rsp)
leaq 0x2dc2(%rip), %r12      # 0x74a6
movl %ebp, %r13d
cmpq %r13, %r15
movsd 0x8(%rsp), %xmm0
jbe 0x471f
movq (%r14), %rax
movq %r13, %rcx
shlq $0x4, %rcx
divsd (%rax,%rcx), %xmm0
movsd (%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
movq %r12, %rdi
movb $0x1, %al
callq 0x3050
leal 0x1(%r13), %ebp
jmp 0x46e4
movsd (%rsp), %xmm0
movapd %xmm0, %xmm1
divsd 0x10(%rsp), %xmm1
leaq 0x2d75(%rip), %rdi      # 0x74aa
movq %rbx, %rsi
movb $0x2, %al
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3050
divsd 0x8(%rax), %xmm0
leaq 0x2d6c(%rip), %r15      # 0x74c5
movq %r15, %rdi
movq %rbx, %rdx
movb $0x1, %al
callq 0x3050
movq (%r14), %rax
movsd 0x8(%rsp), %xmm0
divsd (%rax), %xmm0
movq %r15, %rdi
movq %r12, %rsi
movq %rbx, %rdx
movb $0x1, %al
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3050