user: Converte this assembly snippet into its equivalent C code:

```asm
<hbCreateDecodeTables>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %rdx,-0x28(%rbp)
  mov    %rcx,-0x30(%rbp)
  mov    %r8d,-0x34(%rbp)
  mov    %r9d,-0x38(%rbp)
  movl   $0x0,-0x10(%rbp)
  mov    -0x34(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  jmp    L13
L80:
  movl   $0x0,-0x8(%rbp)
  jmp    L9
L34:
  mov    -0x8(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  cmp    %eax,-0xc(%rbp)
  jne    L93
  mov    -0x10(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x28(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  mov    %eax,(%rdx)
  addl   $0x1,-0x10(%rbp)
L93:
  addl   $0x1,-0x8(%rbp)
L9:
  mov    -0x8(%rbp),%eax
  cmp    0x10(%rbp),%eax
  jl     L34
  addl   $0x1,-0xc(%rbp)
L13:
  mov    -0xc(%rbp),%eax
  cmp    -0x38(%rbp),%eax
  jle    L80
  movl   $0x0,-0xc(%rbp)
  jmp    L38
L59:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movl   $0x0,(%rax)
  addl   $0x1,-0xc(%rbp)
L38:
  cmpl   $0x16,-0xc(%rbp)
  jle    L59
  movl   $0x0,-0xc(%rbp)
  jmp    L94
L72:
  mov    -0xc(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  add    $0x1,%edx
  mov    %edx,(%rax)
  addl   $0x1,-0xc(%rbp)
L94:
  mov    -0xc(%rbp),%eax
  cmp    0x10(%rbp),%eax
  jl     L72
  movl   $0x1,-0xc(%rbp)
  jmp    L118
L35:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%ecx
  mov    -0xc(%rbp),%eax
  cltq
  shl    $0x2,%rax
  lea    -0x4(%rax),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rsi
  mov    -0x20(%rbp),%rax
  add    %rsi,%rax
  add    %ecx,%edx
  mov    %edx,(%rax)
  addl   $0x1,-0xc(%rbp)
L118:
  cmpl   $0x16,-0xc(%rbp)
  jle    L35
  movl   $0x0,-0xc(%rbp)
  jmp    L96
L21:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movl   $0x0,(%rax)
  addl   $0x1,-0xc(%rbp)
L96:
  cmpl   $0x16,-0xc(%rbp)
  jle    L21
  movl   $0x0,-0x4(%rbp)
  mov    -0x34(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  jmp    L74
L31:
  mov    -0xc(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  mov    -0xc(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x20(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%edx
  sub    %edx,%eax
  add    %eax,-0x4(%rbp)
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  mov    -0x4(%rbp),%edx
  sub    $0x1,%edx
  mov    %edx,(%rax)
  shll   -0x4(%rbp)
  addl   $0x1,-0xc(%rbp)
L74:
  mov    -0xc(%rbp),%eax
  cmp    -0x38(%rbp),%eax
  jle    L31
  mov    -0x34(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,-0xc(%rbp)
  jmp    L8
L165:
  mov    -0xc(%rbp),%eax
  cltq
  shl    $0x2,%rax
  lea    -0x4(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  add    $0x1,%eax
  lea    (%rax,%rax,1),%edx
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rcx
  mov    -0x20(%rbp),%rax
  add    %rcx,%rax
  mov    (%rax),%ecx
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rsi
  mov    -0x20(%rbp),%rax
  add    %rsi,%rax
  sub    %ecx,%edx
  mov    %edx,(%rax)
  addl   $0x1,-0xc(%rbp)
L8:
  mov    -0xc(%rbp),%eax
  cmp    -0x38(%rbp),%eax
  jle    L165
  nop
  nop
  pop    %rbp
  ret
```

assistant: ```c
void hbCreateDecodeTables(int *limit, int *base, int *perm, unsigned char *length, int minLen, int maxLen, int alphaSize) {
  int pp, i, j, vec;
  pp = 0;
  for (i = minLen; i <= maxLen; i++)
    for (j = 0; j < alphaSize; j++)
      if (length[j] == i) {
        perm[pp] = j;
        pp++;
      };
  for (i = 0; i < 23; i++)
    base[i] = 0;
  for (i = 0; i < alphaSize; i++)
    base[length[i] + 1]++;
  for (i = 1; i < 23; i++)
    base[i] += base[i - 1];
  for (i = 0; i < 23; i++)
    limit[i] = 0;
  vec = 0;
  for (i = minLen; i <= maxLen; i++) {
    vec += (base[i + 1] - base[i]);
    limit[i] = vec - 1;
    vec <<= 1;
  }
  for (i = minLen + 1; i <= maxLen; i++)
    base[i] = ((limit[i - 1] + 1) << 1) - base[i];
}
```