I am observing some behavior for which I am finding it tough to reason.
I have a piece of code as follows:
int timer_temp_var;
if ((timer_temp_var/1000.0) > 5.0)
{
//Do something
}
This piece leads to link error.
>
> dld: warning: Undefined symbol _d_fle"
> dld: no output written make[1]: ***
> [app.elf] Error 1
But on replacing the equality check as :
if ((timer_temp_var/1000.0) < 5.0) // replace '>' with '<'.
I see no issues.
Also instead of doing division by 1000.0 if I do by 1000 as follows:
if ((timer_temp_var/1000) > 5)
{
//Do something
}
I see no issues irrespective of the kind of equality check.
The application is compiled to run on a pSOS operating system.
What is the reason for such a behavior?