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

```asm
<S_check_flags>:
  endbr64
  push   %r12
  not    %esi
  push   %rbp
  sub    $0x28,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  and    %edi,%esi
  je     L239
  mov    %rdx,%rbp
  test   $0x1,%sil
  jne    L137
  test   $0x2,%sil
  jne    L147
  test   $0x8,%sil
  jne    L75
  test   $0x10,%sil
  jne    L34
  test   $0x20,%sil
  jne    L156
  test   $0x40,%sil
  jne    L72
  test   $0x80,%sil
  jne    L241
  test   $0x100,%esi
  jne    L97
  test   $0x200,%esi
  jne    L157
  test   $0x400,%esi
  jne    L63
  test   $0x800,%esi
  jne    L236
  test   $0x1000,%esi
  je     L120
  mov    %rsp,%r12
  lea    D2(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  xchg   %ax,%ax
L137:
  mov    %rsp,%r12
  lea    D17(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
L131:
  mov    %r12,%rdx
  mov    %rbp,%rsi
  lea    D53(%rip),%rdi
  xor    %eax,%eax
  call   <CFCUtil_die@plt>
L239:
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L127
  add    $0x28,%rsp
  pop    %rbp
  pop    %r12
  ret
  nopw   0x0(%rax,%rax,1)
L75:
  mov    %rsp,%r12
  lea    D39(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopl   0x0(%rax)
L147:
  mov    %rsp,%r12
  lea    D125(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopl   0x0(%rax)
L72:
  mov    %rsp,%r12
  lea    D120(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopl   0x0(%rax)
L34:
  mov    %rsp,%r12
  lea    D37(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopw   0x0(%rax,%rax,1)
L156:
  mov    %rsp,%r12
  lea    D124(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopw   0x0(%rax,%rax,1)
L241:
  mov    %rsp,%r12
  lea    D9(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
  nopw   0x0(%rax,%rax,1)
L97:
  mov    %rsp,%r12
  lea    D15(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
L157:
  mov    %rsp,%r12
  lea    D80(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
L63:
  mov    %rsp,%r12
  lea    D61(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
L120:
  lea    D19(%rip),%rdi
  xor    %eax,%eax
  mov    %rsp,%r12
  call   <CFCUtil_die@plt>
  jmp    L131
L236:
  mov    %rsp,%r12
  lea    D100(%rip),%rsi
  mov    %r12,%rdi
  call   <strcpy@plt>
  jmp    L131
L127:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D2
type: string
name: extract_symbolic_data
arguments: data_label: D17
type: string
name: extract_symbolic_data
arguments: data_label: D53
type: string
name: extract_symbolic_data
arguments: data_label: D39
type: string
name: extract_symbolic_data
arguments: data_label: D125
type: string
name: extract_symbolic_data
arguments: data_label: D120
type: string
name: extract_symbolic_data
arguments: data_label: D37
type: string
name: extract_symbolic_data
arguments: data_label: D124
type: string
name: extract_symbolic_data
arguments: data_label: D9
type: string
name: extract_symbolic_data
arguments: data_label: D15
type: string
name: extract_symbolic_data
arguments: data_label: D80
type: string
name: extract_symbolic_data
arguments: data_label: D61
type: string
name: extract_symbolic_data
arguments: data_label: D19
type: string
name: extract_symbolic_data
arguments: data_label: D100
type: string

tool: D2: COMPOSITE

tool: D17: CONST

tool: D53: Bad flag for type %s: %s

tool: D39: INCREMENTED

tool: D125: NULLABLE

tool: D120: PRIMITIVE

tool: D37: DECREMENTED

tool: D124: OBJECT

tool: D9: INTEGER

tool: D15: FLOATING

tool: D80: STRING_TYPE

tool: D61: VA_LIST

tool: D19: Unknown flags: %d

tool: D100: ARBITRARY

assistant: ```c
void S_check_flags(int supplied, int acceptable, const char *type_name) {
  int bad = (supplied & ~acceptable);
  if (bad) {
    char bad_flag[20];
    if ((bad & 0x00000001)) {
      strcpy(bad_flag, "CONST");
    } else if ((bad & 0x00000002)) {
      strcpy(bad_flag, "NULLABLE");
    } else if ((bad & 0x00000008)) {
      strcpy(bad_flag, "INCREMENTED");
    } else if ((bad & 0x00000010)) {
      strcpy(bad_flag, "DECREMENTED");
    } else if ((bad & 0x00000020)) {
      strcpy(bad_flag, "OBJECT");
    } else if ((bad & 0x00000040)) {
      strcpy(bad_flag, "PRIMITIVE");
    } else if ((bad & 0x00000080)) {
      strcpy(bad_flag, "INTEGER");
    } else if ((bad & 0x00000100)) {
      strcpy(bad_flag, "FLOATING");
    } else if ((bad & 0x00000200)) {
      strcpy(bad_flag, "STRING_TYPE");
    } else if ((bad & 0x00000400)) {
      strcpy(bad_flag, "VA_LIST");
    } else if ((bad & 0x00000800)) {
      strcpy(bad_flag, "ARBITRARY");
    } else if ((bad & 0x00001000)) {
      strcpy(bad_flag, "COMPOSITE");
    } else {
      CFCUtil_die("Unknown flags: %d", bad);
    }
    CFCUtil_die("Bad flag for type %s: %s", type_name, bad_flag);
  }
}
```