user: 请将以下的汇编代码转换成C语言代码：

```asm
<iw_print_retry_value>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  cmp    $0x13,%esi
  jle    L139
  mov    %edx,%r12d
  mov    %ecx,%ebx
  lea    -0x14(%rsi),%r13d
  mov    %r8d,%r14d
  test   $0x1,%cl
  jne    L18
L101:
  test   $0x2,%bl
  jne    L83
L66:
  test   $0x10,%bl
  jne    L73
L111:
  test   $0x20,%bl
  jne    L106
L128:
  test   $0x20,%bh
  jne    L33
  mov    %r12d,%ecx
  lea    D123(%rip),%rdx
  mov    %r13d,%esi
  mov    %rbp,%rdi
L151:
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  jmp    1070 <snprintf@plt>
  nopl   0x0(%rax)
L33:
  mov    %rbp,%rdi
  lea    D56(%rip),%rsi
  call   <strcpy@plt>
  and    $0x4,%ebx
  lea    0xa(%rbp),%rdi
  jne    L148
  cmp    $0xf423f,%r12d
  jg     L56
  cmp    $0x3e7,%r12d
  jle    L108
  pxor   %xmm0,%xmm0
  lea    D10(%rip),%rdx
  cvtsi2sd %r12d,%xmm0
  divsd  D53(%rip),%xmm0
L120:
  pop    %rbx
  mov    %r13d,%esi
  pop    %rbp
  mov    $0x1,%eax
  pop    %r12
  pop    %r13
  pop    %r14
  jmp    1070 <snprintf@plt>
  nopl   0x0(%rax,%rax,1)
L106:
  mov    %rbp,%rdi
  lea    D91(%rip),%rsi
  add    $0x6,%rbp
  call   <strcpy@plt>
  jmp    L128
L73:
  mov    %rbp,%rdi
  lea    D15(%rip),%rsi
  add    $0x6,%rbp
  call   <strcpy@plt>
  jmp    L111
  nopl   0x0(%rax,%rax,1)
L83:
  mov    %rbp,%rdi
  lea    D14(%rip),%rsi
  add    $0x4,%rbp
  call   <strcpy@plt>
  jmp    L66
  nopl   0x0(%rax,%rax,1)
L18:
  lea    D98(%rip),%rsi
  add    $0x4,%rbp
  call   <strcpy@plt>
  jmp    L101
  nopl   (%rax)
L139:
  pop    %rbx
  lea    D65(%rip),%rdx
  pop    %rbp
  xor    %eax,%eax
  pop    %r12
  pop    %r13
  pop    %r14
  jmp    1070 <snprintf@plt>
  xchg   %ax,%ax
L148:
  cmp    $0x14,%r14d
  jg     L84
  pxor   %xmm0,%xmm0
  cvtsi2sd %r12d,%xmm0
  divsd  D7(%rip),%xmm0
  cvttsd2si %xmm0,%r12d
L84:
  pop    %rbx
  mov    %r12d,%ecx
  pop    %rbp
  mov    %r13d,%esi
  pop    %r12
  lea    D20(%rip),%rdx
  pop    %r13
  xor    %eax,%eax
  pop    %r14
  jmp    1070 <snprintf@plt>
  nopl   0x0(%rax,%rax,1)
L108:
  mov    %r12d,%ecx
  lea    D54(%rip),%rdx
  mov    %r13d,%esi
  jmp    L151
  nopw   0x0(%rax,%rax,1)
L56:
  pxor   %xmm0,%xmm0
  lea    D132(%rip),%rdx
  cvtsi2sd %r12d,%xmm0
  divsd  D7(%rip),%xmm0
  jmp    L120
```

tool_calls: name: parse_data
arguments: data_label: D123
type_infered: string
name: parse_data
arguments: data_label: D56
type_infered: string
name: parse_data
arguments: data_label: D10
type_infered: string
name: parse_data
arguments: data_label: D53
type_infered: f64
name: parse_data
arguments: data_label: D91
type_infered: string
name: parse_data
arguments: data_label: D15
type_infered: string
name: parse_data
arguments: data_label: D14
type_infered: string
name: parse_data
arguments: data_label: D98
type_infered: string
name: parse_data
arguments: data_label: D65
type_infered: string
name: parse_data
arguments: data_label: D7
type_infered: f64
name: parse_data
arguments: data_label: D20
type_infered: string
name: parse_data
arguments: data_label: D54
type_infered: string
name: parse_data
arguments: data_label: D132
type_infered: string

tool: D123:  limit:%d

tool: D56:  lifetime:

tool: D10: %gms

tool: D53: 1000

tool: D91:   long

tool: D15:  short

tool: D14:  max

tool: D98:  min

tool: D65: <too big>

tool: D7: 1000000

tool: D20: %d

tool: D54: %dus

tool: D132: %gs

assistant: ```c
void iw_print_retry_value(char *buffer, int buflen, int value, int flags, int we_version) {
  if (buflen < 20) {
    snprintf(buffer, buflen, "<too big>");
    return;
  }
  buflen -= 20;
  if (flags & 0x0001) {
    strcpy(buffer, " min");
    buffer += 4;
  }
  if (flags & 0x0002) {
    strcpy(buffer, " max");
    buffer += 4;
  }
  if (flags & 0x0010) {
    strcpy(buffer, " short");
    buffer += 6;
  }
  if (flags & 0x0020) {
    strcpy(buffer, "  long");
    buffer += 6;
  }
  if (flags & 0x2000) {
    strcpy(buffer, " lifetime:");
    buffer += 10;
    if (flags & 0x0004) {
      if (we_version < 21)
        value /= 1e6;
      snprintf(buffer, buflen, "%d", value);
    } else {
      if (value >= (int)1e6)
        snprintf(buffer, buflen, "%gs", ((double)value) / 1e6);
      else if (value >= (int)1e3)
        snprintf(buffer, buflen, "%gms", ((double)value) / 1e3);
      else
        snprintf(buffer, buflen, "%dus", value);
    }
  } else
    snprintf(buffer, buflen, " limit:%d", value);
}
```