Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Also, five types of floating-point exception are identified:
* Invalid. Operations with mathematically invalid operands--for example, 0.0/0.0, sqrt(-1.0), and log(-37.8)
* Division by zero. Divisor is zero and dividend is a finite nonzero number--for example, 9.9/0.0
* Overflow. Operation produces a result that exceeds the range of the exponent-- for example, MAXDOUBLE+0.0000000000001e308
* Underflow. Operation produces a result that is too small to be represented as a normal number--for example, MINDOUBLE * MINDOUBLE
* Inexact. Operation produces a result that cannot be represented with infinite precision--for example, 2.0 / 3.0, log(1.1) and 0.1 in input
The implementation of the IEEE standard is described in the Sun Numerical Computation Guide.
Basically, it looks like it amounts to performing a math equation that your math teacher would've yelled at you in highschool for.
Isn't it also possible that you have compiled your app with compiler options that assumes there is a floating point processor present and you don't have one on your ARM board? More info on your target hardware, please?
I dig up this old thread : I am in the same situation as mathb 2 years ago :
I try to run my application on an arm board with linux OS and the application crashes sometimes (rare) with floating point exception.
There is a dividing operation in the code, (random division) but I check that it is not a zero divide.
What seems the more probable is "Inexact" type reported by akuthia... But I don't really understand why "Inexact" type is a problem? i.e why making operation 2.0 / 3.0 should crash the application? In my mind the result should just be truncated to 0.6666667 ....
Okay, I made a quick hello world test with 2.0/3.0 operations and with my environment, it is truncated to 0.666667 .
So there is no problem with that.
I found my error which was finally a 0 divide operation not properly managed in a specific case.
Thank you.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.