user: 请从给定的汇编指令推导出C源代码:

```asm
<main>:
  endbr64
  push   %rbp
  lea    D28(%rip),%rdi
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  lea    D53(%rip),%r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x28,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  call   <printf@plt>
  lea    -0x40(%rbp),%rsi
  mov    %r14,%rdi
  call   <scanf@plt>
  movslq -0x40(%rbp),%rax
  mov    %rsp,%rcx
  lea    0xf(,%rax,4),%rax
  mov    %rax,%rsi
  mov    %rax,%rdx
  and    $0xfffffffffffff000,%rsi
  and    $0xfffffffffffffff0,%rdx
  sub    %rsi,%rcx
  cmp    %rcx,%rsp
  je     L190
L152:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L152
L190:
  and    $0xfff,%edx
  sub    %rdx,%rsp
  test   %rdx,%rdx
  jne    L222
L33:
  mov    %rax,%rdx
  mov    %rsp,%rcx
  and    $0xfffffffffffff000,%rax
  mov    %rsp,%r12
  and    $0xfffffffffffffff0,%rdx
  sub    %rax,%rcx
L148:
  cmp    %rcx,%rsp
  je     L100
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L148
L222:
  orq    $0x0,-0x8(%rsp,%rdx,1)
  jmp    L33
L100:
  and    $0xfff,%edx
  sub    %rdx,%rsp
  test   %rdx,%rdx
  jne    L227
L93:
  lea    D66(%rip),%rdi
  xor    %eax,%eax
  mov    %rsp,%rbx
  call   <printf@plt>
  lea    -0x3c(%rbp),%rsi
  mov    %r14,%rdi
  call   <scanf@plt>
  xor    %eax,%eax
  lea    D19(%rip),%rdi
  call   <printf@plt>
  cmpl   $0x0,-0x3c(%rbp)
  jle    L158
  mov    %r12,%r15
  xor    %r13d,%r13d
L71:
  mov    %r15,%rsi
  mov    %r14,%rdi
  add    $0x1,%r13d
  add    $0x4,%r15
  call   <scanf@plt>
  mov    -0x3c(%rbp),%edi
  cmp    %r13d,%edi
  jg     L71
  test   %edi,%edi
  jle    L158
  lea    -0x2(%rdi),%eax
  xor    %r9d,%r9d
  mov    %rax,%r8
  lea    0x4(%r12,%rax,4),%rsi
  nopl   0x0(%rax)
L59:
  mov    %r12,%rax
  cmp    $0x1,%edi
  je     L70
L119:
  mov    (%rax),%edx
  mov    0x4(%rax),%ecx
  cmp    %ecx,%edx
  jle    L236
  mov    %ecx,(%rax)
  mov    %edx,0x4(%rax)
L236:
  add    $0x4,%rax
  cmp    %rsi,%rax
  jne    L119
L70:
  add    $0x1,%r9d
  cmp    %r9d,%edi
  jne    L59
  lea    -0x1(%rdi),%r9d
  xor    %edx,%edx
  lea    0x4(%r12),%r10
  mov    %r12,%rdi
  movl   $0x0,(%rbx,%rdx,4)
  cmp    %rdx,%r9
  je     L158
  nopw   0x0(%rax,%rax,1)
L167:
  mov    %r8d,%eax
  mov    (%rdi),%esi
  sub    %edx,%eax
  add    %rdx,%rax
  lea    (%r10,%rax,4),%rcx
  mov    %rdi,%rax
  nopl   0x0(%rax)
L74:
  cmp    0x4(%rax),%esi
  jne    L216
  addl   $0x1,(%rbx,%rdx,4)
L216:
  add    $0x4,%rax
  cmp    %rax,%rcx
  jne    L74
  add    $0x1,%rdx
  add    $0x4,%rdi
  movl   $0x0,(%rbx,%rdx,4)
  cmp    %rdx,%r9
  jne    L167
L158:
  lea    D67(%rip),%rdi
  xor    %r14d,%r14d
  call   <puts@plt>
  mov    -0x40(%rbp),%eax
  movl   $0x0,-0x44(%rbp)
  test   %eax,%eax
  jns    L267
  jmp    L259
  nopl   (%rax)
L198:
  lea    D17(%rip),%rdi
  xor    %eax,%eax
  add    $0x1,%r14d
  call   <printf@plt>
  cmp    %r14d,-0x40(%rbp)
  jl     L259
L267:
  movslq -0x44(%rbp),%r13
  mov    %r14d,%esi
  cmp    %r14d,(%r12,%r13,4)
  jne    L198
  lea    D63(%rip),%rdi
  xor    %eax,%eax
  xor    %r15d,%r15d
  call   <printf@plt>
  mov    (%rbx,%r13,4),%r13d
  test   %r13d,%r13d
  js     L73
  nop
L26:
  mov    $0x2a,%edi
  add    $0x1,%r15d
  call   <putchar@plt>
  cmp    %r13d,%r15d
  jle    L26
L73:
  mov    -0x44(%rbp),%eax
  mov    $0xa,%edi
  add    $0x1,%r14d
  lea    0x1(%rax,%r13,1),%eax
  mov    %eax,-0x44(%rbp)
  call   <putchar@plt>
  cmp    %r14d,-0x40(%rbp)
  jge    L267
  nopw   0x0(%rax,%rax,1)
L259:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L123
  lea    -0x28(%rbp),%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
L227:
  orq    $0x0,-0x8(%rsp,%rdx,1)
  jmp    L93
L123:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: data_label: D28
datatype: string
name: disassemble_data
arguments: data_label: D53
datatype: string
name: disassemble_data
arguments: data_label: D66
datatype: string
name: disassemble_data
arguments: data_label: D19
datatype: string
name: disassemble_data
arguments: data_label: D67
datatype: string
name: disassemble_data
arguments: data_label: D17
datatype: string
name: disassemble_data
arguments: data_label: D63
datatype: string

tool: D28: Enter range: 

tool: D53: %d

tool: D66: Enter length: 

tool: D19: Enter array: 

tool: D67: Histogram:

tool: D17: %d: 


tool: D63: %d: 

assistant: ```c
int main() {
  int range, length, br, c, j;
  printf("Enter range: ");
  scanf("%d", &range);
  int array[range], HowMuch[range];
  printf("Enter length: ");
  scanf("%d", &length);
  printf("Enter array: ");
  for (br = 0; br < length; br++) {
    scanf("%d", &array[br]);
  }
  for (br = 0; br < length; br++) {
    for (j = 0; j < length - 1; j++) {
      if (array[j] > array[j + 1]) {
        c = array[j];
        array[j] = array[j + 1];
        array[j + 1] = c;
      }
    }
  }
  for (br = 0; br < length; br++) {
    HowMuch[br] = 0;
    for (j = br + 1; j < length; j++) {
      if (array[br] == array[j]) {
        HowMuch[br] = HowMuch[br] + 1;
      }
    }
  }
  j = 0;
  printf("Histogram:\n");
  for (br = 0; br <= range; br++)
    if (br == array[j]) {
      printf("%d: ", br);
      for (c = 0; c <= HowMuch[j]; c++) {
        printf("*");
      }
      j = j + 1 + HowMuch[j];
      printf("\n");
    } else {
      printf("%d: \n", br);
    }
  return 0;
}
```