user: Translate the below assembly code into C programming language:

```asm
<iconvConvert>:
  endbr64
  push   %r15
  mov    %rdi,%r15
  push   %r14
  mov    %r8d,%r14d
  push   %r13
  mov    %rsi,%r13
  push   %r12
  mov    %rcx,%r12
  push   %rbp
  push   %rbx
  mov    %edx,%ebx
  sub    $0x38,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  test   %rsi,%rsi
  je     L103
L78:
  test   %ebx,%ebx
  js     L9
  test   %r12,%r12
  je     L77
L88:
  cmp    %r14d,%ebx
  jge    L73
L87:
  movb   $0x0,(%r12)
  movslq %ebx,%rbp
  cmp    $0xffffffffffffffff,%r15
  je     L127
  movslq %r14d,%rax
  lea    0x10(%rsp),%r8
  lea    0x20(%rsp),%rcx
  mov    %r15,%rdi
  lea    0x8(%rsp),%rdx
  lea    0x18(%rsp),%rsi
  mov    %r13,0x18(%rsp)
  mov    %r12,0x20(%rsp)
  mov    %rbp,0x8(%rsp)
  mov    %rax,0x10(%rsp)
  call   <iconv@plt>
  mov    %eax,%r8d
  mov    $0xffffffff,%eax
  test   %r8d,%r8d
  js     L125
  cmpq   $0x0,0x8(%rsp)
  jne    L125
  mov    %r14d,%eax
  sub    0x10(%rsp),%eax
  movslq %eax,%rdx
  movb   $0x0,(%r12,%rdx,1)
L125:
  mov    0x28(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L86
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L127:
  mov    %ebx,%edx
  mov    %r13,%rsi
  mov    %r12,%rdi
  call   <memcpy@plt>
  movb   $0x0,(%r12,%rbp,1)
  mov    %ebx,%eax
  jmp    L125
  cs nopw 0x0(%rax,%rax,1)
L73:
  lea    D26(%rip),%rdx
  mov    $0x7d,%esi
  lea    D50(%rip),%rdi
  call   <utfError@plt>
  jmp    L87
  nopl   (%rax)
L9:
  lea    D58(%rip),%rdx
  mov    $0x7b,%esi
  lea    D50(%rip),%rdi
  call   <utfError@plt>
  test   %r12,%r12
  jne    L88
L77:
  lea    D77(%rip),%rdx
  mov    $0x7c,%esi
  lea    D50(%rip),%rdi
  call   <utfError@plt>
  jmp    L88
  xchg   %ax,%ax
L103:
  lea    D62(%rip),%rdx
  mov    $0x7a,%esi
  lea    D50(%rip),%rdi
  call   <utfError@plt>
  jmp    L78
L86:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D26
data_type: string
name: extract_symbolic_data
arguments: data_tag: D50
data_type: string
name: extract_symbolic_data
arguments: data_tag: D58
data_type: string
name: extract_symbolic_data
arguments: data_tag: D77
data_type: string
name: extract_symbolic_data
arguments: data_tag: D62
data_type: string

tool: D26: ASSERT ERROR outputMaxLen>len

tool: D50: /scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/34benma/openjdk/refs/heads/jaklin-master/jdk/src/java.instrument/unix/native/libinstrument/EncodingSupport_md.c

tool: D58: ASSERT ERROR len>=0

tool: D77: ASSERT ERROR output

tool: D62: ASSERT ERROR bytes

assistant: ```c
int iconvConvert(iconv_t ic, char *bytes, int len, char *output, int outputMaxLen) {
  int outputLen = 0;
  ((bytes) == 0 ? utfError("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/34benma/openjdk/refs/heads/jaklin-master/jdk/src/java.instrument/unix/native/libinstrument/EncodingSupport_md.c", 122,
                           "ASSERT ERROR "
                           "bytes")
                : (void)0);
  ((len >= 0) == 0 ? utfError("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/34benma/openjdk/refs/heads/jaklin-master/jdk/src/java.instrument/unix/native/libinstrument/EncodingSupport_md.c", 123,
                              "ASSERT ERROR "
                              "len>=0")
                   : (void)0);
  ((output) == 0 ? utfError("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/34benma/openjdk/refs/heads/jaklin-master/jdk/src/java.instrument/unix/native/libinstrument/EncodingSupport_md.c", 124,
                            "ASSERT ERROR "
                            "output")
                 : (void)0);
  ((outputMaxLen > len) == 0 ? utfError("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/34benma/openjdk/refs/heads/jaklin-master/jdk/src/java.instrument/unix/native/libinstrument/EncodingSupport_md.c", 125,
                                        "ASSERT ERROR "
                                        "outputMaxLen>len")
                             : (void)0);
  output[0] = 0;
  outputLen = 0;
  if (ic != (iconv_t)-1) {
    int returnValue;
    size_t inLeft;
    size_t outLeft;
    char *inbuf;
    char *outbuf;
    inbuf = bytes;
    outbuf = output;
    inLeft = len;
    outLeft = outputMaxLen;
    returnValue = iconv(ic, (void *)&inbuf, &inLeft, &outbuf, &outLeft);
    if (returnValue >= 0 && inLeft == 0) {
      outputLen = outputMaxLen - outLeft;
      output[outputLen] = 0;
      return outputLen;
    }
    return -1;
  }
  outputLen = len;
  (void)memcpy(output, bytes, len);
  output[len] = 0;
  return outputLen;
}
```