about summary refs log tree commit diff
path: root/sysdeps/loongarch/fpu
Commit message (Collapse)AuthorAgeFilesLines
* Update copyright dates with scripts/update-copyrightsPaul Eggert2024-01-0156-56/+56
|
* Fix misspellings in sysdeps/ -- BZ 25337Paul Pluzhnikov2023-05-301-1/+1
|
* LoongArch: Add get_rounding_mode.caiyinyu2023-03-131-0/+38
|
* LoongArch: Add math-barriers.hXi Ruoyao2023-02-271-0/+28
| | | | | | | | This patch implements the LoongArch specific math barriers in order to omit the store and load from stack if possible. Signed-off-by: Xi Ruoyao <xry111@xry111.site> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Update copyright dates with scripts/update-copyrightsJoseph Myers2023-01-0654-54/+54
|
* LoongArch: Add support for ilogb[f]Xiaolin Tang2022-11-292-0/+78
| | | | Add inline assembler for the ilogb functions. Passes GLIBC regression.
* LoongArch: Add support for scalb[f]Xiaolin Tang2022-11-292-0/+120
| | | | Add inline assembler for the scalb functions. Passes GLIBC regression.
* LoongArch: Add support for scalbn[f]Xiaolin Tang2022-11-292-0/+58
| | | | | | | | Add inline assembler for the scalbn functions. Passes GLIBC regression. GCC 13, LoongArch support ___builtin_scalbn{,f} with -fno-math-errno, but only "libm" can use -fno-math-errno in GLIBC, and scalbn is in libc instead of libm because __printf_fp calls it.
* LoongArch: Use __builtin_logb{,f} with GCC >= 13Xiaolin Tang2022-11-291-0/+10
| | | | | | | | GCC 13 compiles these built-ins instead of generic implementation for function logb. Link: https://gcc.gnu.org/r13-3922 Co-Authored-By: Xi Ruoyao <xry111@xry111.site>
* LoongArch: Use __builtin_llrint{,f} with GCC >= 13Xiaolin Tang2022-11-291-0/+10
| | | | | | | | GCC 13 compiles these built-ins instead of generic implementation for function llrint. Link: https://gcc.gnu.org/r13-3920 Co-Authored-By: Xi Ruoyao <xry111@xry111.site>
* LoongArch: Use __builtin_lrint{,f} with GCC >= 13Xiaolin Tang2022-11-291-0/+10
| | | | | | | | GCC 13 compiles these built-ins instead of generic implementation for function lrint. Link: https://gcc.gnu.org/r13-3920 Co-Authored-By: Xi Ruoyao <xry111@xry111.site>
* LoongArch: Use __builtin_rint{,f} with GCC >= 13Xi Ruoyao2022-11-291-0/+9
| | | | | | GCC 13 compiles these built-ins to frint.{d,s} instruction. Link: https://gcc.gnu.org/r13-3919
* LoongArch: Hard Float Support for fmaximum_mag_num{f/ }, fminimum_mag_num{f/ }.Xiaolin Tang2022-11-144-0/+192
| | | | | | | | | | Use hardware Floating-point instruction f{maxa/mina}.{s/d}, fclass.{s/d} to implement fmaximum_mag_num{f/ }, fminimum_mag_num{f/ }. * sysdeps/loongarch/fpu/s_fmaximum_mag_num.c: New file. * sysdeps/loongarch/fpu/s_fmaximum_mag_numf.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_mag_num.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_mag_numf.c: Likewise.
* LoongArch: Hard Float Support for fmaximum_mag{f/ }, fminimum_mag{f/ }.Xiaolin Tang2022-11-144-0/+160
| | | | | | | | | | Use hardware Floating-point instruction f{maxa/mina}.{s/d}, fclass.{s/d} to implement fmaximum_mag{f/ }, fminimum_mag{f/ }. * sysdeps/loongarch/fpu/s_fmaximum_mag.c: New file. * sysdeps/loongarch/fpu/s_fmaximum_magf.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_mag.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_magf.c: Likewise.
* LoongArch: Hard Float Support for fmaxmag{f/ }, fminmag{f/ }.Xiaolin Tang2022-11-144-0/+116
| | | | | | | | | | Use hardware Floating-point instruction f{maxa/mina}.{s/d}, to implement fmaxmag{f/ }, fminmag{f/ }. * sysdeps/loongarch/fpu/s_fmaxmag.c: New file. * sysdeps/loongarch/fpu/s_fmaxmagf.c: Likewise. * sysdeps/loongarch/fpu/s_fminmag.c: Likewise. * sysdeps/loongarch/fpu/s_fminmagf.c: Likewise.
* LoongArch: Hard Float Support for fmaximum_num{f/ }, fminimum_num{f/ }.Xiaolin Tang2022-11-144-0/+193
| | | | | | | | | | Use hardware Floating-point instruction f{max/min}.{s/d}, fclass.{s/d} to implement fmaximum_num{f/ }, fminimum_num{f/ }. * sysdeps/loongarch/fpu/s_fmaximum_num.c: New file. * sysdeps/loongarch/fpu/s_fmaximum_numf.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_num.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum_numf.c: Likewise.
* LoongArch: Hard Float Support for fmaximum{f/ }, fminimum{f/ }.Xiaolin Tang2022-11-144-0/+160
| | | | | | | | | | Use hardware Floating-point instruction f{max/min}.{s/d}, fclass.{s/d} to implement fmaximum{f/ }, fminimum{f/ }. * sysdeps/loongarch/fpu/s_fmaximum.c: New file. * sysdeps/loongarch/fpu/s_fmaximumf.c: Likewise. * sysdeps/loongarch/fpu/s_fminimum.c: Likewise. * sysdeps/loongarch/fpu/s_fminimumf.c: Likewise.
* LoongArch: Hard Float Support for float-point classification functions.Xiaolin Tang2022-11-1410-0/+316
| | | | | | | | | | | | | | | | | | Use hardware Floating-point instruction fclass.{s/d} to implement classification functions, i.e finite{f/ }, fpclassify{f/ }, isnan{f/ }, isinf{f/ }, issignaling{f/ }. * sysdeps/loongarch/fpu/s_finite.c: New file. * sysdeps/loongarch/fpu/s_finitef.c: Likewise. * sysdeps/loongarch/fpu/s_fpclassify.c: Likewise. * sysdeps/loongarch/fpu/s_fpclassifyf.c: Likewise. * sysdeps/loongarch/fpu/s_isinf.c: Likewise. * sysdeps/loongarch/fpu/s_isinff.c: Likewise. * sysdeps/loongarch/fpu/s_isnan.c: Likewise. * sysdeps/loongarch/fpu/s_isnanf.c: Likewise. * sysdeps/loongarch/fpu/s_issignaling.c: Likewise. * sysdeps/loongarch/fpu/s_issignalingf.c: Likewise. * sysdeps/loongarch/fpu_control.h: Add _FCLASS_* macro.
* LoongArch: Use __builtin_{fma, fmaf} to implement function {fma, fmaf}.Xiaolin Tang2022-11-141-0/+4
| | | | | | | Use __builtin_{fma, fmaf} to implement function {fma, fmaf} instead of the generic implementation. * sysdeps/loongarch/fpu/math-use-builtins-fma.h: New file.
* LoongArch: Use __builtin_{fmax,fmaxf,fmin,fminf} with GCC >= 13Xi Ruoyao2022-08-302-0/+20
| | | | | | | | GCC 13 compiles these built-ins to {fmax,fmin}.{s/d} instruction, use them instead of the generic implementation. Link: https://gcc.gnu.org/r13-2085 Signed-off-by: Xi Ruoyao <xry111@xry111.site>
* LoongArch: Hard Float Supportcaiyinyu2022-07-2619-0/+711