user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<strnatcmp0>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %edx,-0x34(%rbp)
  movl   $0x0,-0x14(%rbp)
  mov    -0x14(%rbp),%eax
  mov    %eax,-0x18(%rbp)
L27:
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <to_int@plt>
  mov    %eax,-0x10(%rbp)
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <to_int@plt>
  mov    %eax,-0xc(%rbp)
  mov    -0x10(%rbp),%eax
  mov    %eax,%edi
  call   <nat_isdigit@plt>
  test   %rax,%rax
  je     L54
  mov    -0xc(%rbp),%eax
  mov    %eax,%edi
  call   <nat_isdigit@plt>
  test   %rax,%rax
  je     L54
  cmpl   $0x30,-0x10(%rbp)
  je     L66
  cmpl   $0x30,-0xc(%rbp)
  jne    L144
L66:
  mov    $0x1,%eax
  jmp    L21
L144:
  mov    $0x0,%eax
L21:
  mov    %eax,-0x8(%rbp)
  cmpl   $0x0,-0x8(%rbp)
  je     L80
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x18(%rbp),%eax
  movslq %eax,%rcx
  mov    -0x28(%rbp),%rax
  add    %rcx,%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <compare_left@plt>
  mov    %eax,-0x4(%rbp)
  cmpl   $0x0,-0x4(%rbp)
  je     L54
  mov    -0x4(%rbp),%eax
  jmp    L158
L80:
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x18(%rbp),%eax
  movslq %eax,%rcx
  mov    -0x28(%rbp),%rax
  add    %rcx,%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <compare_right@plt>
  mov    %eax,-0x4(%rbp)
  cmpl   $0x0,-0x4(%rbp)
  je     L54
  mov    -0x4(%rbp),%eax
  jmp    L158
L54:
  cmpl   $0x0,-0x10(%rbp)
  jne    L134
  cmpl   $0x0,-0xc(%rbp)
  jne    L134
  cmpl   $0x0,-0x34(%rbp)
  je     L146
  mov    -0x30(%rbp),%rdx
  mov    -0x28(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcasecmp@plt>
  jmp    L158
L146:
  mov    -0x30(%rbp),%rdx
  mov    -0x28(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  jmp    L158
L134:
  cmpl   $0x0,-0x34(%rbp)
  je     L75
  mov    -0x10(%rbp),%eax
  mov    %eax,%edi
  call   <nat_unify_case@plt>
  mov    %eax,-0x10(%rbp)
  mov    -0xc(%rbp),%eax
  mov    %eax,%edi
  call   <nat_unify_case@plt>
  mov    %eax,-0xc(%rbp)
L75:
  mov    -0x10(%rbp),%eax
  cmp    -0xc(%rbp),%eax
  jge    L55
  mov    $0xffffffff,%eax
  jmp    L158
L55:
  mov    -0x10(%rbp),%eax
  cmp    -0xc(%rbp),%eax
  jle    L31
  mov    $0x1,%eax
  jmp    L158
L31:
  addl   $0x1,-0x18(%rbp)
  addl   $0x1,-0x14(%rbp)
  jmp    L27
L158:
  leave
  ret
```

assistant: ```c
int strnatcmp0(char const *a, char const *b, int fold_case) {
  int ai, bi;
  int ca, cb;
  int fractional, result;
  ;
  ai = bi = 0;
  while (1) {
    ca = to_int(a[ai]);
    cb = to_int(b[bi]);
    if (nat_isdigit(ca) && nat_isdigit(cb)) {
      fractional = (ca == '0' || cb == '0');
      if (fractional) {
        if ((result = compare_left(a + ai, b + bi)) != 0)
          return result;
      } else {
        if ((result = compare_right(a + ai, b + bi)) != 0)
          return result;
      }
    }
    if (!ca && !cb) {
      if (fold_case)
        return strcasecmp(a, b);
      else
        return strcmp(a, b);
    }
    if (fold_case) {
      ca = nat_unify_case(ca);
      cb = nat_unify_case(cb);
    }
    if (ca < cb)
      return -1;
    else if (ca > cb)
      return +1;
    ++ai;
    ++bi;
  }
}
```