user: 请将这段汇编代码片段转换成等效的C代码：

```asm
<edflib_is_number>:
  endbr64
  push   %rbx
  mov    %rdi,%rbx
  call   <strlen@plt>
  mov    $0x1,%r10d
  test   %eax,%eax
  je     L103
  mov    %eax,%edi
  movzbl (%rbx),%eax
  sub    $0x2b,%eax
  test   $0xfd,%al
  sete   %al
  sete   %dl
  movzbl %dl,%edx
  cmp    %edx,%edi
  jle    L18
  movzbl %al,%eax
  mov    $0x0,%r10d
  mov    $0x0,%r8d
  mov    $0x0,%ecx
  mov    $0x1,%r11d
  jmp    L9
L246:
  mov    $0x1,%r10d
  test   %r8d,%r8d
  je     L103
  lea    0x1(%rax),%eax
  mov    $0x1,%r10d
  cmp    %eax,%edi
  je     L103
  movslq %eax,%rdx
  movzbl (%rbx,%rdx,1),%edx
  sub    $0x2b,%edx
  add    $0x2,%r9d
  test   $0xfd,%dl
  cmove  %r9d,%eax
  cmp    %eax,%edi
  jle    L120
  movslq %eax,%rsi
  lea    (%rbx,%rsi,1),%rdx
  lea    0x1(%rbx,%rsi,1),%rsi
  sub    $0x1,%edi
  sub    %eax,%edi
  add    %rdi,%rsi
  mov    $0x0,%r8d
  jmp    L195
L151:
  test   %r8d,%r8d
  je     L272
  add    $0x1,%ecx
L118:
  add    $0x1,%rax
  cmp    %eax,%edi
  jle    L141
L9:
  mov    %eax,%r9d
  movzbl (%rbx,%rax,1),%edx
  mov    %edx,%esi
  and    $0xffffffdf,%esi
  cmp    $0x45,%sil
  je     L246
  cmp    $0x20,%dl
  je     L151
  lea    -0x30(%rdx),%esi
  cmp    $0x9,%sil
  seta   %r9b
  cmp    $0x2e,%dl
  setne  %sil
  test   %sil,%r9b
  jne    L179
  test   %ecx,%ecx
  jne    L179
  cmp    $0x2e,%dl
  je     L262
  add    $0x1,%r8d
  mov    $0x0,%ecx
  jmp    L118
L262:
  test   %r10d,%r10d
  jne    L103
  mov    %r10d,%ecx
  mov    %r11d,%r10d
  jmp    L118
L140:
  test   %r8d,%r8d
  je     L142
  add    $0x1,%ecx
L31:
  add    $0x1,%rdx
  cmp    %rsi,%rdx
  je     L141
L195:
  movzbl (%rdx),%eax
  cmp    $0x20,%al
  je     L140
  sub    $0x30,%eax
  cmp    $0x9,%al
  ja     L124
  test   %ecx,%ecx
  jne    L124
  add    $0x1,%r8d
  jmp    L31
L120:
  mov    $0x0,%r8d
  jmp    L141
L272:
  mov    $0x1,%r10d
  jmp    L103
L179:
  mov    $0x1,%r10d
L103:
  mov    %r10d,%eax
  pop    %rbx
  ret
L142:
  mov    $0x1,%r10d
  jmp    L103
L124:
  mov    $0x1,%r10d
  jmp    L103
L18:
  mov    $0x0,%r8d
L141:
  test   %r8d,%r8d
  sete   %r10b
  movzbl %r10b,%r10d
  jmp    L103
```

assistant: ```c
int edflib_is_number(char *str) {
  int i = 0, l, hasspace = 0, hassign = 0, digit = 0, hasdot = 0, hasexp = 0;
  l = strlen(str);
  if (!l)
    return (1);
  if ((str[0] == '+') || (str[0] == '-')) {
    hassign++;
    i++;
  }
  for (; i < l; i++) {
    if ((str[i] == 'e') || (str[i] == 'E')) {
      if ((!digit) || hasexp) {
        return (1);
      }
      hasexp++;
      hassign = 0;
      digit = 0;
      break;
    }
    if (str[i] == ' ') {
      if (!digit) {
        return (1);
      }
      hasspace++;
    } else {
      if (((str[i] < 48) || (str[i] > 57)) && str[i] != '.') {
        return (1);
      } else {
        if (hasspace) {
          return (1);
        }
        if (str[i] == '.') {
          if (hasdot)
            return (1);
          hasdot++;
        } else {
          digit++;
        }
      }
    }
  }
  if (hasexp) {
    if (++i == l) {
      return (1);
    }
    if ((str[i] == '+') || (str[i] == '-')) {
      hassign++;
      i++;
    }
    for (; i < l; i++) {
      if (str[i] == ' ') {
        if (!digit) {
          return (1);
        }
        hasspace++;
      } else {
        if ((str[i] < 48) || (str[i] > 57)) {
          return (1);
        } else {
          if (hasspace) {
            return (1);
          }
          digit++;
        }
      }
    }
  }
  if (digit)
    return (0);
  else
    return (1);
}
```