user: Translate the below assembly code into C programming language:

```asm
<DEVfetlim>:
  endbr64
  movapd %xmm1,%xmm3
  subsd  %xmm2,%xmm3
  addsd  %xmm3,%xmm3
  pxor   %xmm4,%xmm4
  comisd %xmm3,%xmm4
  ja     L172
L96:
  movsd  D36(%rip),%xmm5
  addsd  %xmm5,%xmm3
  movapd %xmm3,%xmm4
  mulsd  D8(%rip),%xmm4
  addsd  %xmm5,%xmm4
  movapd %xmm0,%xmm5
  subsd  %xmm1,%xmm5
  comisd %xmm2,%xmm1
  jb     L139
  movapd %xmm2,%xmm6
  addsd  D79(%rip),%xmm6
  comisd %xmm6,%xmm1
  jb     L68
  pxor   %xmm7,%xmm7
  comisd %xmm5,%xmm7
  jae    L53
  movapd %xmm0,%xmm2
  comisd %xmm3,%xmm5
  jb     L104
  addsd  %xmm3,%xmm1
  movapd %xmm1,%xmm2
  jmp    L104
L172:
  xorpd  D3(%rip),%xmm3
  jmp    L96
L53:
  comisd %xmm6,%xmm0
  jb     L133
  xorpd  D3(%rip),%xmm5
  movapd %xmm0,%xmm2
  comisd %xmm4,%xmm5
  jbe    L104
  subsd  %xmm4,%xmm1
  movapd %xmm1,%xmm2
  jmp    L104
L133:
  addsd  D36(%rip),%xmm2
  maxsd  %xmm2,%xmm0
  movapd %xmm0,%xmm2
  jmp    L104
L68:
  pxor   %xmm1,%xmm1
  comisd %xmm5,%xmm1
  jae    L128
  addsd  D63(%rip),%xmm2
  minsd  %xmm2,%xmm0
  movapd %xmm0,%xmm2
L104:
  movapd %xmm2,%xmm0
  ret
L128:
  subsd  D8(%rip),%xmm2
  maxsd  %xmm2,%xmm0
  movapd %xmm0,%xmm2
  jmp    L104
L139:
  pxor   %xmm6,%xmm6
  comisd %xmm5,%xmm6
  jae    L7
  addsd  D8(%rip),%xmm2
  comisd %xmm0,%xmm2
  jb     L104
  movapd %xmm0,%xmm2
  comisd %xmm4,%xmm5
  jbe    L104
  addsd  %xmm4,%xmm1
  movapd %xmm1,%xmm2
  jmp    L104
L7:
  xorpd  D3(%rip),%xmm5
  movapd %xmm0,%xmm2
  comisd %xmm3,%xmm5
  jbe    L104
  subsd  %xmm3,%xmm1
  movapd %xmm1,%xmm2
  jmp    L104
```

tool_calls: name: unpack_data
arguments: tag: D36
type_guessed: byte[8]
name: unpack_data
arguments: tag: D8
type_guessed: byte[8]
name: unpack_data
arguments: tag: D79
type_guessed: f64
name: unpack_data
arguments: tag: D3
type_guessed: byte[16]
name: unpack_data
arguments: tag: D63
type_guessed: byte[8]

tool: {"D36": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40]}

tool: {"D8": [0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f]}

tool: D79: 3.5

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

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

assistant: ```c
double DEVfetlim(vnew, vold, vto)
double vnew;
double vold;
double vto;
{
  double vtsthi;
  double vtstlo;
  double vtox;
  double delv;
  double vtemp;
  vtsthi = (((2 * (vold - vto)) < 0) ? -(2 * (vold - vto)) : (2 * (vold - vto))) + 2;
  vtstlo = vtsthi / 2 + 2;
  vtox = vto + 3.5;
  delv = vnew - vold;
  if (vold >= vto) {
    if (vold >= vtox) {
      if (delv <= 0) {
        if (vnew >= vtox) {
          if (-delv > vtstlo) {
            vnew = vold - vtstlo;
          }
        } else {
          vnew = ((vnew) > (vto + 2) ? (vnew) : (vto + 2));
        }
      } else {
        if (delv >= vtsthi) {
          vnew = vold + vtsthi;
        }
      }
    } else {
      if (delv <= 0) {
        vnew = ((vnew) > (vto - .5) ? (vnew) : (vto - .5));
      } else {
        vnew = ((vnew) < (vto + 4) ? (vnew) : (vto + 4));
      }
    }
  } else {
    if (delv <= 0) {
      if (-delv > vtsthi) {
        vnew = vold - vtsthi;
      }
    } else {
      vtemp = vto + .5;
      if (vnew <= vtemp) {
        if (delv > vtstlo) {
          vnew = vold + vtstlo;
        }
      } else {
        vnew = vtemp;
      }
    }
  }
  return (vnew);
}
```