user: Converte this assembly snippet into its equivalent C code:

```asm
<c_sapx>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %edi,-0x14(%rbp)
  movss  %xmm0,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %edx,-0x24(%rbp)
  cmpl   $0x0,-0x14(%rbp)
  jle    L71
  pxor   %xmm0,%xmm0
  ucomiss -0x18(%rbp),%xmm0
  jp     L67
  pxor   %xmm0,%xmm0
  ucomiss -0x18(%rbp),%xmm0
  je     L71
L67:
  cmpl   $0x1,-0x24(%rbp)
  jne    L40
  mov    -0x14(%rbp),%eax
  movslq %eax,%rdx
  imul   $0x66666667,%rdx,%rdx
  shr    $0x20,%rdx
  sar    %edx
  mov    %eax,%esi
  sar    $0x1f,%esi
  mov    %edx,%ecx
  sub    %esi,%ecx
  mov    %ecx,%edx
  shl    $0x2,%edx
  add    %ecx,%edx
  sub    %edx,%eax
  mov    %eax,-0x4(%rbp)
  cmpl   $0x0,-0x4(%rbp)
  jle    L57
  movl   $0x0,-0x8(%rbp)
  jmp    L45
L95:
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  addl   $0x1,-0x8(%rbp)
L45:
  mov    -0x8(%rbp),%eax
  cmp    -0x4(%rbp),%eax
  jl     L95
L57:
  cmpl   $0x4,-0x14(%rbp)
  jle    L155
  mov    -0x4(%rbp),%eax
  mov    %eax,-0x8(%rbp)
  jmp    L123
L117:
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x2,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x2,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x3,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x3,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x4,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x8(%rbp),%eax
  cltq
  add    $0x4,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  addl   $0x5,-0x8(%rbp)
L123:
  mov    -0x8(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jl     L117
  jmp    L125
L40:
  cmpl   $0x0,-0x24(%rbp)
  jns    L12
  mov    $0x1,%eax
  sub    -0x14(%rbp),%eax
  mov    -0x24(%rbp),%edx
  imul   %edx,%eax
  mov    %eax,-0xc(%rbp)
  jmp    L18
L12:
  movl   $0x0,-0xc(%rbp)
L18:
  movl   $0x0,-0x8(%rbp)
  jmp    L145
L146:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  addss  -0x18(%rbp),%xmm0
  movss  %xmm0,(%rax)
  mov    -0x24(%rbp),%eax
  add    %eax,-0xc(%rbp)
  addl   $0x1,-0x8(%rbp)
L145:
  mov    -0x8(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jl     L146
  jmp    L125
L71:
  nop
  jmp    L125
L155:
  nop
L125:
  pop    %rbp
  ret
```

assistant: ```c
void c_sapx(const int64_t N, const float alpha, float *X, const int64_t stride) {
  int64_t ix;
  int64_t m;
  int64_t i;
  if (N <= 0 || alpha == 0.0) {
    return;
  }
  if (stride == 1) {
    m = N % 5;
    if (m > 0) {
      for (i = 0; i < m; i++) {
        X[i] += alpha;
      }
    }
    if (N < 5) {
      return;
    }
    for (i = m; i < N; i += 5) {
      X[i] += alpha;
      X[i + 1] += alpha;
      X[i + 2] += alpha;
      X[i + 3] += alpha;
      X[i + 4] += alpha;
    }
    return;
  }
  if (stride < 0) {
    ix = (1 - N) * stride;
  } else {
    ix = 0;
  }
  for (i = 0; i < N; i++) {
    X[ix] += alpha;
    ix += stride;
  }
  return;
}
```