Welcome to mirror list, hosted at ThFree Co, Russian Federation.

sqrtf.h « headers « spu « machine « libm « newlib - cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: c1f5ab2239cac93c121581df0e2e94158b0faacc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "headers/sqrtf4.h"
#include "headers/dom_chkf_less_than.h"

static __inline float _sqrtf(float in)
{
  float res;
  vector float vx;
  vector float vc = { 0.0, 0.0, 0.0, 0.0 };

  vx = spu_promote(in, 0);
  res = spu_extract(_sqrtf4(vx), 0);
#ifndef _IEEE_LIBM
  dom_chkf_less_than(vx, vc);
#endif
  return res;
}