user: Translate the below assembly code into C programming language:

```asm
<panel_utils_note_to_name>:
  endbr64
  push   %rbp
  push   %rbx
  sub    $0x8,%rsp
  mov    %rdi,%rbx
  mov    %ecx,%ebp
  cmp    $0x7f,%esi
  ja     L174
L94:
  movslq %esi,%rax
  imul   $0x2aaaaaab,%rax,%rax
  sar    $0x21,%rax
  mov    %esi,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%eax
  lea    (%rax,%rax,2),%ecx
  shl    $0x2,%ecx
  mov    %esi,%eax
  sub    %ecx,%eax
  test   %edx,%edx
  je     L44
  movslq %esi,%rdx
  imul   $0x2aaaaaab,%rdx,%rdx
  sar    $0x21,%rdx
  sar    $0x1f,%esi
  sub    %esi,%edx
  sub    $0x1,%edx
  cmp    $0xb,%eax
  ja     L131
  mov    %eax,%eax
  lea    D124(%rip),%rcx
  movslq (%rcx,%rax,4),%rax
  add    %rcx,%rax
  notrack jmp *%rax
L174:
  movw   $0x2d2d,(%rdi)
  movb   $0x0,0x2(%rdi)
  jmp    L94
  lea    D258(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D39(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
L131:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  ret
  lea    D17(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D80(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  jmp    L131
  lea    D143(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D206(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D33(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  jmp    L131
  lea    D131(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D42(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  jmp    L131
  lea    D261(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  lea    D16(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  jmp    L131
  lea    D186(%rip),%rsi
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
L44:
  cmp    $0xb,%eax
  ja     L131
  mov    %eax,%eax
  lea    D231(%rip),%rdx
  movslq (%rdx,%rax,4),%rax
  add    %rdx,%rax
  notrack jmp *%rax
  movw   $0x43,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x2343,(%rbx)
  movb   $0x0,0x2(%rbx)
  jmp    L131
  movw   $0x44,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x2344,(%rbx)
  movb   $0x0,0x2(%rbx)
  jmp    L131
  movw   $0x45,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x46,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x2346,(%rbx)
  movb   $0x0,0x2(%rbx)
  jmp    L131
  movw   $0x47,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x2347,(%rbx)
  movb   $0x0,0x2(%rbx)
  jmp    L131
  movw   $0x41,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
  movw   $0x2341,(%rbx)
  movb   $0x0,0x2(%rbx)
  jmp    L131
  movw   $0x42,(%rbx)
  test   %ebp,%ebp
  je     L131
  lea    D12(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcat@plt>
  jmp    L131
```

tool_calls: name: unpack_data
arguments: data_tag: D258
datatype: string
name: unpack_data
arguments: data_tag: D12
datatype: string
name: unpack_data
arguments: data_tag: D39
datatype: string
name: unpack_data
arguments: data_tag: D17
datatype: string
name: unpack_data
arguments: data_tag: D80
datatype: string
name: unpack_data
arguments: data_tag: D143
datatype: string
name: unpack_data
arguments: data_tag: D206
datatype: string
name: unpack_data
arguments: data_tag: D33
datatype: string
name: unpack_data
arguments: data_tag: D131
datatype: string
name: unpack_data
arguments: data_tag: D42
datatype: string
name: unpack_data
arguments: data_tag: D261
datatype: string
name: unpack_data
arguments: data_tag: D16
datatype: string
name: unpack_data
arguments: data_tag: D186
datatype: string

tool: D258: C%d

tool: D12:  

tool: D39: C#%d

tool: D17: D%d

tool: D80: D#%d

tool: D143: E%d

tool: D206: F%d

tool: D33: F#%d

tool: D131: G%d

tool: D42: G#%d

tool: D261: A%d

tool: D16: A#%d

tool: D186: B%d

assistant: ```c
void panel_utils_note_to_name(char *tempstr, int note, int octdisp, int padding) {
  int oct, degree;
  if (note < 0 || note > 0x7f) {
    sprintf(tempstr, "--");
  }
  oct = (note / 12) - 1;
  degree = note % 12;
  if (octdisp) {
    switch (degree) {
    case 0:
      sprintf(tempstr, "C%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 1:
      sprintf(tempstr, "C#%d", oct);
      break;
    case 2:
      sprintf(tempstr, "D%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 3:
      sprintf(tempstr, "D#%d", oct);
      break;
    case 4:
      sprintf(tempstr, "E%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 5:
      sprintf(tempstr, "F%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 6:
      sprintf(tempstr, "F#%d", oct);
      break;
    case 7:
      sprintf(tempstr, "G%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 8:
      sprintf(tempstr, "G#%d", oct);
      break;
    case 9:
      sprintf(tempstr, "A%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 10:
      sprintf(tempstr, "A#%d", oct);
      break;
    case 11:
      sprintf(tempstr, "B%d", oct);
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    }
  } else {
    switch (degree) {
    case 0:
      sprintf(tempstr, "C");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 1:
      sprintf(tempstr, "C#");
      break;
    case 2:
      sprintf(tempstr, "D");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 3:
      sprintf(tempstr, "D#");
      break;
    case 4:
      sprintf(tempstr, "E");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 5:
      sprintf(tempstr, "F");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 6:
      sprintf(tempstr, "F#");
      break;
    case 7:
      sprintf(tempstr, "G");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 8:
      sprintf(tempstr, "G#");
      break;
    case 9:
      sprintf(tempstr, "A");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    case 10:
      sprintf(tempstr, "A#");
      break;
    case 11:
      sprintf(tempstr, "B");
      if (padding) {
        strcat(tempstr, " ");
      }
      break;
    }
  }
}
```