Floating Point errors using powerpc-eabivle-4_9 compilers on MPC5777 e200z7 core

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Floating Point errors using powerpc-eabivle-4_9 compilers on MPC5777 e200z7 core

545 次查看
sreekant866
Contributor I

Hello Team,

I am using use the compiler -powerpc-eabivle-gcc-4.9.4 located in "\nxp\S32DS_Power_v2.1\S32DS\build_tools\powerpc-eabivle-4_9\bin". We are getting following errors while we are compiling our code:
1. undefined reference to `__extendsfdf2'
2. undefined reference to `__extendsfdf2'
3. undefined reference to `__floatunsidf'
4. undefined reference to `__umoddi3'
5. undefined reference to `__gtdf2'
6. undefined reference to `__udivdi3'

I am using  MPC5777 e200z7 core. Am I missing any compiler flags to address this issue or are we missing anything in the compiler to add the above mentioned floating point functions?. Please help

Below are the compilation flags used:

Arch Flags:

TGT_FLAGS = -mno-eabi -mspe -mabi=spe -memb -meabi -mlra -mcpu=e200z7 -mbig -mno-vle -Wa,-mbooke32 -mregnames -Wa,-mregnames -mhard-float

COMMON_FLAGS = $(TGT_FLAGS) -fno-common
C Flags:

CFLAGS = $(COMMON_FLAGS) -DUINT_SIZE=32 -c $(C_OPTIMIZATION) -fweb -ffunction-sections -frename-registers -funswitch-loops -fgcse-after-reload \
-g3 $(ASSERTFLAGS) $(CEXTFLAGS) -nostdinc -fno-builtin -std=gnu99 -Wimplicit -Wall -Wstrict-prototypes \
-Wparentheses -Wmissing-braces -Wsequence-point -Wfloat-equal -Wmissing-prototypes -Wmissing-declarations \
-Wold-style-definition -Wimplicit-function-declaration -Wno-long-long -Wunreachable-code -fsingle-precision-constant \

CPP Flags:


CPPFLAGS = $(COMMON_FLAGS) -DUINT_SIZE=32 -c $(CPP_OPTIMIZATION) -fweb -ffunction-sections -frename-registers -funswitch-loops -fgcse-after-reload \
-g3 $(ASSERTFLAGS) $(CPPEXTFLAGS) -fno-default-inline --param max-inline-insns-auto=0 -fno-inline-functions \
-fno-rtti -fno-exceptions -fno-enforce-eh-specs -fno-builtin -fno-threadsafe-statics -fno-gnu-keywords \
-fno-nonansi-builtins -fno-operator-names -nostdinc++ -Wabi -Wreorder -Woverloaded-virtual -Wsign-promo -Winit-self \
-Wswitch-enum -Wextra -Wfloat-equal -Wunreachable-code -fsingle-precision-constant 

Regards,

Sreekant Kollur

0 项奖励
1 回复

517 次查看
jiri_kral
NXP Employee
NXP Employee

Hi, 

you may find helpful this StackOverflow article:
https://stackoverflow.com/questions/53402307/powerpc-gcc-floating-point-instructions

Also make sure, that HW float point is enabled in your project properties: 

jiri_kral_0-1657719074294.png

 

Jiri

 

0 项奖励