user: 请将以下的汇编代码转换成C语言代码:

```asm
<sinus>:
  endbr64
  push   %rbx
  movapd %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  mov    %edi,%ebx
  sub    $0x30,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  comisd %xmm1,%xmm0
  jbe    L17
  xorpd  D112(%rip),%xmm1
  add    $0x2,%ebx
L17:
  mulsd  D31(%rip),%xmm1
  comisd D114(%rip),%xmm1
  ja     L8
  cvttsd2si %xmm1,%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  lea    (%rbx,%rax,1),%edi
  and    $0x3,%edi
  subsd  %xmm0,%xmm1
L59:
  test   $0x1,%dil
  je     L23
  movsd  D135(%rip),%xmm0
  subsd  %xmm1,%xmm0
  movapd %xmm0,%xmm1
L23:
  cmp    $0x1,%edi
  jle    L40
  xorpd  D112(%rip),%xmm1
L40:
  movapd %xmm1,%xmm2
  movsd  D89(%rip),%xmm0
  mulsd  %xmm1,%xmm2
  mulsd  %xmm2,%xmm0
  subsd  D66(%rip),%xmm0
  mulsd  %xmm2,%xmm0
  addsd  D48(%rip),%xmm0
  mulsd  %xmm2,%xmm0
  subsd  D108(%rip),%xmm0
  mulsd  %xmm2,%xmm0
  addsd  D115(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  D57(%rip),%xmm1
  addsd  %xmm2,%xmm1
  mulsd  %xmm2,%xmm1
  addsd  D1(%rip),%xmm1
  mulsd  %xmm2,%xmm1
  addsd  D65(%rip),%xmm1
  mulsd  %xmm2,%xmm1
  addsd  D64(%rip),%xmm1
  divsd  %xmm1,%xmm0
  mov    0x28(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L49
  add    $0x30,%rsp
  pop    %rbx
  ret
  nopl   0x0(%rax)
L8:
  movapd %xmm1,%xmm0
  lea    0x18(%rsp),%rdi
  call   <modf@plt>
  pxor   %xmm2,%xmm2
  lea    0x20(%rsp),%rdi
  cvtsi2sd %ebx,%xmm2
  addsd  0x18(%rsp),%xmm2
  movsd  %xmm0,0x8(%rsp)
  movapd %xmm2,%xmm0
  movsd  %xmm2,(%rsp)
  mulsd  D11(%rip),%xmm0
  call   <modf@plt>
  movsd  (%rsp),%xmm2
  movsd  D159(%rip),%xmm0
  mulsd  0x20(%rsp),%xmm0
  movsd  0x8(%rsp),%xmm1
  subsd  %xmm0,%xmm2
  cvttsd2si %xmm2,%edi
  jmp    L59
L49:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: tag: D112
data_type: byte[16]
name: disassemble_data
arguments: tag: D31
data_type: f64
name: disassemble_data
arguments: tag: D114
data_type: byte[16]
name: disassemble_data
arguments: tag: D135
data_type: byte[8]
name: disassemble_data
arguments: tag: D89
data_type: f64
name: disassemble_data
arguments: tag: D66
data_type: f64
name: disassemble_data
arguments: tag: D48
data_type: f64
name: disassemble_data
arguments: tag: D108
data_type: f64
name: disassemble_data
arguments: tag: D115
data_type: f64
name: disassemble_data
arguments: tag: D57
data_type: f64
name: disassemble_data
arguments: tag: D1
data_type: f64
name: disassemble_data
arguments: tag: D65
data_type: f64
name: disassemble_data
arguments: tag: D64
data_type: f64
name: disassemble_data
arguments: tag: D11
data_type: f64
name: disassemble_data
arguments: tag: D159
data_type: byte[8]

tool: {"D112": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00]}

tool: D31: 0.636619772367581

tool: {"D114": [0x00,0x00,0x00,0x00,0x00,0xff,0xdf,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0xd0,0x3f]}

tool: {"D135": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x3f]}

tool: D89: 145.968840666577

tool: D66: 13847.2724998245

tool: D48: 440103.053537527

tool: D108: 4942908.10090284

tool: D115: 13578840.9787738

tool: D57: 132.653490878614

tool: D1: 9463.09610153821

tool: D65: 408179.22523433

tool: D64: 8644558.65292253

tool: D11: 0.25

tool: {"D159": [0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x40]}

assistant: ```c
double sinus(double arg, int quad) {
  double e, f;
  int k;
  double ysq;
  double x, y;
  double temp1, temp2;
  x = arg;
  if (x < 0) {
    x = -x;
    quad = quad + 2;
  }
  x = x * 0.636619772367581;
  if (x > 32764) {
    y = modf(x, &e);
    e = e + quad;
    modf(0.25 * e, &f);
    quad = e - 4 * f;
  } else {
    k = x;
    y = x - k;
    quad = (quad + k) & 03;
  }
  if (quad & 01)
    y = 1 - y;
  if (quad > 1)
    y = -y;
  ysq = y * y;
  temp1 = ((((0.145968840666577e3 * ysq + -0.138472724998245e5) * ysq + 0.440103053537527e6) * ysq + -0.494290810090284e7) * ysq + 0.135788409787738e8) * y;
  temp2 = ((((ysq + 0.132653490878614e3) * ysq + 0.946309610153821e4) * ysq + 0.408179225234330e6) * ysq + 0.864455865292253e7);
  return (temp1 / temp2);
}
```