3 ms·
AFAIK IEEE 754 does allow for some variation in the results of operations like log and exp. I recall this being an issue with the LHC@Home BOINC project, where
by magicalhippo 5y ago
AFAIK IEEE 754 does allow for some variation in the results of operations like log and exp. I recall this being an issue with the LHC@Home BOINC project, where simulations computed on Intels would run for a long time before reaching the termination condition (beam hitting wall) while when computed on AMDs would terminate quickly.
For a project relying on multiple runs on different computers for verification of correctness, this was a serious issue. IIRC before they solved it properly, they had to increase the number of validations per piece of work, as well as trying to segregate the work so a work unit was only issued to either Intel or AMD but not both. This only reduced the impact somewhat though.
From their[1] page:
Besides helping build the LHC, LHC@home has proved to be an invaluable, even essential, tool for investigating and solving fundamental problems with floating-point arithmetic. Different processors, even of the same brand, all conforming more or less to the IEE754 standard, produce different results, a problem further compounded by the different libraries provided for Linux and Windows. In particular, a major problem was the evaluation of the elementary functions, such as exponent and logarithm, which are not covered by the standard at all (apart from the square root function). This problem was solved by the use of the correctly rounded elementary function library (crlibm) developed by a group at the Ecole Nationale Supérieure in Lyon. Due to the often chaotic motion of the particles even a one unit of difference in the last digit of a binary number produces completely different results, as the difference grows exponentially as the particle circulates for up to one million turns round the LHC. Thus it is extremely difficult to find bugs or to verify new software and hardware platforms. This methodology has allowed us to detect failing hardware, otherwise unnoticed, and to find compiler bugs. With your help, it is being extended to ensure identical results on any IEE754 compliant processor with a standard compliant compiler (C++ or FORTRAN) which will allow us to work on any such system and even on Graphical Processing Units (GPUs).
[1]: https://lhcathome.web.cern.ch/projects/sixtrack/sixtrack-and-numerical-simulations https://lhcathome.web.cern.ch/projects/sixtrack/sixtrack-and... (