OpenCores
URL https://opencores.org/ocsvn/hf-risc/hf-risc/trunk

Subversion Repositories hf-risc

[/] [hf-risc/] [trunk/] [tools/] [riscv-gnu-toolchain-master/] [glibc/] [sysdeps/] [riscv/] [fpu/] [s_fminf.c] - Rev 13

Compare with Previous | Blame | View Log

#include <math.h>
 
float __fminf (float x, float y)
{
#ifdef __riscv_soft_float
  if (isnan(x))
    return y;
  if (isnan(y))
    return x;
  return (x < y) ? x : y;
#else
  float res;
  asm ("fmin.s %0, %1, %2" : "=f"(res) : "f"(x), "f"(y));
  return res;
#endif
}
weak_alias (__fminf, fminf)
 

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.