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

```asm
<_glp_mat_amd_order1>:
  endbr64
  push   %r15
  mov    %rsi,%r15
  push   %r14
  mov    %rcx,%r14
  push   %r13
  mov    %edi,%r13d
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rdx,%rbx
  sub    $0xf8,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0xe8(%rsp)
  xor    %eax,%eax
  lea    0x10(%rsp),%r8
  mov    %r8,%rdi
  mov    %r8,0x8(%rsp)
  call   <_glp_amd_defaults@plt>
  movslq %r13d,%rax
  mov    0x8(%rsp),%r8
  lea    0x4(,%rax,4),%r12
  mov    $0x1,%eax
  lea    (%r15,%r12,1),%rbp
  cmpl   $0x1,0x0(%rbp)
  jle    L59
  nopl   (%rax)
L32:
  subl   $0x1,(%rbx,%rax,4)
  add    $0x1,%rax
  cmp    %eax,0x0(%rbp)
  jg     L32
L59:
  lea    0x4(%r14),%rcx
  lea    0x4(%rbx),%rdx
  lea    0x4(%r15),%r10
  test   %r13d,%r13d
  js     L116
  lea    0x1(%r13),%edi
  cmp    $0x2,%r13d
  jbe    L254
  mov    %edi,%esi
  mov    %r10,%rax
  pcmpeqd %xmm1,%xmm1
  shr    $0x2,%esi
  sub    $0x1,%esi
  shl    $0x4,%rsi
  lea    0x14(%r15,%rsi,1),%rsi
L52:
  movdqu (%rax),%xmm0
  add    $0x10,%rax
  paddd  %xmm1,%xmm0
  movups %xmm0,-0x10(%rax)
  cmp    %rsi,%rax
  jne    L52
  mov    %edi,%eax
  and    $0xfffffffc,%eax
  lea    0x1(%rax),%esi
  cmp    %edi,%eax
  je     L11
L37:
  movslq %esi,%rax
  shl    $0x2,%rax
  subl   $0x1,(%r15,%rax,1)
  cmp    %r13d,%esi
  jg     L11
  subl   $0x1,0x4(%r15,%rax,1)
  cmp    %r13d,%esi
  jge    L11
  subl   $0x1,0x8(%r15,%rax,1)
L11:
  mov    %r10,%rsi
  lea    0x40(%rsp),%r9
  mov    %r13d,%edi
  mov    %r10,0x8(%rsp)
  call   <_glp_amd_order@plt>
  mov    0x8(%rsp),%r10
  cmp    $0x1,%eax
  jbe    L77
  mov    $0x200,%edx
  lea    D18(%rip),%rsi
  mov    %r10,0x8(%rsp)
  lea    D54(%rip),%rdi
  call   <_glp_lib_xassert@plt>
  mov    0x8(%rsp),%r10
L77:
  xor    %edx,%edx
  test   %r13d,%r13d
  cmovns %r13d,%edx
  add    $0x1,%edx
  cmp    $0x2,%r13d
  jle    L44
  mov    %edx,%ecx
  movdqa D33(%rip),%xmm1
  mov    %r10,%rax
  shr    $0x2,%ecx
  sub    $0x1,%ecx
  shl    $0x4,%rcx
  lea    0x14(%r15,%rcx,1),%rcx
  cs nopw 0x0(%rax,%rax,1)
L40:
  movdqu (%rax),%xmm0
  add    $0x10,%rax
  paddd  %xmm1,%xmm0
  movups %xmm0,-0x10(%rax)
  cmp    %rax,%rcx
  jne    L40
  mov    %edx,%eax
  and    $0xfffffffc,%eax
  lea    0x1(%rax),%ecx
  cmp    %eax,%edx
  je     L145
L250:
  movslq %ecx,%rax
  shl    $0x2,%rax
  addl   $0x1,(%r15,%rax,1)
  cmp    %ecx,%r13d
  jl     L145
  addl   $0x1,0x4(%r15,%rax,1)
  cmp    %ecx,%r13d
  jle    L145
  addl   $0x1,0x8(%r15,%rax,1)
L145:
  cmpl   $0x1,0x0(%rbp)
  mov    $0x1,%eax
  jle    L70
  xchg   %ax,%ax
L121:
  addl   $0x1,(%rbx,%rax,4)
  add    $0x1,%rax
  cmp    %eax,0x0(%rbp)
  jg     L121
L70:
  lea    0x0(,%r13,4),%edx
  lea    (%r14,%r12,1),%rdi
  xor    %esi,%esi
  mov    $0x1,%r15d
  call   <memset@plt>
  lea    D18(%rip),%rbx
  lea    D71(%rip),%rbp
  test   %r13d,%r13d
  jle    L271
  nopl   0x0(%rax)
L243:
  mov    (%r14,%r15,4),%eax
  mov    %r15d,%r12d
  add    $0x1,%eax
  mov    %eax,(%r14,%r15,4)
  cmp    %r13d,%eax
  jg     L39
  test   %eax,%eax
  jle    L39
  add    %r13d,%eax
  cltq
  lea    (%r14,%rax,4),%rax
  mov    (%rax),%edx
  test   %edx,%edx
  jne    L117
L102:
  add    $0x1,%r15
  mov    %r12d,(%rax)
  cmp    %r15d,%r13d
  jge    L243
L271:
  mov    0xe8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L128
  add    $0xf8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L39:
  mov    $0x208,%edx
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  call   <_glp_lib_xassert@plt>
  mov    (%r14,%r15,4),%eax
  add    %r13d,%eax
  cltq
  lea    (%r14,%rax,4),%rax
  mov    (%rax),%edx
  test   %edx,%edx
  je     L102
L117:
  mov    $0x209,%edx
  mov    %rbx,%rsi
  lea    D62(%rip),%rdi
  call   <_glp_lib_xassert@plt>
  mov    (%r14,%r15,4),%eax
  add    $0x1,%r15
  add    %r13d,%eax
  cltq
  mov    %r12d,(%r14,%rax,4)
  cmp    %r15d,%r13d
  jge    L243
  jmp    L271
  cs nopw 0x0(%rax,%rax,1)
L116:
  lea    0x40(%rsp),%r9
  mov    %r10,%rsi
  mov    %r13d,%edi
  call   <_glp_amd_order@plt>
  cmp    $0x1,%eax
  jbe    L145
  mov    $0x200,%edx
  lea    D18(%rip),%rsi
  lea    D54(%rip),%rdi
  call   <_glp_lib_xassert@plt>
  jmp    L145
L44:
  mov    $0x1,%ecx
  jmp    L250
L254:
  mov    $0x1,%esi
  jmp    L37
L128:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D18
type_infered: string
name: extract_symbolic_data
arguments: data_label: D54
type_infered: string
name: extract_symbolic_data
arguments: data_label: D33
type_infered: byte[16]
name: extract_symbolic_data
arguments: data_label: D71
type_infered: string
name: extract_symbolic_data
arguments: data_label: D62
type_infered: string

tool: D18: /scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/macmanes-lab/BinPacker/refs/heads/master/glpk-4.40/src/glpmat.c

tool: D54: ret == AMD_OK || ret == AMD_OK_BUT_JUMBLED

tool: {"D33": [0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00]}

tool: D71: 1 <= P_per[k] && P_per[k] <= n

tool: D62: P_per[n+P_per[k]] == 0

assistant: ```c
void _glp_mat_amd_order1(int n, int A_ptr[], int A_ind[], int P_per[]) {
  int k, ret;
  double Control[5], Info[20];
  _glp_amd_defaults(Control);
  for (k = 1; k < A_ptr[n + 1]; k++)
    A_ind[k]--;
  for (k = 1; k <= n + 1; k++)
    A_ptr[k]--;
  ret = _glp_amd_order(n, &A_ptr[1], &A_ind[1], &P_per[1], Control, Info);
  ((void)((ret == 0 || ret == 1) || (_glp_lib_xassert("ret == AMD_OK || ret == AMD_OK_BUT_JUMBLED", "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/macmanes-lab/BinPacker/refs/heads/master/glpk-4.40/src/glpmat.c", 512), 1)));
  for (k = 1; k <= n + 1; k++)
    A_ptr[k]++;
  for (k = 1; k < A_ptr[n + 1]; k++)
    A_ind[k]++;
  memset(&P_per[n + 1], 0, n * sizeof(int));
  for (k = 1; k <= n; k++) {
    P_per[k]++;
    ((void)((1 <= P_per[k] && P_per[k] <= n) || (_glp_lib_xassert("1 <= P_per[k] && P_per[k] <= n", "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/macmanes-lab/BinPacker/refs/heads/master/glpk-4.40/src/glpmat.c", 520), 1)));
    ((void)((P_per[n + P_per[k]] == 0) || (_glp_lib_xassert("P_per[n+P_per[k]] == 0", "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/macmanes-lab/BinPacker/refs/heads/master/glpk-4.40/src/glpmat.c", 521), 1)));
    P_per[n + P_per[k]] = k;
  }
  return;
}
```