Not applicable
Jul 22, 2015
08:28 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jul 22, 2015
08:28 PM
Hi all,
I would like to take advantage of hardware floating point unit in XMC4500. However, selecting 'Full hardware floating point (-mfloat-abi=hard) option under Miscellaneous section of compiler options in DAVE4 throws bunch of linker errors.
Please help.
Sam
I would like to take advantage of hardware floating point unit in XMC4500. However, selecting 'Full hardware floating point (-mfloat-abi=hard) option under Miscellaneous section of compiler options in DAVE4 throws bunch of linker errors.
Please help.
Sam
- Tags:
- IFX
4 Replies
Not applicable
Jul 23, 2015
01:15 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jul 23, 2015
01:15 AM
Hi Sam,
With referring to "DAVE TIP of the day: Things need to do when use math functions", you may try to "add '__FPU_PRESENT'" in Compiler Preprocessor configuration (Go to Project -> Active Project Properties -> C/C++ Build -> Settings -> ARM-GCC C Compiler, add "__FPU_PRESENT" in the Preprocessor).
BR,
Zain
With referring to "DAVE TIP of the day: Things need to do when use math functions", you may try to "add '__FPU_PRESENT'" in Compiler Preprocessor configuration (Go to Project -> Active Project Properties -> C/C++ Build -> Settings -> ARM-GCC C Compiler, add "__FPU_PRESENT" in the Preprocessor).
BR,
Zain
Not applicable
Jul 26, 2015
03:41 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jul 26, 2015
03:41 PM
Thanks Zain. Adding __FPU_PRESENT to compiler settings does not work as the problem is related to linker. The errors go something like this:
"Trial.elf uses VFP register arguments, c:/davev4/dave-4.0.0/eclipse/arm-gcc-49/bin/../lib/gcc/arm-none-eabi/4.9.3/../../../../arm-none-eabi/lib/armv7e-m\libg_nano.a(lib_a-nano-msizer.o) does not"
It seems that libg_nano and lib_gcc being linked have not been compiled with FPU flag turned on and by default linker does not know where to look for appropriate files. After posting the question I found out that adding following library search paths on linker tab takes care of the problem.
"C:\DAVEv4\DAVE-4.0.0\eclipse\ARM-GCC-49\lib\gcc\arm-none-eabi\4.9.3\armv7e-m\fpu"
"C:\DAVEv4\DAVE-4.0.0\eclipse\ARM-GCC-49\arm-none-eabi\lib\armv7e-m\fpu"
However, it is tedious to do that in every project so I am still looking for a better solution.
Sam
"Trial.elf uses VFP register arguments, c:/davev4/dave-4.0.0/eclipse/arm-gcc-49/bin/../lib/gcc/arm-none-eabi/4.9.3/../../../../arm-none-eabi/lib/armv7e-m\libg_nano.a(lib_a-nano-msizer.o) does not"
It seems that libg_nano and lib_gcc being linked have not been compiled with FPU flag turned on and by default linker does not know where to look for appropriate files. After posting the question I found out that adding following library search paths on linker tab takes care of the problem.
"C:\DAVEv4\DAVE-4.0.0\eclipse\ARM-GCC-49\lib\gcc\arm-none-eabi\4.9.3\armv7e-m\fpu"
"C:\DAVEv4\DAVE-4.0.0\eclipse\ARM-GCC-49\arm-none-eabi\lib\armv7e-m\fpu"
However, it is tedious to do that in every project so I am still looking for a better solution.
Sam
Jul 26, 2015
09:57 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jul 26, 2015
09:57 PM
Hi,
When you change the 'Full hardware floating point (-mfloat-abi=hard) option under Miscellaneous section of compiler, a similar option is to be selected in Linker-->Miscellaneous --> Floating Point.
This feature is added in Dave4.1.2 version.
When you change the 'Full hardware floating point (-mfloat-abi=hard) option under Miscellaneous section of compiler, a similar option is to be selected in Linker-->Miscellaneous --> Floating Point.
This feature is added in Dave4.1.2 version.
Not applicable
Jul 27, 2015
12:19 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jul 27, 2015
12:19 PM
That's it, upgrading to 4.1.2 took care of the problem. Thanks.
Sam
Sam