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

```asm
<encrypt>:
  endbr64
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x510,%rsp
  mov    %rdi,%rbp
  mov    %fs:0x28,%rax
  mov    %rax,0x508(%rsp)
  xor    %eax,%eax
  movq   $0x0,0x120(%rsp)
  movq   $0x0,0x128(%rsp)
  lea    0x130(%rsp),%rdi
  mov    $0x7b,%ecx
  rep stos %rax,%es:(%rdi)
  lea    D159(%rip),%rax
  mov    %rax,(%rsp)
  lea    D375(%rip),%rax
  mov    %rax,0x8(%rsp)
  lea    D11(%rip),%rax
  mov    %rax,0x10(%rsp)
  lea    D169(%rip),%rax
  mov    %rax,0x18(%rsp)
  lea    D244(%rip),%rax
  mov    %rax,0x20(%rsp)
  lea    D123(%rip),%rax
  mov    %rax,0x28(%rsp)
  lea    D290(%rip),%rax
  mov    %rax,0x30(%rsp)
  lea    D165(%rip),%rax
  mov    %rax,0x38(%rsp)
  lea    D356(%rip),%rax
  mov    %rax,0x40(%rsp)
  lea    D363(%rip),%rax
  mov    %rax,0x48(%rsp)
  lea    D317(%rip),%rax
  mov    %rax,0x50(%rsp)
  lea    D256(%rip),%rax
  mov    %rax,0x58(%rsp)
  lea    D350(%rip),%rax
  mov    %rax,0x60(%rsp)
  lea    D191(%rip),%rax
  mov    %rax,0x68(%rsp)
  lea    D204(%rip),%rax
  mov    %rax,0x70(%rsp)
  lea    D315(%rip),%rax
  mov    %rax,0x78(%rsp)
  lea    D312(%rip),%rax
  mov    %rax,0x80(%rsp)
  lea    D333(%rip),%rax
  mov    %rax,0x88(%rsp)
  lea    D377(%rip),%rax
  mov    %rax,0x90(%rsp)
  lea    D38(%rip),%rax
  mov    %rax,0x98(%rsp)
  lea    D162(%rip),%rax
  mov    %rax,0xa0(%rsp)
  lea    D292(%rip),%rax
  mov    %rax,0xa8(%rsp)
  lea    D196(%rip),%rax
  mov    %rax,0xb0(%rsp)
  lea    D379(%rip),%rax
  mov    %rax,0xb8(%rsp)
  lea    D341(%rip),%rax
  mov    %rax,0xc0(%rsp)
  lea    D87(%rip),%rax
  mov    %rax,0xc8(%rsp)
  lea    D104(%rip),%rax
  mov    %rax,0xd0(%rsp)
  lea    D257(%rip),%rax
  mov    %rax,0xd8(%rsp)
  lea    D129(%rip),%rax
  mov    %rax,0xe0(%rsp)
  lea    D151(%rip),%rax
  mov    %rax,0xe8(%rsp)
  lea    D264(%rip),%rax
  mov    %rax,0xf0(%rsp)
  lea    D326(%rip),%rax
  mov    %rax,0xf8(%rsp)
  lea    D245(%rip),%rax
  mov    %rax,0x100(%rsp)
  lea    D134(%rip),%rax
  mov    %rax,0x108(%rsp)
  lea    D195(%rip),%rax
  mov    %rax,0x110(%rsp)
  lea    D81(%rip),%rax
  mov    %rax,0x118(%rsp)
  mov    %rbp,%rdi
  call   <strlen@plt>
  test   %eax,%eax
  jle    L40
  mov    %rbp,%rbx
  lea    -0x1(%rax),%eax
  lea    0x1(%rbp,%rax,1),%rbp
  lea    D232(%rip),%r12
  jmp    L68
L28:
  movsbl %al,%eax
  sub    $0x41,%eax
  cltq
  mov    0x50(%rsp,%rax,8),%rsi
  lea    0x120(%rsp),%rdi
  call   <strcat@plt>
L51:
  add    $0x1,%rbx
  cmp    %rbp,%rbx
  je     L40
L68:
  movzbl (%rbx),%eax
  cmp    $0x20,%al
  je     L23
  lea    -0x30(%rax),%edx
  cmp    $0x9,%dl
  ja     L28
  movsbl %al,%eax
  sub    $0x30,%eax
  cltq
  mov    (%rsp,%rax,8),%rsi
  lea    0x120(%rsp),%rdi
  call   <strcat@plt>
  jmp    L51
L23:
  lea    0x120(%rsp),%rdi
  mov    %r12,%rsi
  call   <strcat@plt>
  jmp    L51
L40:
  lea    0x120(%rsp),%rsi
  lea    D319(%rip),%rdi
  call   <printf@plt>
  mov    0x508(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L74
  add    $0x510,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
L74:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: retrieve_data
arguments: label: D159
type_guessed: string
name: retrieve_data
arguments: label: D375
type_guessed: string
name: retrieve_data
arguments: label: D11
type_guessed: string
name: retrieve_data
arguments: label: D169
type_guessed: string
name: retrieve_data
arguments: label: D244
type_guessed: string
name: retrieve_data
arguments: label: D123
type_guessed: string
name: retrieve_data
arguments: label: D290
type_guessed: string
name: retrieve_data
arguments: label: D165
type_guessed: string
name: retrieve_data
arguments: label: D356
type_guessed: string
name: retrieve_data
arguments: label: D363
type_guessed: string
name: retrieve_data
arguments: label: D317
type_guessed: string
name: retrieve_data
arguments: label: D256
type_guessed: string
name: retrieve_data
arguments: label: D350
type_guessed: string
name: retrieve_data
arguments: label: D191
type_guessed: string
name: retrieve_data
arguments: label: D204
type_guessed: string
name: retrieve_data
arguments: label: D315
type_guessed: string
name: retrieve_data
arguments: label: D312
type_guessed: string
name: retrieve_data
arguments: label: D333
type_guessed: string
name: retrieve_data
arguments: label: D377
type_guessed: string
name: retrieve_data
arguments: label: D38
type_guessed: string
name: retrieve_data
arguments: label: D162
type_guessed: string
name: retrieve_data
arguments: label: D292
type_guessed: string
name: retrieve_data
arguments: label: D196
type_guessed: string
name: retrieve_data
arguments: label: D379
type_guessed: string
name: retrieve_data
arguments: label: D341
type_guessed: string
name: retrieve_data
arguments: label: D87
type_guessed: string
name: retrieve_data
arguments: label: D104
type_guessed: string
name: retrieve_data
arguments: label: D257
type_guessed: string
name: retrieve_data
arguments: label: D129
type_guessed: string
name: retrieve_data
arguments: label: D151
type_guessed: string
name: retrieve_data
arguments: label: D264
type_guessed: string
name: retrieve_data
arguments: label: D326
type_guessed: string
name: retrieve_data
arguments: label: D245
type_guessed: string
name: retrieve_data
arguments: label: D134
type_guessed: string
name: retrieve_data
arguments: label: D195
type_guessed: string
name: retrieve_data
arguments: label: D81
type_guessed: string
name: retrieve_data
arguments: label: D232
type_guessed: string
name: retrieve_data
arguments: label: D319
type_guessed: string

tool: D159: -----

tool: D375: .----

tool: D11: ..---

tool: D169: ...--

tool: D244: ....-

tool: D123: .....

tool: D290: -....

tool: D165: --...

tool: D356: ---..

tool: D363: ----.

tool: D317: .-

tool: D256: -...

tool: D350: -.-.

tool: D191: -..

tool: D204: .

tool: D315: ..-.

tool: D312: --.

tool: D333: ....

tool: D377: ..

tool: D38: .---

tool: D162: -.-

tool: D292: .-..

tool: D196: --

tool: D379: -.

tool: D341: ---

tool: D87: .--.

tool: D104: --.-

tool: D257: .-.

tool: D129: ...

tool: D151: -

tool: D264: ..-

tool: D326: ...-

tool: D245: .--

tool: D134: -..-

tool: D195: -.--

tool: D81: --..

tool: D232:  

tool: D319: %s


assistant: ```c
void encrypt(char *msg) {
  int i, size;
  char morse_code[1000] = "";
  char *num[] = {"-----", ".----", "..---", "...--", "....-", ".....", "-....", "--...", "---..", "----."};
  char *letters[] = {".-", "-...", "-.-.", "-..", ".", "..-.", "--.", "....", "..", ".---", "-.-", ".-..", "--", "-.", "---", ".--.", "--.-", ".-.", "...", "-", "..-", "...-", ".--", "-..-", "-.--", "--.."};
  size = strlen(msg);
  for (i = 0; i < size; i++)
    if (msg[i] != ' ')
      if (msg[i] >= '0' && msg[i] <= '9')
        strcat(morse_code, num[msg[i] - 48]);
      else
        strcat(morse_code, letters[msg[i] - 65]);
    else
      strcat(morse_code, " ");
  printf("%s\n", morse_code);
}
```