开发者

Difference in benchmark with different ARM cross compilers using hardware FP and soft VFP

I am currently using Open virtual platform that simulates an ARM processor and I'm doing some benc开发者_如何学Chmarks on a simple task started by FreeRTOS with different cross compilers.

So I encountered something strange, when I use GCC toolchain, I have to use the flag -mhard-float when compiling the software because gcc's library is compiled using hardware FP. On my benchmark I get 10 million instructions.

However, when I switched to Codesourcerys ARM eabi toolchain, I have to use the flag -mfloat-abi=soft to compile the software because its library is not compiled with hard floats. On this benchmark I get 30 million instructions, THREE times as slow.

The software is very simple and does not test any floats, it just start a freeRTOS task and goes through a loop printing out numbers from 0 to 10000. Simple addition of integers.

Can anyone explain the difference in hard floats and soft floats and why the benchmarks differs so much between the compilers?

Best regards Mr Gigu

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜