user: 请从给定的汇编指令推导出C源代码：

```asm
<luaO_chunkid>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %edx,-0x24(%rbp)
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x3d,%al
  jne    L47
  mov    -0x20(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x24(%rbp),%edx
  mov    -0x18(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncpy@plt>
  mov    -0x24(%rbp),%eax
  cltq
  lea    -0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  jmp    L19
L47:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x40,%al
  jne    L10
  addq   $0x1,-0x20(%rbp)
  mov    -0x24(%rbp),%eax
  sub    $0x8,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x20(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  mov    %eax,-0x4(%rbp)
  mov    -0x18(%rbp),%rax
  lea    D29(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  mov    -0x4(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jle    L60
  mov    -0x4(%rbp),%eax
  sub    -0x24(%rbp),%eax
  cltq
  add    %rax,-0x20(%rbp)
  mov    -0x18(%rbp),%rax
  lea    D32(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
L60:
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L19
L10:
  mov    -0x20(%rbp),%rax
  lea    D20(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcspn@plt>
  mov    %eax,-0x8(%rbp)
  mov    -0x24(%rbp),%eax
  sub    $0x11,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x8(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jle    L55
  mov    -0x24(%rbp),%eax
  mov    %eax,-0x8(%rbp)
L55:
  mov    -0x18(%rbp),%rax
  lea    D27(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  mov    -0x8(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L42
  mov    -0x8(%rbp),%edx
  mov    -0x20(%rbp),%rcx
  mov    -0x18(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  mov    -0x18(%rbp),%rax
  lea    D32(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L45
L42:
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
L45:
  mov    -0x18(%rbp),%rax
  lea    D8(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
L19:
  nop
  leave
  ret
```

tool_calls: name: retrieve_data
arguments: data_label: D29
type_guessed: string
name: retrieve_data
arguments: data_label: D32
type_guessed: string
name: retrieve_data
arguments: data_label: D20
type_guessed: string
name: retrieve_data
arguments: data_label: D27
type_guessed: string
name: retrieve_data
arguments: data_label: D8
type_guessed: string

tool: 

tool: D32: ...

tool: D20: 


tool: D27: [string "

tool: D8: "]

assistant: ```c
void luaO_chunkid(char *out, const char *source, int bufflen) {
  if (*source == '=') {
    strncpy(out, source + 1, bufflen);
    out[bufflen - 1] = '\0';
  } else {
    if (*source == '@') {
      int l;
      source++;
      bufflen -= sizeof(" `...' ");
      l = strlen(source);
      strcpy(out, "");
      if (l > bufflen) {
        source += (l - bufflen);
        strcat(out, "...");
      }
      strcat(out, source);
    } else {
      int len = strcspn(source, "\n");
      bufflen -= sizeof(" [string \"...\"] ");
      if (len > bufflen)
        len = bufflen;
      strcpy(out, "[string \"");
      if (source[len] != '\0') {
        strncat(out, source, len);
        strcat(out, "...");
      } else
        strcat(out, source);
      strcat(out, "\"]");
    }
  }
}
```