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

```asm
<__kernel_cos>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  movsd  %xmm0,-0x48(%rbp)
  movsd  %xmm1,-0x50(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  lea    -0x48(%rbp),%rax
  add    $0x4,%rax
  mov    (%rax),%eax
  and    $0x7fffffff,%eax
  mov    %eax,-0x34(%rbp)
  cmpl   $0x3e3fffff,-0x34(%rbp)
  jg     L48
  movsd  -0x48(%rbp),%xmm0
  cvttsd2si %xmm0,%eax
  test   %eax,%eax
  jne    L48
  movsd  D91(%rip),%xmm0
  jmp    L10
L48:
  movsd  -0x48(%rbp),%xmm1
  movsd  -0x48(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x28(%rbp),%xmm1
  movsd  D92(%rip),%xmm0
  mulsd  %xmm0,%xmm1
  movsd  D111(%rip),%xmm0
  addsd  %xmm1,%xmm0
  mulsd  -0x28(%rbp),%xmm0
  movsd  D78(%rip),%xmm1
  subsd  %xmm1,%xmm0
  movapd %xmm0,%xmm1
  mulsd  -0x28(%rbp),%xmm1
  movsd  D0(%rip),%xmm0
  addsd  %xmm1,%xmm0
  mulsd  -0x28(%rbp),%xmm0
  movsd  D41(%rip),%xmm1
  subsd  %xmm1,%xmm0
  movapd %xmm0,%xmm1
  mulsd  -0x28(%rbp),%xmm1
  movsd  D77(%rip),%xmm0
  addsd  %xmm1,%xmm0
  movsd  -0x28(%rbp),%xmm1
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  cmpl   $0x3fd33332,-0x34(%rbp)
  jg     L60
  movsd  -0x28(%rbp),%xmm1
  movsd  D80(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  -0x28(%rbp),%xmm1
  mulsd  -0x20(%rbp),%xmm1
  movsd  -0x48(%rbp),%xmm2
  movapd %xmm2,%xmm3
  mulsd  -0x50(%rbp),%xmm3
  movapd %xmm1,%xmm2
  subsd  %xmm3,%xmm2
  movapd %xmm0,%xmm1
  subsd  %xmm2,%xmm1
  movsd  D91(%rip),%xmm0
  subsd  %xmm1,%xmm0
  jmp    L10
L60:
  cmpl   $0x3fe90000,-0x34(%rbp)
  jle    L58
  movsd  D18(%rip),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  jmp    L37
L58:
  lea    -0x30(%rbp),%rax
  add    $0x4,%rax
  mov    -0x34(%rbp),%edx
  sub    $0x200000,%edx
  mov    %edx,(%rax)
  lea    -0x30(%rbp),%rax
  movl   $0x0,(%rax)
L37:
  movsd  -0x28(%rbp),%xmm1
  movsd  D80(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  -0x30(%rbp),%xmm1
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x18(%rbp)
  movsd  -0x30(%rbp),%xmm1
  movsd  D91(%rip),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x10(%rbp)
  movsd  -0x28(%rbp),%xmm0
  mulsd  -0x20(%rbp),%xmm0
  movsd  -0x48(%rbp),%xmm1
  mulsd  -0x50(%rbp),%xmm1
  movapd %xmm0,%xmm2
  subsd  %xmm1,%xmm2
  movsd  -0x18(%rbp),%xmm0
  movapd %xmm0,%xmm1
  subsd  %xmm2,%xmm1
  movsd  -0x10(%rbp),%xmm0
  subsd  %xmm1,%xmm0
L10:
  movq   %xmm0,%rax
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L65
  call   <__stack_chk_fail@plt>
L65:
  movq   %rax,%xmm0
  leave
  ret
```

tool_calls: name: read_data
arguments: label: D91
type_infered: byte[8]
name: read_data
arguments: label: D92
type_infered: byte[8]
name: read_data
arguments: label: D111
type_infered: byte[8]
name: read_data
arguments: label: D78
type_infered: byte[8]
name: read_data
arguments: label: D0
type_infered: byte[8]
name: read_data
arguments: label: D41
type_infered: byte[8]
name: read_data
arguments: label: D77
type_infered: byte[8]
name: read_data
arguments: label: D80
type_infered: f64
name: read_data
arguments: label: D18
type_infered: f64

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

tool: {"D92": [0xd4,0x38,0x88,0xbe,0xe9,0xfa,0xa8,0xbd]}

tool: {"D111": [0xc4,0xb1,0xb4,0xbd,0x9e,0xee,0x21,0x3e]}

tool: {"D78": [0xad,0x52,0x9c,0x80,0x4f,0x7e,0x92,0x3e]}

tool: {"D0": [0x90,0x15,0xcb,0x19,0xa0,0x01,0xfa,0x3e]}

tool: {"D41": [0x77,0x51,0xc1,0x16,0x6c,0xc1,0x56,0x3f]}

tool: {"D77": [0x4c,0x55,0x55,0x55,0x55,0x55,0xa5,0x3f]}

tool: D80: 0.5

tool: D18: 0.28125

assistant: ```c
double __kernel_cos(double x, double y) {
  double a, hz, z, r, qx;
  int ix;
  ix = *(1 + (int *)&x) & 0x7fffffff;
  if (ix < 0x3e400000) {
    if (((int)x) == 0) {
      return 1.00000000000000000000e+00;
    }
  }
  z = x * x;
  r = z * (4.16666666666666019037e-02 + z * (-1.38888888888741095749e-03 + z * (2.48015872894767294178e-05 + z * (-2.75573143513906633035e-07 + z * (2.08757232129817482790e-09 + z * -1.13596475577881948265e-11)))));
  if (ix < 0x3FD33333) {
    return 1.00000000000000000000e+00 - (0.5 * z - (z * r - x * y));
  } else {
    if (ix > 0x3fe90000) {
      qx = 0.28125;
    } else {
      *(1 + (int *)&qx) = ix - 0x00200000;
      *(int *)&qx = 0;
    }
    hz = 0.5 * z - qx;
    a = 1.00000000000000000000e+00 - qx;
    return a - (hz - (z * r - x * y));
  }
}
```