18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-or-later */ 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci 48c2ecf20Sopenharmony_ci fp_arith.h: floating-point math routines for the Linux-m68k 58c2ecf20Sopenharmony_ci floating point emulator. 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_ci Copyright (c) 1998 David Huggins-Daines. 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ci Somewhat based on the AlphaLinux floating point emulator, by David 108c2ecf20Sopenharmony_ci Mosberger-Tang. 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_ci 138c2ecf20Sopenharmony_ci */ 148c2ecf20Sopenharmony_ci 158c2ecf20Sopenharmony_ci#ifndef FP_ARITH_H 168c2ecf20Sopenharmony_ci#define FP_ARITH_H 178c2ecf20Sopenharmony_ci 188c2ecf20Sopenharmony_ci/* easy ones */ 198c2ecf20Sopenharmony_cistruct fp_ext * 208c2ecf20Sopenharmony_cifp_fabs(struct fp_ext *dest, struct fp_ext *src); 218c2ecf20Sopenharmony_cistruct fp_ext * 228c2ecf20Sopenharmony_cifp_fneg(struct fp_ext *dest, struct fp_ext *src); 238c2ecf20Sopenharmony_ci 248c2ecf20Sopenharmony_ci/* straightforward arithmetic */ 258c2ecf20Sopenharmony_cistruct fp_ext * 268c2ecf20Sopenharmony_cifp_fadd(struct fp_ext *dest, struct fp_ext *src); 278c2ecf20Sopenharmony_cistruct fp_ext * 288c2ecf20Sopenharmony_cifp_fsub(struct fp_ext *dest, struct fp_ext *src); 298c2ecf20Sopenharmony_cistruct fp_ext * 308c2ecf20Sopenharmony_cifp_fcmp(struct fp_ext *dest, struct fp_ext *src); 318c2ecf20Sopenharmony_cistruct fp_ext * 328c2ecf20Sopenharmony_cifp_ftst(struct fp_ext *dest, struct fp_ext *src); 338c2ecf20Sopenharmony_cistruct fp_ext * 348c2ecf20Sopenharmony_cifp_fmul(struct fp_ext *dest, struct fp_ext *src); 358c2ecf20Sopenharmony_cistruct fp_ext * 368c2ecf20Sopenharmony_cifp_fdiv(struct fp_ext *dest, struct fp_ext *src); 378c2ecf20Sopenharmony_ci 388c2ecf20Sopenharmony_ci/* ones that do rounding and integer conversions */ 398c2ecf20Sopenharmony_cistruct fp_ext * 408c2ecf20Sopenharmony_cifp_fmod(struct fp_ext *dest, struct fp_ext *src); 418c2ecf20Sopenharmony_cistruct fp_ext * 428c2ecf20Sopenharmony_cifp_frem(struct fp_ext *dest, struct fp_ext *src); 438c2ecf20Sopenharmony_cistruct fp_ext * 448c2ecf20Sopenharmony_cifp_fint(struct fp_ext *dest, struct fp_ext *src); 458c2ecf20Sopenharmony_cistruct fp_ext * 468c2ecf20Sopenharmony_cifp_fintrz(struct fp_ext *dest, struct fp_ext *src); 478c2ecf20Sopenharmony_cistruct fp_ext * 488c2ecf20Sopenharmony_cifp_fscale(struct fp_ext *dest, struct fp_ext *src); 498c2ecf20Sopenharmony_ci 508c2ecf20Sopenharmony_ci#endif /* FP_ARITH__H */ 51