user: Please show me the C implementation that matches the assembly code listed below:

```asm
<compute_frame_min_max_tiles>:
  endbr64
  push   %r15
  mov    %ecx,%eax
  push   %r14
  mov    %edx,%r14d
  push   %r13
  imul   %r14d,%ecx
  push   %r12
  mov    %r9d,%r12d
  shr    $0x1f,%r12d
  push   %rbp
  mov    %r9d,%ebp
  add    %r9d,%r12d
  push   %rbx
  mov    %rdi,%rbx
  sar    %r12d
  sub    %r12d,%eax
  cltd
  sub    $0x58,%rsp
  idiv   %r9d
  mov    %rsi,0x18(%rsp)
  mov    %r9d,0x4(%rsp)
  mov    %ecx,0x3c(%rsp)
  mov    %eax,%r13d
  mov    %r8d,%eax
  mov    %edx,%r15d
  sub    %r12d,%eax
  cltd
  idiv   %r9d
  mov    %eax,0x48(%rsp)
  lea    0x2(%r13),%eax
  mov    %eax,%esi
  mov    %edx,0x4c(%rsp)
  mov    %edx,0x2c(%rsp)
  mov    %eax,0x28(%rsp)
  call   <init_min_max@plt>
  cmp    $0x1,%ebp
  jle    L79
  movslq 0x3c(%rsp),%rax
  mov    0x18(%rsp),%rbp
  mov    %r12d,0x10(%rsp)
  mov    %rax,0x8(%rsp)
  mov    %r15d,%eax
  mov    %r13d,%r15d
  mov    %r12d,%r13d
  mov    %rbp,%r12
  mov    %eax,%ebp
  nopl   0x0(%rax)
L37:
  sub    $0x8,%rsp
  mov    %ebp,%r9d
  mov    %r15d,%r8d
  mov    %r12,%rsi
  mov    0xc(%rsp),%eax
  mov    %r13d,%ecx
  mov    %r14d,%edx
  mov    %rbx,%rdi
  push   %rax
  call   <compute_line_min_max_spans@plt>
  add    0x18(%rsp),%r12
  pop    %r8
  pop    %r9
  subl   $0x1,0x10(%rsp)
  jne    L37
  mov    %r13d,%r12d
  mov    $0x1,%edx
  mov    %r15d,%r13d
  mov    %ebp,%r15d
  lea    -0x1(%r12),%eax
  add    $0x1,%rax
  cmpl   $0x1,0x4(%rsp)
  cmovle %rdx,%rax
  imul   0x8(%rsp),%rax
  add    %rax,0x18(%rsp)
L79:
  mov    0x28(%rsp),%eax
  mov    0x48(%rsp),%edx
  add    %eax,%eax
  cltq
  add    %rax,%rbx
  mov    %rax,0x20(%rsp)
  mov    %rbx,0x40(%rsp)
  mov    %rbx,%rbp
  test   %edx,%edx
  jle    L35
  mov    0x4(%rsp),%eax
  movslq 0x3c(%rsp),%rdi
  mov    %edx,0x38(%rsp)
  mov    %r12d,0x8(%rsp)
  sub    $0x1,%eax
  mov    %rdi,0x10(%rsp)
  add    $0x1,%rax
  imul   %rdi,%rax
  mov    %rax,0x30(%rsp)
  cs nopw 0x0(%rax,%rax,1)
L13:
  mov    0x28(%rsp),%esi
  mov    %rbp,%rdi
  call   <init_min_max@plt>
  mov    0x4(%rsp),%eax
  test   %eax,%eax
  jle    L42
  mov    %eax,%ebx
  mov    0x18(%rsp),%r12
  mov    %r15d,%eax
  mov    %r13d,%r15d
  mov    %eax,%r13d
  nopl   0x0(%rax)
L63:
  sub    $0x8,%rsp
  mov    %r12,%rsi
  mov    %rbp,%rdi
  mov    %r13d,%r9d
  mov    0xc(%rsp),%eax
  mov    %r15d,%r8d
  mov    %r14d,%edx
  push   %rax
  mov    0x18(%rsp),%ecx
  call   <compute_line_min_max_spans@plt>
  add    0x20(%rsp),%r12
  pop    %rsi
  pop    %rdi
  sub    $0x1,%ebx
  jne    L63
  mov    0x30(%rsp),%rcx
  add    %rcx,0x18(%rsp)
  mov    %r13d,%eax
  mov    %r15d,%r13d
  mov    %eax,%r15d
L42:
  add    0x20(%rsp),%rbp
  subl   $0x1,0x38(%rsp)
  jne    L13
  movslq 0x48(%rsp),%rax
  imul   0x20(%rsp),%rax
  add    %rax,0x40(%rsp)
  mov    0x8(%rsp),%r12d
L35:
  mov    0x40(%rsp),%rbp
  mov    0x28(%rsp),%esi
  mov    %rbp,%rdi
  call   <init_min_max@plt>
  mov    0x4c(%rsp),%ecx
  movslq 0x3c(%rsp),%rbx
  test   %ecx,%ecx
  jle    L46
  mov    %rbx,0x8(%rsp)
  mov    %r15d,%ebx
  mov    %r13d,%r15d
  mov    %r12d,%r13d
  mov    0x18(%rsp),%r12
  nopw   0x0(%rax,%rax,1)
L68:
  sub    $0x8,%rsp
  mov    %r14d,%edx
  mov    %r12,%rsi
  mov    %ebx,%r9d
  mov    0xc(%rsp),%eax
  mov    %r15d,%r8d
  mov    %r13d,%ecx
  mov    %rbp,%rdi
  push   %rax
  call   <compute_line_min_max_spans@plt>
  add    0x18(%rsp),%r12
  pop    %rax
  pop    %rdx
  subl   $0x1,0x2c(%rsp)
  jne    L68
L46:
  add    $0x58,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
void compute_frame_min_max_tiles(unsigned char *min_max_dest, const unsigned char *source, int source_stride, int width, int height, int tile_size) {
  int first_vector_size = tile_size / 2;
  int full_span_count = (width - first_vector_size) / tile_size;
  int last_vector_size = width - first_vector_size - (full_span_count * tile_size);
  int first_block_height = tile_size / 2;
  int full_block_count = (height - first_block_height) / tile_size;
  int last_block_height = height - first_block_height - (full_block_count * tile_size);
  int i, j;
  int increment = source_stride * width;
  init_min_max(min_max_dest, full_span_count + 2);
  for (i = first_block_height; i > 0; --i) {
    compute_line_min_max_spans(min_max_dest, source, source_stride, first_vector_size, full_span_count, last_vector_size, tile_size);
    source += increment;
  }
  min_max_dest += 2 * (full_span_count + 2);
  for (i = full_block_count; i > 0; --i) {
    init_min_max(min_max_dest, full_span_count + 2);
    for (j = tile_size; j > 0; --j) {
      compute_line_min_max_spans(min_max_dest, source, source_stride, first_vector_size, full_span_count, last_vector_size, tile_size);
      source += increment;
    }
    min_max_dest += 2 * (full_span_count + 2);
  }
  init_min_max(min_max_dest, full_span_count + 2);
  for (i = last_block_height; i > 0; --i) {
    compute_line_min_max_spans(min_max_dest, source, source_stride, first_vector_size, full_span_count, last_vector_size, tile_size);
    source += increment;
  }
}
```