On Tue, 10 Mar 2009 23:52:36 +0100, "Vincent R." <foru...@smartmobili.com>
wrote:
> On Tue, 10 Mar 2009 20:44:27 +0100, "Vincent R."
<foru...@smartmobili.com>
> wrote:
>> Hi,
>> 
>> When trying to compile the following code with cegcc-4.4 I get undefined
>> reference to `__floatdidf' :
>> 
>> find__floatdidf.c:
>> ----
>> 
>> #include <windows.h>
>> 
>> LONGLONG _evil_time_freq;
>> LONGLONG _evil_time_count;
>> long     _evil_time_second;
>> 
>> double
>> evil_time_get()
>> {
>>   LARGE_INTEGER count;
>> 
>>   QueryPerformanceCounter(&count);
>> 
>>   return (double)_evil_time_second + (double)(count.QuadPart -
>>                           _evil_time_count)/
>>                           (double)_evil_time_freq;
>> }
>> 
>> int WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR
> lpCmdLine,
>> int nCmdShow)
>> {
>>   double dTime = evil_time_get();
>>   printf("ret : %d\n", dTime);
>> 
>>   return 0;
>> }
>> ---- 
>> 
>> $ arm-mingw32ce-g++ -v find__floatdidf.c
>> Using built-in specs.
>> Target: arm-mingw32ce
>> Configured with: /home/Vincent/cegcc/cegcc/src/gcc-trunk/configure
>> --with-gcc --with-gnu-ld --with-gnu-as --target=arm-mingw32ce
>> --prefix=/opt/mingw32ce-4.4.0 --enable-threads=win32 --disable-nls
>> --enable-languages=c,c++ --disable-win32-registry --disable-multilib
>> --disable-interwork --without-newlib --enable-checking --with-headers
>> Thread model: win32
>> gcc version 4.4.0 20090310 (experimental) (GCC)
>> COLLECT_GCC_OPTIONS='-v' '-shared-libgcc'
>>  /opt/mingw32ce-4.4.0/libexec/gcc/arm-mingw32ce/4.4.0/cc1plus.exe -quiet
> -v
>> find__floatdidf.c -quiet -dumpbase find__floatdidf.c -auxbase
>> find__floatdidf -version -o /c/DOCUME~1/Vincent/LOCALS~1/Temp/ccsOiRvb.s
>> 
>> ...
>> 
>> GNU C++ (GCC) version 4.4.0 20090310 (experimental) (arm-mingw32ce)
>>         compiled by GNU C version 3.4.4 (cygming special, gdc 0.12,
using
>> dmd 0.125), GMP version 4.2.4, MPFR version 2.4.1.
>> GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
>> Compiler executable checksum: 6f254b178188838682258d701691e447
>> COLLECT_GCC_OPTIONS='-v' '-shared-libgcc'
>> 
>>
>
/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/../../../../arm-mingw32ce/bin/as.exe
>> -v -o /c/DOCUME~1/Vincent/LOCALS~1/Temp/ccIrneqx.o
>> /c/DOCUME~1/Vincent/LOCALS~1/Temp/ccsOiRvb.s
>> GNU assembler version 2.19.51 (arm-mingw32ce) using BFD version (GNU
>> Binutils) 2.19.51.20090204
>>
>
COMPILER_PATH=/opt/mingw32ce-4.4.0/libexec/gcc/arm-mingw32ce/4.4.0/:/opt/mingw32ce-4.4.0/libexec/gcc/arm-mingw32ce/4.4.0/:/opt/mingw32ce-4.4.0/libexec/gcc/arm-mingw32ce/:/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/:/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/:/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/../../../../arm-mingw32ce/bin/
>>
>
LIBRARY_PATH=/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/:/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/../../../../arm-mingw32ce/lib/
>> COLLECT_GCC_OPTIONS='-v' '-shared-libgcc'
>>  /opt/mingw32ce-4.4.0/libexec/gcc/arm-mingw32ce/4.4.0/collect2.exe
>> -Bdynamic
>>
>
/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/../../../../arm-mingw32ce/lib/crt3.o
>> /opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/crtbegin.o
>> -L/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0
>>
>
-L/opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/../../../../arm-mingw32ce/lib
>> /c/DOCUME~1/Vincent/LOCALS~1/Temp/ccIrneqx.o -lstdc++ -lmingw32 -lgcc_s
>> -lgcc -lceoldname -lmingwex -lcoredll -lcoredll -lmingw32 -lgcc_s -lgcc
>> -lceoldname -lmingwex -lcoredll
>> /opt/mingw32ce-4.4.0/lib/gcc/arm-mingw32ce/4.4.0/crtend.o
>>
>
/c/DOCUME~1/Vincent/LOCALS~1/Temp/ccIrneqx.o:find__floatdidf.c:(.text+0x50):
>> undefined reference to `__floatdidf'
>>
>
/c/DOCUME~1/Vincent/LOCALS~1/Temp/ccIrneqx.o:find__floatdidf.c:(.text+0x6c):
>> undefined reference to `__floatdidf'
>> collect2: ld returned 1 exit status 
>> 
>> Any idea ?
>> Danny or Pedro can you reproduce it ?
> 
> When using nm with gcc-4.4:
> 
> $ arm-mingw32ce-nm libgcc.a | grep float
> _floatdidf.o:
> _floatdisf.o:
>          U __floatunsidf
>          U __floatunsidf
> _floatdixf.o:
> _floatditf.o:
> _floatundisf.o:
> 00000000 T __floatundisf
>          U __floatunsidf
> _floatundidf.o:
> 00000000 T __floatundidf
>          U __floatunsidf
> _floatundixf.o:
> _floatunditf.o:
> 0000000c T __floatsisf
> 0000000c T __floatunsisf
> 0000000c T __floatsidf
> 0000000c T __floatunsidf
> 
> with an old working version (4.1):
> 
> 0000038c T __floatdidf
> 00000310 T __floatsidf
> 00000378 T __floatundidf
> 000002ec T __floatunsidf
> 00000200 T __floatdisf
> 000001d0 T __floatsisf
> 000001f0 T __floatundisf
> 000001c8 T __floatunsisf
> _floatdidf.o:
> _floatdisf.o:
>          U __floatsidf
>          U __floatsidf
> _floatdixf.o:
> _floatditf.o:
> 00000000 T __floatsisf
> 00000000 T __floatunsisf
> 00000000 T __floatsidf
> 00000000 T __floatunsidf
> 
> So in my case floatxxx are not defined.
> 
> Pedro if you could comment.
> 
> Thanks

I found why it's because of the following tests :

#ifdef L_arm_addsubdf3
...
#endif

#ifdef L_arm_muldivdf3
...
#endif


in gcc/config/arm/t-wince-pe there is :

+# For most CPUs we have an assembly soft-float implementations.
+# However this is not true for ARMv6M.  Here we want to use the soft-fp C
+# implementation.  The soft-fp code is only build for ARMv6M.  This pulls
+# in the asm implementation for other CPUs.
+#LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_tls _bb_init_func
\
+#      _call_via_rX _interwork_call_via_rX \
+#      _lshrdi3 _ashrdi3 _ashldi3 \
+#      _arm_negdf2 _arm_addsubdf3 _arm_muldivdf3 _arm_cmpdf2 _arm_unorddf2 \
+#      _arm_fixdfsi _arm_fixunsdfsi \
+#      _arm_truncdfsf2 _arm_negsf2 _arm_addsubsf3 _arm_muldivsf3 \
+#      _arm_cmpsf2 _arm_unordsf2 _arm_fixsfsi _arm_fixunssfsi \
+#      _arm_floatdidf _arm_floatdisf _arm_floatundidf _arm_floatundisf \
+#      _clzsi2 _clzdi2


Are you sure you need to add all these functions ?
It seems this is the problem.





------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Cegcc-devel mailing list
Cegcc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cegcc-devel

Reply via email to