user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<test_note_to_int>:
  endbr64
  sub    $0x8,%rsp
  lea    D95(%rip),%rdi
  call   <start_test@plt>
  lea    D61(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  test   %eax,%eax
  sete   %dil
  call   <assert@plt>
  lea    D2(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x2,%eax
  sete   %dil
  call   <assert@plt>
  lea    D135(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x2,%eax
  sete   %dil
  call   <assert@plt>
  lea    D98(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x4,%eax
  sete   %dil
  call   <assert@plt>
  lea    D12(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x5,%eax
  sete   %dil
  call   <assert@plt>
  lea    D13(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x7,%eax
  sete   %dil
  call   <assert@plt>
  lea    D40(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x9,%eax
  sete   %dil
  call   <assert@plt>
  lea    D151(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0xa,%eax
  sete   %dil
  call   <assert@plt>
  lea    D168(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0xa,%eax
  sete   %dil
  call   <assert@plt>
  lea    D19(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0xb,%eax
  sete   %dil
  call   <assert@plt>
  lea    D139(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0xb,%eax
  sete   %dil
  call   <assert@plt>
  lea    D51(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x8,%eax
  sete   %dil
  call   <assert@plt>
  lea    D136(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x4,%eax
  sete   %dil
  call   <assert@plt>
  lea    D35(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x1,%eax
  sete   %dil
  call   <assert@plt>
  lea    D22(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  test   %eax,%eax
  sete   %dil
  call   <assert@plt>
  lea    D90(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x8,%eax
  sete   %dil
  call   <assert@plt>
  lea    D58(%rip),%rdi
  call   <str_to_note@plt>
  mov    %eax,%edi
  call   <note_to_int@plt>
  xor    %edi,%edi
  cmp    $0x3,%eax
  sete   %dil
  call   <assert@plt>
  xor    %eax,%eax
  add    $0x8,%rsp
  jmp    10d0 <end_test@plt>
```

tool_calls: name: disassemble_data
arguments: label: D95
data_type: string
name: disassemble_data
arguments: label: D61
data_type: string
name: disassemble_data
arguments: label: D2
data_type: string
name: disassemble_data
arguments: label: D135
data_type: string
name: disassemble_data
arguments: label: D98
data_type: string
name: disassemble_data
arguments: label: D12
data_type: string
name: disassemble_data
arguments: label: D13
data_type: string
name: disassemble_data
arguments: label: D40
data_type: string
name: disassemble_data
arguments: label: D151
data_type: string
name: disassemble_data
arguments: label: D168
data_type: string
name: disassemble_data
arguments: label: D19
data_type: string
name: disassemble_data
arguments: label: D139
data_type: string
name: disassemble_data
arguments: label: D51
data_type: string
name: disassemble_data
arguments: label: D136
data_type: string
name: disassemble_data
arguments: label: D35
data_type: string
name: disassemble_data
arguments: label: D22
data_type: string
name: disassemble_data
arguments: label: D90
data_type: string
name: disassemble_data
arguments: label: D58
data_type: string

tool: D95: note_to_int

tool: D61: C

tool: D2: C##

tool: D135: D

tool: D98: E

tool: D12: F

tool: D13: G

tool: D40: A

tool: D151: A#

tool: D168: Bb

tool: D19: B

tool: D139: Cb

tool: D51: Cbbbb

tool: D136: Cbbbbbbbb

tool: D35: Cbbbbbbbbbbb

tool: D22: Cbbbbbbbbbbbb

tool: D90: Cbbbbbbbbbbbbbbbb

tool: D58: Bbbbbbbbb

assistant: ```c
void test_note_to_int() {
  start_test("note_to_int");
  assert(note_to_int(str_to_note("C")) == 0);
  assert(note_to_int(str_to_note("C##")) == 2);
  assert(note_to_int(str_to_note("D")) == 2);
  assert(note_to_int(str_to_note("E")) == 4);
  assert(note_to_int(str_to_note("F")) == 5);
  assert(note_to_int(str_to_note("G")) == 7);
  assert(note_to_int(str_to_note("A")) == 9);
  assert(note_to_int(str_to_note("A#")) == 10);
  assert(note_to_int(str_to_note("Bb")) == 10);
  assert(note_to_int(str_to_note("B")) == 11);
  assert(note_to_int(str_to_note("Cb")) == 11);
  assert(note_to_int(str_to_note("Cbbbb")) == 8);
  assert(note_to_int(str_to_note("Cbbbbbbbb")) == 4);
  assert(note_to_int(str_to_note("Cbbbbbbbbbbb")) == 1);
  assert(note_to_int(str_to_note("Cbbbbbbbbbbbb")) == 0);
  assert(note_to_int(str_to_note("Cbbbbbbbbbbbbbbbb")) == 8);
  assert(note_to_int(str_to_note("Bbbbbbbbb")) == 3);
  end_test();
}
```