LPC55S69 FPU multiplication error (Hard floats)

cancel
Showing results for 
Search instead for 
Did you mean: 

LPC55S69 FPU multiplication error (Hard floats)

Jump to solution
190 Views
v_canoz
Contributor III

Hello,

I have a very surprising problem with LPC55S69. The hard ABI is enabled.

 

float a = 255.0;
float b = 1.0;
float res = a * b;

 

With this simple test case I get different results each time the function is called : 

 

res = 0.407566
res = 0.489081
res = 0.505314

...

 

 What can cause this?

Labels (1)
0 Kudos
1 Solution
174 Views
v_canoz
Contributor III

Hi,

Further testing showed that it's due to a stack corruption. Don't know why yet, but now I'm confident it is not related to the FPU.
Sorry for disturbing!

View solution in original post

0 Kudos
2 Replies
175 Views
v_canoz
Contributor III

Hi,

Further testing showed that it's due to a stack corruption. Don't know why yet, but now I'm confident it is not related to the FPU.
Sorry for disturbing!

View solution in original post

0 Kudos
180 Views
converse
Senior Contributor IV

Can you post the whole project that reproduces this?

0 Kudos