ylfeng/ReF-Decompile-dataset huggingface dataset:
user: Translate the below assembly code into C programming language:

```asm
<fibonacci>:
  endbr64
  push   %rbp
  push   %rbx
  sub    $0x8,%rsp
  mov    %edi,%ebx
  test   %edi,%edi
  je     L2
  cmp    $0x1,%edi
  je     L2
  lea    -0x1(%rdi),%edi
  call   <fibonacci>
  mov    %eax,%ebp
  lea    -0x2(%rbx),%edi
  call   <fibonacci>
  lea    0x0(%rbp,%rax,1),%ebx
L2:
  mov    %ebx,%eax
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  ret
```

assistant: ```c
unsigned int fibonacci(unsigned int n) {
  if (n == 0) {
    return 0;
  } else if (n == 1) {
    return 1;
  }
  return fibonacci(n - 1) + fibonacci(n - 2);
}
```
user: 请将以下的汇编代码转换成C语言代码：

```asm
<usage>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x10,%rsp
  mov    %rdi,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  mov    %rax,%rsi
  lea    D15(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    D3(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D29(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D59(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D43(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D33(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D44(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rsi
  lea    D63(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  nop
  leave
  ret
```

tool_calls: name: read_data
arguments: data_tag: D15
type_guessed: string
name: read_data
arguments: data_tag: D3
type_guessed: string
name: read_data
arguments: data_tag: D29
type_guessed: string
name: read_data
arguments: data_tag: D59
type_guessed: string
name: read_data
arguments: data_tag: D43
type_guessed: string
name: read_data
arguments: data_tag: D33
type_guessed: string
name: read_data
arguments: data_tag: D44
type_guessed: string
name: read_data
arguments: data_tag: D63
type_guessed: string

tool: D15: Usage: %s <input_files>


tool: D3:   This program converts the given input files assumed to be

tool: D29:   in the subdue graph format to the new gbad-mdl / gbad-fsm

tool: D59:   graph format.  The converted graphs are written to

tool: D43:   <input>.g.  For example, running the following command

tool: D33:   would convert the file graph.g and write the result in a

tool: D44:   a file called graph.g.g:

tool: D63:     %s graph.g


assistant: ```c
void usage(char *exe_name) {
  printf("Usage: %s <input_files>\n", exe_name);
  printf("  This program converts the given input files assumed to be\n");
  printf("  in the subdue graph format to the new gbad-mdl / gbad-fsm\n");
  printf("  graph format.  The converted graphs are written to\n");
  printf("  <input>.g.  For example, running the following command\n");
  printf("  would convert the file graph.g and write the result in a\n");
  printf("  a file called graph.g.g:\n");
  printf("    %s graph.g\n", exe_name);
}
```
user: 请将这段汇编代码片段转换成等效的C代码：

```asm
<usage>:
  endbr64
  push   %rbx
  mov    %rdi,%rbx
  mov    %rdi,%rsi
  lea    D41(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    D53(%rip),%rdi
  call   <puts@plt>
  lea    D64(%rip),%rdi
  call   <puts@plt>
  lea    D62(%rip),%rdi
  call   <puts@plt>
  lea    D45(%rip),%rdi
  call   <puts@plt>
  lea    D65(%rip),%rdi
  call   <puts@plt>
  lea    D30(%rip),%rdi
  call   <puts@plt>
  mov    %rbx,%rsi
  lea    D4(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  pop    %rbx
  ret
```

tool_calls: name: retrieve_data
arguments: label: D41
data_type: string
name: retrieve_data
arguments: label: D53
data_type: string
name: retrieve_data
arguments: label: D64
data_type: string
name: retrieve_data
arguments: label: D62
data_type: string
name: retrieve_data
arguments: label: D45
data_type: string
name: retrieve_data
arguments: label: D65
data_type: string
name: retrieve_data
arguments: label: D30
data_type: string
name: retrieve_data
arguments: label: D4
data_type: string

tool: D41: Usage: %s <input_files>


tool: D53:   This program converts the given input files assumed to be

tool: D64:   in the subdue graph format to the new gbad-mdl / gbad-fsm

tool: D62:   graph format.  The converted graphs are written to

tool: D45:   <input>.g.  For example, running the following command

tool: D65:   would convert the file graph.g and write the result in a

tool: D30:   a file called graph.g.g:

tool: D4:     %s graph.g


assistant: ```c
void usage(char *exe_name) {
  printf("Usage: %s <input_files>\n", exe_name);
  printf("  This program converts the given input files assumed to be\n");
  printf("  in the subdue graph format to the new gbad-mdl / gbad-fsm\n");
  printf("  graph format.  The converted graphs are written to\n");
  printf("  <input>.g.  For example, running the following command\n");
  printf("  would convert the file graph.g and write the result in a\n");
  printf("  a file called graph.g.g:\n");
  printf("    %s graph.g\n", exe_name);
}
```
user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<usage>:
  endbr64
  push   %rbp
  mov    %rdi,%rsi
  mov    %rdi,%rbp
  xor    %eax,%eax
  lea    D76(%rip),%rdi
  call   <printf@plt>
  lea    D25(%rip),%rdi
  call   <puts@plt>
  lea    D29(%rip),%rdi
  call   <puts@plt>
  lea    D45(%rip),%rdi
  call   <puts@plt>
  lea    D38(%rip),%rdi
  call   <puts@plt>
  lea    D77(%rip),%rdi
  call   <puts@plt>
  lea    D34(%rip),%rdi
  call   <puts@plt>
  mov    %rbp,%rsi
  lea    D57(%rip),%rdi
  xor    %eax,%eax
  pop    %rbp
  jmp    1070 <printf@plt>
```

tool_calls: name: retrieve_data
arguments: tag: D76
type: string
name: retrieve_data
arguments: tag: D25
type: string
name: retrieve_data
arguments: tag: D29
type: string
name: retrieve_data
arguments: tag: D45
type: string
name: retrieve_data
arguments: tag: D38
type: string
name: retrieve_data
arguments: tag: D77
type: string
name: retrieve_data
arguments: tag: D34
type: string
name: retrieve_data
arguments: tag: D57
type: string

tool: D76: Usage: %s <input_files>


tool: D25:   This program converts the given input files assumed to be

tool: D29:   in the subdue graph format to the new gbad-mdl / gbad-fsm

tool: D45:   graph format.  The converted graphs are written to

tool: D38:   <input>.g.  For example, running the following command

tool: D77:   would convert the file graph.g and write the result in a

tool: D34:   a file called graph.g.g:

tool: D57:     %s graph.g


assistant: ```c
void usage(char *exe_name) {
  printf("Usage: %s <input_files>\n", exe_name);
  printf("  This program converts the given input files assumed to be\n");
  printf("  in the subdue graph format to the new gbad-mdl / gbad-fsm\n");
  printf("  graph format.  The converted graphs are written to\n");
  printf("  <input>.g.  For example, running the following command\n");
  printf("  would convert the file graph.g and write the result in a\n");
  printf("  a file called graph.g.g:\n");
  printf("    %s graph.g\n", exe_name);
}
```
user: What would the C source look like for the assembly code provided here?

```asm
<usage>:
  endbr64
  push   %rbp
  mov    %rdi,%rsi
  mov    %rdi,%rbp
  xor    %eax,%eax
  lea    D20(%rip),%rdi
  call   <printf@plt>
  lea    D62(%rip),%rdi
  call   <puts@plt>
  lea    D2(%rip),%rdi
  call   <puts@plt>
  lea    D4(%rip),%rdi
  call   <puts@plt>
  lea    D72(%rip),%rdi
  call   <puts@plt>
  lea    D37(%rip),%rdi
  call   <puts@plt>
  lea    D65(%rip),%rdi
  call   <puts@plt>
  mov    %rbp,%rsi
  lea    D22(%rip),%rdi
  xor    %eax,%eax
  pop    %rbp
  jmp    1070 <printf@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D20
datatype: string
name: extract_symbolic_data
arguments: data_tag: D62
datatype: string
name: extract_symbolic_data
arguments: data_tag: D2
datatype: string
name: extract_symbolic_data
arguments: data_tag: D4
datatype: string
name: extract_symbolic_data
arguments: data_tag: D72
datatype: string
name: extract_symbolic_data
arguments: data_tag: D37
datatype: string
name: extract_symbolic_data
arguments: data_tag: D65
datatype: string
name: extract_symbolic_data
arguments: data_tag: D22
datatype: string

tool: D20: Usage: %s <input_files>


tool: D62:   This program converts the given input files assumed to be

tool: D2:   in the subdue graph format to the new gbad-mdl / gbad-fsm

tool: D4:   graph format.  The converted graphs are written to

tool: D72:   <input>.g.  For example, running the following command

tool: D37:   would convert the file graph.g and write the result in a

tool: D65:   a file called graph.g.g:

tool: D22:     %s graph.g


assistant: ```c
void usage(char *exe_name) {
  printf("Usage: %s <input_files>\n", exe_name);
  printf("  This program converts the given input files assumed to be\n");
  printf("  in the subdue graph format to the new gbad-mdl / gbad-fsm\n");
  printf("  graph format.  The converted graphs are written to\n");
  printf("  <input>.g.  For example, running the following command\n");
  printf("  would convert the file graph.g and write the result in a\n");
  printf("  a file called graph.g.g:\n");
  printf("    %s graph.g\n", exe_name);
}
```
user: 请从给定的汇编指令推导出C源代码:

```asm
<next_hop>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %edi,-0x14(%rbp)
  mov    %esi,-0x18(%rbp)
  mov    %rdx,-0x20(%rbp)
  mov    -0x14(%rbp),%eax
  add    $0x1,%eax
  add    %eax,%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    %rax,-0x8(%rbp)
  movl   $0x1,-0x10(%rbp)
  jmp    L9
L1:
  mov    -0x10(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  jmp    L19
L0:
  mov    -0xc(%rbp),%eax
  lea    (%rax,%rax,1),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movzwl (%rax),%eax
  movzwl %ax,%eax
  mov    %eax,-0xc(%rbp)
L19:
  mov    -0xc(%rbp),%eax
  lea    (%rax,%rax,1),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movzwl (%rax),%eax
  movzwl %ax,%eax
  cmp    %eax,-0x18(%rbp)
  jne    L0
  mov    -0x10(%rbp),%eax
  lea    (%rax,%rax,1),%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  mov    -0xc(%rbp),%edx
  mov    %dx,(%rax)
  addl   $0x1,-0x10(%rbp)
L9:
  mov    -0x10(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jbe    L1
  mov    -0x8(%rbp),%rax
  leave
  ret
```

assistant: ```c
unsigned short *next_hop(unsigned size, unsigned vertex, unsigned short *parent) {
  unsigned short *hop = malloc((size + 1) * sizeof(unsigned short));
  unsigned i, j;
  for (i = 1; i <= size; i++) {
    j = i;
    while (parent[j] != vertex) {
      j = parent[j];
    }
    hop[i] = j;
  }
  return hop;
}
```
user: 请将以下的汇编代码转换成C语言代码：

```asm
<next_hop>:
  endbr64
  push   %r12
  push   %rbp
  push   %rbx
  mov    %edi,%r12d
  mov    %esi,%ebx
  mov    %rdx,%rbp
  lea    0x2(%rdi,%rdi,1),%edi
  call   <malloc@plt>
  test   %r12d,%r12d
  je     L20
  mov    $0x1,%esi
L16:
  mov    %esi,%edx
L6:
  mov    %edx,%ecx
  mov    %edx,%edx
  movzwl 0x0(%rbp,%rdx,2),%edx
  cmp    %ebx,%edx
  jne    L6
  mov    %esi,%edx
  mov    %cx,(%rax,%rdx,2)
  add    $0x1,%esi
  cmp    %esi,%r12d
  jae    L16
L20:
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
```

assistant: ```c
unsigned short *next_hop(unsigned size, unsigned vertex, unsigned short *parent) {
  unsigned short *hop = malloc((size + 1) * sizeof(unsigned short));
  unsigned i, j;
  for (i = 1; i <= size; i++) {
    j = i;
    while (parent[j] != vertex) {
      j = parent[j];
    }
    hop[i] = j;
  }
  return hop;
}
```
user: What would the C source look like for the assembly code provided here?

```asm
<next_hop>:
  endbr64
  push   %r12
  mov    %edi,%r12d
  lea    0x2(%rdi,%rdi,1),%edi
  push   %rbp
  mov    %rdx,%rbp
  push   %rbx
  mov    %esi,%ebx
  call   <malloc@plt>
  test   %r12d,%r12d
  je     L5
  mov    $0x1,%edx
  nopl   0x0(%rax,%rax,1)
L3:
  mov    %edx,%ecx
  nopw   0x0(%rax,%rax,1)
L23:
  mov    %ecx,%ecx
  mov    %rcx,%rdi
  movzwl 0x0(%rbp,%rcx,2),%ecx
  cmp    %ebx,%ecx
  jne    L23
  mov    %edx,%ecx
  add    $0x1,%edx
  mov    %di,(%rax,%rcx,2)
  cmp    %edx,%r12d
  jae    L3
L5:
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
```

assistant: ```c
unsigned short *next_hop(unsigned size, unsigned vertex, unsigned short *parent) {
  unsigned short *hop = malloc((size + 1) * sizeof(unsigned short));
  unsigned i, j;
  for (i = 1; i <= size; i++) {
    j = i;
    while (parent[j] != vertex) {
      j = parent[j];
    }
    hop[i] = j;
  }
  return hop;
}
```
user: Demonstrate the C code that generates the assembly output below:

```asm
<next_hop>:
  endbr64
  push   %r12
  mov    %edi,%r12d
  lea    0x2(%rdi,%rdi,1),%edi
  push   %rbp
  mov    %rdx,%rbp
  push   %rbx
  mov    %esi,%ebx
  call   <malloc@plt>
  test   %r12d,%r12d
  je     L3
  mov    $0x1,%edx
  nopl   0x0(%rax,%rax,1)
L4:
  mov    %edx,%ecx
  nopw   0x0(%rax,%rax,1)
L5:
  mov    %ecx,%ecx
  mov    %rcx,%rdi
  movzwl 0x0(%rbp,%rcx,2),%ecx
  cmp    %ebx,%ecx
  jne    L5
  mov    %edx,%ecx
  add    $0x1,%edx
  mov    %di,(%rax,%rcx,2)
  cmp    %edx,%r12d
  jae    L4
L3:
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
```

assistant: ```c
unsigned short *next_hop(unsigned size, unsigned vertex, unsigned short *parent) {
  unsigned short *hop = malloc((size + 1) * sizeof(unsigned short));
  unsigned i, j;
  for (i = 1; i <= size; i++) {
    j = i;
    while (parent[j] != vertex) {
      j = parent[j];
    }
    hop[i] = j;
  }
  return hop;
}
```
user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<crc_cal_by_bit>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x18(%rbp)
  mov    %esi,-0x1c(%rbp)
  movl   $0x0,-0x4(%rbp)
  jmp    L36
L27:
  movb   $0x80,-0x5(%rbp)
  jmp    L12
L54:
  shll   -0x4(%rbp)
  mov    -0x4(%rbp),%eax
  and    $0x10000,%eax
  test   %eax,%eax
  je     L49
  xorl   $0x11021,-0x4(%rbp)
L49:
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  and    -0x5(%rbp),%al
  test   %al,%al
  je     L32
  xorl   $0x1021,-0x4(%rbp)
L32:
  movzbl -0x5(%rbp),%eax
  shr    %al
  mov    %al,-0x5(%rbp)
L12:
  cmpb   $0x0,-0x5(%rbp)
  jne    L54
  addq   $0x1,-0x18(%rbp)
L36:
  mov    -0x1c(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    %edx,-0x1c(%rbp)
  test   %eax,%eax
  jne    L27
  mov    -0x4(%rbp),%eax
  pop    %rbp
  ret
```

assistant: ```c
unsigned int crc_cal_by_bit(const unsigned char *ptr, unsigned int len) {
  unsigned int crc = 0;
  unsigned char i;
  while (len-- != 0) {
    for (i = 0x80; i != 0; i /= 2) {
      crc *= 2;
      if ((crc & 0x10000) != 0)
        crc ^= 0x11021;
      if ((*ptr & i) != 0)
        crc ^= 0x1021;
    }
    ptr++;
  }
  return crc;
}
```
user: 提供的汇编代码用C语言表示会是什么样子：

```asm
<crc_cal_by_bit>:
  endbr64
  lea    -0x1(%rsi),%eax
  test   %esi,%esi
  je     L29
  mov    %eax,%eax
  lea    0x1(%rdi,%rax,1),%r10
  mov    $0x0,%eax
  mov    $0xffffff80,%r9d
  jmp    L34
L18:
  add    $0x1,%rdi
  cmp    %r10,%rdi
  je     L16
L34:
  movzbl (%rdi),%r8d
  mov    $0x8,%ecx
  mov    %r9d,%edx
L46:
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   %dl,%r8b
  cmovne %esi,%eax
  shr    %dl
  sub    $0x1,%ecx
  jne    L46
  jmp    L18
L29:
  mov    %esi,%eax
L16:
  ret
```

assistant: ```c
unsigned int crc_cal_by_bit(const unsigned char *ptr, unsigned int len) {
  unsigned int crc = 0;
  unsigned char i;
  while (len-- != 0) {
    for (i = 0x80; i != 0; i /= 2) {
      crc *= 2;
      if ((crc & 0x10000) != 0)
        crc ^= 0x11021;
      if ((*ptr & i) != 0)
        crc ^= 0x1021;
    }
    ptr++;
  }
  return crc;
}
```
user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<crc_cal_by_bit>:
  endbr64
  test   %esi,%esi
  je     L4
  mov    %esi,%esi
  xor    %eax,%eax
  lea    (%rdi,%rsi,1),%r9
L16:
  movzbl (%rdi),%r8d
  mov    $0x8,%ecx
  mov    $0xffffff80,%edx
  xchg   %ax,%ax
L23:
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   %dl,%r8b
  cmovne %esi,%eax
  shr    %dl
  sub    $0x1,%ecx
  jne    L23
  add    $0x1,%rdi
  cmp    %r9,%rdi
  jne    L16
  ret
L4:
  xor    %eax,%eax
  ret
```

assistant: ```c
unsigned int crc_cal_by_bit(const unsigned char *ptr, unsigned int len) {
  unsigned int crc = 0;
  unsigned char i;
  while (len-- != 0) {
    for (i = 0x80; i != 0; i /= 2) {
      crc *= 2;
      if ((crc & 0x10000) != 0)
        crc ^= 0x11021;
      if ((*ptr & i) != 0)
        crc ^= 0x1021;
    }
    ptr++;
  }
  return crc;
}
```
user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<crc_cal_by_bit>:
  endbr64
  mov    %rdi,%rcx
  test   %esi,%esi
  je     L19
  mov    %esi,%esi
  xor    %eax,%eax
  lea    (%rdi,%rsi,1),%rdi
  nopw   0x0(%rax,%rax,1)
L16:
  add    %eax,%eax
  movzbl (%rcx),%edx
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   %dl,%dl
  cmovs  %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x40,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x20,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x10,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x8,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x4,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  test   $0x2,%dl
  cmovne %esi,%eax
  add    %eax,%eax
  mov    %eax,%esi
  xor    $0x11021,%esi
  test   $0x10000,%eax
  cmovne %esi,%eax
  mov    %eax,%esi
  xor    $0x1021,%esi
  and    $0x1,%edx
  cmovne %esi,%eax
  add    $0x1,%rcx
  cmp    %rcx,%rdi
  jne    L16
  ret
L19:
  xor    %eax,%eax
  ret
```

assistant: ```c
unsigned int crc_cal_by_bit(const unsigned char *ptr, unsigned int len) {
  unsigned int crc = 0;
  unsigned char i;
  while (len-- != 0) {
    for (i = 0x80; i != 0; i /= 2) {
      crc *= 2;
      if ((crc & 0x10000) != 0)
        crc ^= 0x11021;
      if ((*ptr & i) != 0)
        crc ^= 0x1021;
    }
    ptr++;
  }
  return crc;
}
```
user: Please show me the C implementation that matches the assembly code listed below:

```asm
<vzctl_get_normalized_guid>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %edx,-0x34(%rbp)
  cmpl   $0x26,-0x34(%rbp)
  jg     L160
  mov    $0xffffffff,%eax
  jmp    L159
L160:
  mov    -0x28(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x7b,%al
  jne    L93
  mov    -0x28(%rbp),%rax
  add    $0x1,%rax
  jmp    L196
L93:
  mov    -0x28(%rbp),%rax
L196:
  mov    %rax,-0x10(%rbp)
  mov    -0x30(%rbp),%rax
  movb   $0x7b,(%rax)
  mov    -0x30(%rbp),%rax
  add    $0x1,%rax
  mov    %rax,-0x8(%rbp)
  movl   $0x0,-0x14(%rbp)
  jmp    L163
L74:
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L136
  cmpl   $0x8,-0x14(%rbp)
  je     L38
  cmpl   $0xd,-0x14(%rbp)
  je     L38
  cmpl   $0x12,-0x14(%rbp)
  je     L38
  cmpl   $0x17,-0x14(%rbp)
  jne    L137
L38:
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  cmp    $0x2d,%al
  je     L183
  jmp    L133
L137:
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <isxdigit@plt>
  test   %eax,%eax
  je     L33
L183:
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    -0x14(%rbp),%edx
  movslq %edx,%rcx
  mov    -0x8(%rbp),%rdx
  add    %rcx,%rdx
  movzbl (%rax),%eax
  mov    %al,(%rdx)
  addl   $0x1,-0x14(%rbp)
L163:
  cmpl   $0x23,-0x14(%rbp)
  jle    L74
  jmp    L133
L136:
  nop
  jmp    L133
L33:
  nop
L133:
  cmpl   $0x23,-0x14(%rbp)
  jg     L59
  mov    $0x1,%eax
  jmp    L159
L59:
  mov    -0x10(%rbp),%rax
  add    $0x24,%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L79
  mov    -0x10(%rbp),%rax
  add    $0x24,%rax
  movzbl (%rax),%eax
  cmp    $0x7d,%al
  jne    L43
  mov    -0x10(%rbp),%rax
  add    $0x25,%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L79
L43:
  mov    $0x1,%eax
  jmp    L159
L79:
  mov    -0x8(%rbp),%rax
  add    $0x24,%rax
  movb   $0x7d,(%rax)
  mov    -0x8(%rbp),%rax
  add    $0x25,%rax
  movb   $0x0,(%rax)
  mov    $0x0,%eax
L159:
  leave
  ret
```

assistant: ```c
int vzctl_get_normalized_guid(const char *str, char *buf, int len) {
  int i;
  const char *in;
  char *out;
  if (len < 36 + 3)
    return -1;
  in = (str[0] == '{') ? str + 1 : str;
  buf[0] = '{';
  out = buf + 1;
  for (i = 0; i < 36; i++) {
    if (in[i] == '\0')
      break;
    if ((i == 8) || (i == 13) || (i == 18) || (i == 23)) {
      if (in[i] != '-')
        break;
    } else if (!isxdigit(in[i])) {
      break;
    }
    out[i] = in[i];
  }
  if (i < 36)
    return 1;
  if (in[36] != '\0' && (in[36] != '}' || in[36 + 1] != '\0'))
    return 1;
  out[36] = '}';
  out[36 + 1] = '\0';
  return 0;
}
```
user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<vzctl_get_normalized_guid>:
  endbr64
  mov    $0xffffffff,%eax
  cmp    $0x26,%edx
  jle    L55
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rdi,%rbp
  mov    %rsi,%r12
  cmpb   $0x7b,(%rdi)
  sete   %al
  movzbl %al,%eax
  add    %rax,%rbp
  movb   $0x7b,(%rsi)
  mov    $0x0,%ebx
  mov    $0x842100,%r14d
  jmp    L102
L36:
  cmp    $0x2d,%dil
  jne    L122
L43:
  movzbl 0x0(%rbp,%rbx,1),%eax
  mov    %al,0x1(%r12,%rbx,1)
  add    $0x1,%rbx
  cmp    $0x24,%rbx
  je     L39
L102:
  mov    %ebx,%r13d
  movzbl 0x0(%rbp,%rbx,1),%edi
  test   %dil,%dil
  je     L45
  cmp    $0x17,%ebx
  ja     L2
  bt     %rbx,%r14
  jb     L36
L2:
  movsbl %dil,%edi
  call   <isxdigit@plt>
  test   %eax,%eax
  jne    L43
L45:
  mov    $0x1,%eax
  cmp    $0x23,%r13d
  jle    L81
L39:
  movzbl 0x24(%rbp),%edx
  test   %dl,%dl
  je     L46
  mov    $0x1,%eax
  cmp    $0x7d,%dl
  jne    L81
  cmpb   $0x0,0x25(%rbp)
  jne    L81
L46:
  movb   $0x7d,0x25(%r12)
  movb   $0x0,0x26(%r12)
  mov    $0x0,%eax
L81:
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L122:
  mov    $0x1,%eax
  jmp    L81
L55:
  ret
```

assistant: ```c
int vzctl_get_normalized_guid(const char *str, char *buf, int len) {
  int i;
  const char *in;
  char *out;
  if (len < 36 + 3)
    return -1;
  in = (str[0] == '{') ? str + 1 : str;
  buf[0] = '{';
  out = buf + 1;
  for (i = 0; i < 36; i++) {
    if (in[i] == '\0')
      break;
    if ((i == 8) || (i == 13) || (i == 18) || (i == 23)) {
      if (in[i] != '-')
        break;
    } else if (!isxdigit(in[i])) {
      break;
    }
    out[i] = in[i];
  }
  if (i < 36)
    return 1;
  if (in[36] != '\0' && (in[36] != '}' || in[36 + 1] != '\0'))
    return 1;
  out[36] = '}';
  out[36 + 1] = '\0';
  return 0;
}
```