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

```asm
<gen_parser>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %rdi,-0x8(%rbp)
  mov    %rsi,-0x10(%rbp)
  mov    %rdx,-0x18(%rbp)
  mov    %rcx,-0x20(%rbp)
  mov    %r8,-0x28(%rbp)
  mov    -0x10(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <gen_known@plt>
  mov    -0x10(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <gen_non_term@plt>
  mov    -0x10(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <gen_goto@plt>
  mov    -0x10(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <gen_states@plt>
  mov    -0x28(%rbp),%rcx
  mov    -0x18(%rbp),%rdx
  mov    -0x10(%rbp),%rsi
  mov    -0x8(%rbp),%rax
  mov    %rax,%rdi
  call   <gen_reduce@plt>
  mov    -0x10(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <gen_free@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x15,%edx
  mov    $0x1,%esi
  lea    D40(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x20(%rbp),%rdx
  mov    -0x8(%rbp),%rax
  lea    D8(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <fprintf@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x2,%edx
  mov    $0x1,%esi
  lea    D71(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x1d,%edx
  mov    $0x1,%esi
  lea    D32(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x1e,%edx
  mov    $0x1,%esi
  lea    D23(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x37,%edx
  mov    $0x1,%esi
  lea    D89(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x46,%edx
  mov    $0x1,%esi
  lea    D69(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x24,%edx
  mov    $0x1,%esi
  lea    D91(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x55,%edx
  mov    $0x1,%esi
  lea    D112(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x16,%edx
  mov    $0x1,%esi
  lea    D34(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0xc,%edx
  mov    $0x1,%esi
  lea    D113(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  mov    -0x8(%rbp),%rax
  mov    %rax,%rcx
  mov    $0x3,%edx
  mov    $0x1,%esi
  lea    D55(%rip),%rax
  mov    %rax,%rdi
  call   <fwrite@plt>
  nop
  leave
  ret
```

tool_calls: name: retrieve_data
arguments: label: D40
type: string
name: retrieve_data
arguments: label: D8
type: string
name: retrieve_data
arguments: label: D71
type: string
name: retrieve_data
arguments: label: D32
type: string
name: retrieve_data
arguments: label: D23
type: string
name: retrieve_data
arguments: label: D89
type: string
name: retrieve_data
arguments: label: D69
type: string
name: retrieve_data
arguments: label: D91
type: string
name: retrieve_data
arguments: label: D112
type: string
name: retrieve_data
arguments: label: D34
type: string
name: retrieve_data
arguments: label: D113
type: string
name: retrieve_data
arguments: label: D55
type: string

tool: D40: #line 0 "gen_parser"


tool: D8: void *parse_%s(struct code_node *code, struct token_config *config, FILE *trace)


tool: D71: {


tool: D32: 	struct token_state *tokens;


tool: D23: 	config->words_marks = known;


tool: D89: 	config->known_count = sizeof(known)/sizeof(known[0]);


tool: D69: 	config->ignored |= (1 << TK_line_comment) | (1 << TK_block_comment);


tool: D91: 	tokens = token_open(code, config);


tool: D112: 	void *rv = parser_run(tokens, states, do_reduce, do_free, trace, non_term, config);


tool: D34: 	token_close(tokens);


tool: D113: 	return rv;


tool: D55: }



assistant: ```c
void gen_parser(FILE *f, struct grammar *g, char *file, char *name, struct code_node *pre_reduce) {
  gen_known(f, g);
  gen_non_term(f, g);
  gen_goto(f, g);
  gen_states(f, g);
  gen_reduce(f, g, file, pre_reduce);
  gen_free(f, g);
  fprintf(f, "#line 0 \"gen_parser\"\n");
  fprintf(f, "void *parse_%s(struct code_node *code, struct token_config *config, FILE *trace)\n", name);
  fprintf(f, "{\n");
  fprintf(f, "\tstruct token_state *tokens;\n");
  fprintf(f, "\tconfig->words_marks = known;\n");
  fprintf(f, "\tconfig->known_count = sizeof(known)/sizeof(known[0]);\n");
  fprintf(f, "\tconfig->ignored |= (1 << TK_line_comment) | (1 << TK_block_comment);\n");
  fprintf(f, "\ttokens = token_open(code, config);\n");
  fprintf(f, "\tvoid *rv = parser_run(tokens, states, do_reduce, do_free, trace, non_term, config);\n");
  fprintf(f, "\ttoken_close(tokens);\n");
  fprintf(f, "\treturn rv;\n");
  fprintf(f, "}\n\n");
}
```