FLIP: Floating-point Library for Integer Processors
Software support for floating-point arithmetic on integer processors
FLIP is a C library that provides a software support for binary32 floating-point arithmetic on integer processors. This library is particularly targeted to VLIW or DSP processors (that is, embedded systems), and has been validated on VLIW integer processors like those of the ST200 family from STMicroelectronics.This library provides software implementation for the five basic arithmetic operations (addition, subtraction, multiplication, division, and square root) with subnormal numbers support, and for the four rounding-direction attributes (RoundTiesToEven, RoundTowardPositive, RoundTowardNegative, RoundTowardZero) required by the IEEE 754-2008 standard.
FLIP is contributed by the Arénaire (now AriC) project-team (INRIA Grenoble - Rhône-Alpes) within the LIP laboratory at ENS Lyon.
The main developers of the latest version (FLIP-1.0) are Claude-Pierre Jeannerod and Guillaume Revy.
Download
FLIP-1.0 is the latest released version of FLIP. Please, contact us for how to get it.Older, no longer maintained versions of FLIP are also available upon requiest.
Performances
FLIP has been validated on ST231 VLIW processor. Performances on ST231 can be found here.Example
The following program can be downloaded here.#include<stdio.h> #include<flip.h> int main(void) { float a = 17.0128421783447265625000000f; float b = 1.24564564228057861328125000f; printf("a = %1.30f\n",a); printf("b = %1.30f\n",b); printf("add(a,b) = %1.30f\n",flip_addf(a,b)); printf("sub(a,b) = %1.30f\n",flip_subf(a,b)); printf("mul(a,b) = %1.30f\n",flip_mulf(a,b)); printf("div(a,b) = %1.30f\n",flip_divf(a,b)); printf("sqrt(a) = %1.30f\n",flip_sqrtf(a)); printf("sqrt(b) = %1.30f\n",flip_sqrtf(b)); return 0; }
To compile, just type in a terminal:
$ gcc -o test-flip test-flip.c -lflipThe result of this program is:
$ ./test-flip a = 17.012842178344726562500000000000 b = 1.245645642280578613281250000000 add(a,b) = 18.258487701416015625000000000000 sub(a,b) = 15.767196655273437500000000000000 mul(a,b) = 21.191972732543945312500000000000 div(a,b) = 13.657850265502929687500000000000 sqrt(a) = 4.124662876129150390625000000000 sqrt(b) = 1.116084933280944824218750000000
Bibliography
- Simultaneous floating-point sine and cosine for VLIW integer processors. Claude-Pierre Jeannerod and Jingyan Jourdan-Lu. 23rd IEEE International Conference on Application-Specific Systems, Architectures and Processors (ASAP), Delft, Netherlands, 2012.
- How to square floats accurately and efficiently on the ST231 integer processor. Claude-Pierre Jeannerod, Jingyan Jourdan-Lu, Christophe Monat, and Guillaume Revy. 20th IEEE Symposium on Computer Arithmetic (ARITH'20), Tuebingen, Germany, 2011.
- Computing floating-point square roots via bivariate polynomial evaluation. Claude-Pierre Jeannerod, Hervé Knochel, Christophe Monat, and Guillaume Revy. IEEE Transactions on Computers, Special Section on Computer Arithmetic, 2011.
- Techniques and tools for implementing IEEE 754 floating-point arithmetic on VLIW integer processors. Christian Bertin, Claude-Pierre Jeannerod, Jingyan Jourdan-Lu, Hervé Knochel, Christophe Monat, Christophe Mouilleron, Jean-Michel Muller, and Guillaume Revy. 4th International Workshop on Parallel and Symbolic Computation (PASCO'2010), Grenoble, France, 2010.
- Implementation of binary floating-point arithmetic on embedded integer processors - Polynomial evaluation-based algorithms and certified code generation. Guillaume Revy. Ph.D. Thesis, Université de Lyon - École Normale Supérieure de Lyon, France, 2009.
- Optimizing correctly-rounded reciprocal square roots for embedded VLIW cores. Claude-Pierre Jeannerod and Guillaume Revy. 43rd Asilomar Conference on Signals, Systems, and Computers (Asilomar'09), Pacific Grove, CA, USA, 2009.
- A new binary floating-point division algorithm and its software implementation on the ST231 processor. Claude-Pierre Jeannerod, Hervé Knochel, Christophe Monat, Guillaume Revy, and Gilles Villard. 19th IEEE Symposium on Computer Arithmetic (ARITH'19), Portland, OR, USA, 2009.
- Faster floating-point square root for integer processors. Claude-Pierre Jeannerod, Hervé Knochel, Christophe Monat, and Guillaume Revy. 2nd IEEE International Symposium on Industrial Embedded Systems (SIES'2007), Lisbon, Portugal, 2007.
Claude-Pierre Jeannerod, Guillaume Revy
Last modification: 10-19-2021 17:31:55 CEST.