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

```asm
<rndgamma>:
  endbr64
  push   %rbx
  sub    $0x30,%rsp
  movsd  D7(%rip),%xmm5
  movsd  %xmm0,0x28(%rsp)
  comisd %xmm0,%xmm5
  ja     L79
  movsd  0x28(%rsp),%xmm0
L61:
  movsd  D6(%rip),%xmm1
  pxor   %xmm5,%xmm5
  subsd  %xmm1,%xmm0
  ucomisd %xmm0,%xmm5
  movapd %xmm0,%xmm7
  movsd  %xmm0,0x20(%rsp)
  ja     L13
  sqrtsd %xmm7,%xmm7
  movapd %xmm7,%xmm0
L83:
  divsd  %xmm0,%xmm1
  movsd  %xmm1,0x8(%rsp)
  nopl   (%rax)
L67:
  xor    %eax,%eax
  call   <rndNormal@plt>
  pxor   %xmm4,%xmm4
  movapd %xmm0,%xmm1
  movsd  0x8(%rsp),%xmm0
  mulsd  %xmm1,%xmm0
  addsd  D7(%rip),%xmm0
  comisd %xmm0,%xmm4
  jae    L67
  movapd %xmm0,%xmm2
  xor    %eax,%eax
  movsd  %xmm1,0x18(%rsp)
  mulsd  %xmm0,%xmm2
  mulsd  %xmm0,%xmm2
  movsd  %xmm2,0x10(%rsp)
  call   <rndu@plt>
  movsd  0x18(%rsp),%xmm1
  movsd  D10(%rip),%xmm6
  movsd  D7(%rip),%xmm3
  mulsd  %xmm1,%xmm6
  movapd %xmm6,%xmm2
  mulsd  %xmm1,%xmm2
  mulsd  %xmm1,%xmm2
  mulsd  %xmm1,%xmm2
  subsd  %xmm2,%xmm3
  comisd %xmm0,%xmm3
  ja     L46
  call   <log@plt>
  movsd  0x18(%rsp),%xmm1
  movsd  D75(%rip),%xmm0
  mov    %eax,%ebx
  mulsd  %xmm1,%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,0x18(%rsp)
  movsd  0x10(%rsp),%xmm0
  call   <log@plt>
  pxor   %xmm2,%xmm2
  pxor   %xmm1,%xmm1
  movsd  D7(%rip),%xmm6
  cvtsi2sd %eax,%xmm2
  subsd  0x10(%rsp),%xmm6
  cvtsi2sd %ebx,%xmm1
  movapd %xmm6,%xmm0
  addsd  %xmm2,%xmm0
  mulsd  0x20(%rsp),%xmm0
  addsd  0x18(%rsp),%xmm0
  comisd %xmm1,%xmm0
  jbe    L67
L46:
  movsd  D7(%rip),%xmm7
  comisd 0x28(%rsp),%xmm7
  movsd  0x20(%rsp),%xmm2
  mulsd  0x10(%rsp),%xmm2
  ja     L105
L51:
  pxor   %xmm7,%xmm7
  ucomisd %xmm7,%xmm2
  jp     L39
  je     L33
L39:
  add    $0x30,%rsp
  movapd %xmm2,%xmm0
  pop    %rbx
  ret
L79:
  movapd %xmm0,%xmm7
  movapd %xmm5,%xmm0
  addsd  %xmm7,%xmm0
  jmp    L61
L33:
  lea    D53(%rip),%rdi
  movsd  %xmm2,0x8(%rsp)
  call   <printf@plt>
  movsd  0x8(%rsp),%xmm2
  add    $0x30,%rsp
  pop    %rbx
  movapd %xmm2,%xmm0
  ret
L105:
  xor    %eax,%eax
  movsd  %xmm2,0x8(%rsp)
  call   <rndu@plt>
  movsd  D7(%rip),%xmm1
  divsd  0x28(%rsp),%xmm1
  cvttsd2si %xmm1,%edi
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm2
  mulsd  %xmm0,%xmm2
  jmp    L51
L13:
  movsd  0x20(%rsp),%xmm0
  call   <sqrt@plt>
  mov    D6(%rip),%rax
  movq   %rax,%xmm1
  jmp    L83
```

tool_calls: name: read_data
arguments: tag: D7
type: f64
name: read_data
arguments: tag: D6
type: byte[8]
name: read_data
arguments: tag: D10
type: f64
name: read_data
arguments: tag: D75
type: f64
name: read_data
arguments: tag: D53
type: string

tool: D7: 1

tool: {"D6": [0x55,0x55,0x55,0x55,0x55,0x55,0xd5,0x3f]}

tool: D10: 0.0331

tool: D75: 0.5

tool: D53: 
rndgamma returning 0.


assistant: ```c
double rndgamma(double a) {
  double a0 = a, c, d, u, v, x;
  if (a < 1)
    a++;
  d = a - 1.0 / 3.0;
  c = (1.0 / 3.0) / sqrt(d);
  for (;;) {
    do {
      x = rndNormal();
      v = 1.0 + c * x;
    } while (v <= 0);
    v *= v * v;
    u = rndu();
    if (u < 1 - 0.0331 * x * x * x * x)
      break;
    if (log(u) < 0.5 * x * x + d * (1 - v + log(v)))
      break;
  }
  v *= d;
  if (a0 < 1)
    v *= pow(rndu(), 1 / a0);
  if (v == 0)
    printf("\nrndgamma returning 0.\n");
  return v;
}
```