user: 这段汇编代码用C语言表示是什么样的?

```asm
<jvp_utf8_encode>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %edi,-0x24(%rbp)
  mov    %rsi,-0x30(%rbp)
  cmpl   $0x0,-0x24(%rbp)
  js     L12
  cmpl   $0x10ffff,-0x24(%rbp)
  jg     L12
  mov    $0x1,%eax
  jmp    L89
L12:
  mov    $0x0,%eax
L89:
  mov    %eax,%edi
  call   <assert@plt>
  mov    -0x30(%rbp),%rax
  mov    %rax,-0x18(%rbp)
  cmpl   $0x7f,-0x24(%rbp)
  jg     L52
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    -0x24(%rbp),%edx
  mov    %dl,(%rax)
  jmp    L7
L52:
  cmpl   $0x7ff,-0x24(%rbp)
  jg     L34
  mov    -0x24(%rbp),%eax
  sar    $0x6,%eax
  and    $0x1f,%eax
  lea    -0x40(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  jmp    L7
L34:
  cmpl   $0xffff,-0x24(%rbp)
  jg     L6
  mov    -0x24(%rbp),%eax
  sar    $0xc,%eax
  and    $0xf,%eax
  lea    -0x20(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  sar    $0x6,%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  jmp    L7
L6:
  mov    -0x24(%rbp),%eax
  sar    $0x12,%eax
  and    $0x7,%eax
  lea    -0x10(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  sar    $0xc,%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  sar    $0x6,%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  mov    -0x24(%rbp),%eax
  and    $0x3f,%eax
  lea    -0x80(%rax),%ecx
  mov    -0x30(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x30(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
L7:
  mov    -0x30(%rbp),%rax
  sub    -0x18(%rbp),%rax
  mov    %rax,%rbx
  mov    -0x24(%rbp),%eax
  mov    %eax,%edi
  call   <jvp_utf8_encode_length@plt>
  cltq
  cmp    %rax,%rbx
  sete   %al
  movzbl %al,%eax
  mov    %eax,%edi
  call   <assert@plt>
  mov    -0x30(%rbp),%rax
  sub    -0x18(%rbp),%rax
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
int jvp_utf8_encode(int codepoint, char *out) {
  assert(codepoint >= 0 && codepoint <= 0x10FFFF);
  char *start = out;
  if (codepoint <= 0x7F) {
    *out++ = codepoint;
  } else if (codepoint <= 0x7FF) {
    *out++ = 0xC0 + ((codepoint & 0x7C0) >> 6);
    *out++ = 0x80 + ((codepoint & 0x03F));
  } else if (codepoint <= 0xFFFF) {
    *out++ = 0xE0 + ((codepoint & 0xF000) >> 12);
    *out++ = 0x80 + ((codepoint & 0x0FC0) >> 6);
    *out++ = 0x80 + ((codepoint & 0x003F));
  } else {
    *out++ = 0xF0 + ((codepoint & 0x1C0000) >> 18);
    *out++ = 0x80 + ((codepoint & 0x03F000) >> 12);
    *out++ = 0x80 + ((codepoint & 0x000FC0) >> 6);
    *out++ = 0x80 + ((codepoint & 0x00003F));
  }
  assert(out - start == jvp_utf8_encode_length(codepoint));
  return out - start;
}
```