user: What would the C source look like for the assembly code provided here:

```asm
<adjust>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x1d8,%rsp
  mov    %rdi,-0x1b8(%rbp)
  mov    %esi,-0x1bc(%rbp)
  mov    %rdx,-0x1c8(%rbp)
  mov    %rcx,-0x1d0(%rbp)
  mov    %r8d,-0x1c0(%rbp)
  mov    %r9,-0x1d8(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x18(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x1a4(%rbp)
  jmp    L25
L56:
  mov    -0x1a4(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x1d8(%rbp),%rax
  add    %rdx,%rax
  movl   $0x0,(%rax)
  mov    -0x1a4(%rbp),%eax
  cltq
  movl   $0x0,-0x1a0(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  movl   $0x0,-0x120(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  movl   $0x0,-0xa0(%rbp,%rax,4)
  addl   $0x1,-0x1a4(%rbp)
L25:
  mov    -0x1a4(%rbp),%eax
  cmp    %eax,-0x1c0(%rbp)
  ja     L56
  movl   $0x0,-0x1a8(%rbp)
  jmp    L60
L35:
  mov    -0x1a8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x1b8(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  lea    -0x1a9(%rbp),%rcx
  lea    -0x1aa(%rbp),%rdx
  lea    -0x1ab(%rbp),%rsi
  mov    %eax,%edi
  call   <bm_get_rgb@plt>
  mov    -0x1a8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x1c8(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  mov    %eax,-0x1a4(%rbp)
  mov    -0x1a4(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x1d8(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  add    $0x1,%edx
  mov    %edx,(%rax)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%edx
  movzbl -0x1ab(%rbp),%eax
  movzbl %al,%eax
  add    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0x1a0(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x120(%rbp,%rax,4),%edx
  movzbl -0x1aa(%rbp),%eax
  movzbl %al,%eax
  add    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0x120(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0xa0(%rbp,%rax,4),%edx
  movzbl -0x1a9(%rbp),%eax
  movzbl %al,%eax
  add    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0xa0(%rbp,%rax,4)
  addl   $0x1,-0x1a8(%rbp)
L60:
  mov    -0x1a8(%rbp),%eax
  cmp    -0x1bc(%rbp),%eax
  jl     L35
  movl   $0x0,-0x1a4(%rbp)
  jmp    L76
L81:
  mov    -0x1a4(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x1d8(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  test   %eax,%eax
  je     L10
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  mov    -0x1a4(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x1d8(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%ebx
  mov    $0x0,%edx
  div    %ebx
  mov    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0x1a0(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x120(%rbp,%rax,4),%eax
  mov    -0x1a4(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x1d8(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%ebx
  mov    $0x0,%edx
  div    %ebx
  mov    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0x120(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0xa0(%rbp,%rax,4),%eax
  mov    -0x1a4(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x1d8(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%edi
  mov    $0x0,%edx
  div    %edi
  mov    %eax,%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    %edx,-0xa0(%rbp,%rax,4)
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0xa0(%rbp,%rax,4),%edx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x120(%rbp,%rax,4),%ecx
  mov    -0x1a4(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  mov    -0x1a4(%rbp),%esi
  movslq %esi,%rsi
  lea    0x0(,%rsi,4),%rdi
  mov    -0x1d0(%rbp),%rsi
  lea    (%rdi,%rsi,1),%rbx
  mov    %ecx,%esi
  mov    %eax,%edi
  call   <bm_rgb@plt>
  mov    %eax,(%rbx)
  jmp    L83
L10:
  nop
L83:
  addl   $0x1,-0x1a4(%rbp)
L76:
  mov    -0x1a4(%rbp),%eax
  cmp    %eax,-0x1c0(%rbp)
  ja     L81
  nop
  mov    -0x18(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L9
  call   <__stack_chk_fail@plt>
L9:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
void adjust(unsigned int *bytes, int np, int *cat, unsigned int *pal, unsigned int K, unsigned int *n) {
  int i, k;
  unsigned int sR[32], sG[32], sB[32];
  for (k = 0; k < K; k++) {
    n[k] = 0;
    sR[k] = 0;
    sG[k] = 0;
    sB[k] = 0;
  }
  for (i = 0; i < np; i++) {
    unsigned char iR, iG, iB;
    bm_get_rgb(bytes[i], &iR, &iG, &iB);
    k = cat[i];
    n[k]++;
    sR[k] += iR;
    sG[k] += iG;
    sB[k] += iB;
  }
  for (k = 0; k < K; k++) {
    if (n[k] == 0)
      continue;
    sR[k] /= n[k];
    sG[k] /= n[k];
    sB[k] /= n[k];
    pal[k] = bm_rgb(sR[k], sG[k], sB[k]);
  }
}
```