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

```asm
<ECDH_KDF_X9_62>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x58,%rsp
  mov    %rdx,-0x50(%rbp)
  mov    %rcx,-0x58(%rbp)
  mov    %r8,-0x60(%rbp)
  mov    %r9,-0x68(%rbp)
  mov    0x10(%rbp),%r15
  mov    %r15,-0x70(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  cmp    $0x40000000,%rsi
  seta   %al
  cmp    $0x40000000,%rcx
  seta   %dl
  or     %dl,%al
  jne    L85
  mov    %rdi,%r14
  mov    %rsi,%rbx
  cmp    $0x40000000,%r9
  jbe    L124
L85:
  mov    $0x0,%r12d
L87:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L122
  mov    %r12d,%eax
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
L124:
  mov    $0x0,%eax
  call   <EVP_MD_CTX_new@plt>
  mov    %rax,%r13
  mov    $0x0,%r12d
  test   %rax,%rax
  je     L87
  mov    %r15,%rdi
  call   <EVP_MD_size@plt>
  mov    %rax,-0x48(%rbp)
  mov    $0x1,%r12d
  mov    %rbx,%rax
  mov    %r12d,%ebx
  mov    %rax,%r12
  jmp    L158
L53:
  mov    %rcx,%rax
  and    $0xfff,%eax
  sub    %rax,%rsp
  test   %rax,%rax
  je     L71
  orq    $0x0,-0x8(%rsp,%rax,1)
L71:
  mov    %rsp,-0x78(%rbp)
  mov    $0x0,%edx
  mov    -0x70(%rbp),%rsi
  mov    %r13,%rdi
  call   <EVP_DigestInit_ex@plt>
  test   %eax,%eax
  je     L152
  mov    %bl,-0x39(%rbp)
  movzbl %bh,%eax
  mov    %al,-0x3a(%rbp)
  mov    %ebx,%eax
  shr    $0x10,%eax
  mov    %al,-0x3b(%rbp)
  mov    %ebx,%eax
  shr    $0x18,%eax
  mov    %al,-0x3c(%rbp)
  mov    -0x58(%rbp),%rdx
  mov    -0x50(%rbp),%rsi
  mov    %r13,%rdi
  call   <EVP_DigestUpdate@plt>
  test   %eax,%eax
  je     L152
  lea    -0x3c(%rbp),%rsi
  mov    $0x4,%edx
  mov    %r13,%rdi
  call   <EVP_DigestUpdate@plt>
  test   %eax,%eax
  je     L152
  mov    -0x68(%rbp),%rdx
  mov    -0x60(%rbp),%rsi
  mov    %r13,%rdi
  call   <EVP_DigestUpdate@plt>
  test   %eax,%eax
  je     L152
  cmp    -0x48(%rbp),%r12
  jb     L155
  mov    $0x0,%edx
  mov    %r14,%rsi
  mov    %r13,%rdi
  call   <EVP_DigestFinal@plt>
  test   %eax,%eax
  je     L152
  mov    -0x48(%rbp),%rax
  sub    %rax,%r12
  je     L145
  add    %rax,%r14
  mov    %r15,%rsp
  add    $0x1,%ebx
L158:
  mov    %rsp,%r15
  mov    D0(%rip),%rax
  movslq (%rax),%rax
  add    $0xf,%rax
  mov    %rax,%rcx
  and    $0xfffffffffffffff0,%rcx
  and    $0xfffffffffffff000,%rax
  mov    %rsp,%rdx
  sub    %rax,%rdx
L26:
  cmp    %rdx,%rsp
  je     L53
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L26
L155:
  mov    %r12,%rbx
  mov    $0x0,%edx
  mov    -0x78(%rbp),%r12
  mov    %r12,%rsi
  mov    %r13,%rdi
  call   <EVP_DigestFinal@plt>
  test   %eax,%eax
  jne    L70
L152:
  mov    %r15,%rsp
  mov    $0x0,%r12d
L95:
  mov    %r13,%rdi
  call   <EVP_MD_CTX_free@plt>
  jmp    L87
L70:
  mov    %rbx,%rdx
  mov    %r12,%rsi
  mov    %r14,%rdi
  call   <memcpy@plt>
  mov    -0x48(%rbp),%rsi
  mov    %r12,%rdi
  call   <OPENSSL_cleanse@plt>
L145:
  mov    %r15,%rsp
  mov    $0x1,%r12d
  jmp    L95
L122:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
int ECDH_KDF_X9_62(unsigned char *out, size_t outlen, const unsigned char *Z, size_t Zlen, const unsigned char *sinfo, size_t sinfolen, const EVP_MD *md) {
  EVP_MD_CTX *mctx = NULL;
  int rv = 0;
  unsigned int i;
  size_t mdlen;
  unsigned char ctr[4];
  if (sinfolen > (1 << 30) || outlen > (1 << 30) || Zlen > (1 << 30))
    return 0;
  mctx = EVP_MD_CTX_new();
  if (mctx == NULL)
    return 0;
  mdlen = EVP_MD_size(md);
  for (i = 1;; i++) {
    unsigned char mtmp[EVP_MAX_MD_SIZE];
    if (!EVP_DigestInit_ex(mctx, md, NULL))
      goto err;
    ctr[3] = i & 0xFF;
    ctr[2] = (i >> 8) & 0xFF;
    ctr[1] = (i >> 16) & 0xFF;
    ctr[0] = (i >> 24) & 0xFF;
    if (!EVP_DigestUpdate(mctx, Z, Zlen))
      goto err;
    if (!EVP_DigestUpdate(mctx, ctr, sizeof(ctr)))
      goto err;
    if (!EVP_DigestUpdate(mctx, sinfo, sinfolen))
      goto err;
    if (outlen >= mdlen) {
      if (!EVP_DigestFinal(mctx, out, NULL))
        goto err;
      outlen -= mdlen;
      if (outlen == 0)
        break;
      out += mdlen;
    } else {
      if (!EVP_DigestFinal(mctx, mtmp, NULL))
        goto err;
      memcpy(out, mtmp, outlen);
      OPENSSL_cleanse(mtmp, mdlen);
      break;
    }
  }
  rv = 1;
err:
  EVP_MD_CTX_free(mctx);
  return rv;
}
```