[ixp1200] Doubt reg. Floating Point Operations support in IXP 1200

romit dasgupta romit at myrealbox.com
Tue Mar 9 04:04:25 EST 2004


Hello David,
                    Thanks for your mail. Once I did a division 
operation in the kernel and I got an error given by the assembler. I 
enabled CONFIG_FPE_FASTFPE and the error vanished. You are right we are 
not supposed to do FP operations in Kernel but my understanding is that, 
if we do really need FP operations in kernel we have to explicitly save 
the FP context. Correct me if I am wrong.  
By the way, if we dont enable CONFIG_FPE_FASTFPE, cant we still use libm 
from userspace?

Regards,
-Romit

David Mentre wrote:

>Hello,
>
>  
>
>>From: romit dasgupta [mailto:romit at myrealbox.com]
>>Sent: Tuesday, March 09, 2004 6:30 AM
>>    
>>
>
>[ about doing floating point computations on IXP1200 core ]
>
>  
>
>>If you are talking about userland, then libm is your friend. 
>>If you are 
>>talking about kernel space
>>then you may compile your kernel with CONFIG_FPE_NWFPE  or 
>>CONFIG_FPE_FASTFPE.
>>    
>>
>
>Romit, I think you have been confused by the fact the CONFIG_FPE_NWFPE and
>CONFIG_FPE_FASTFPE are kernel options. In fact, once enabled, they provide
>floating point emulation for *user* application.
>
>BTW, if you want fast floating point computations, it appears that there is
>a patch floating around (no pun intended) for gcc that implements floating
>point emulation at the compilation toolchain level. According to linux-arm
>developers, it is much faster than kernel level emulation. However, this
>patch requires to recompile all the libraries, including the glibc.
>
>On 2004-03-08, in an email entitled "SoftFloat Benchmarks" on arm-linux
>mailing list, Eric BENARD / Free [ebenard at free.fr] has posted a comparison
>of the different solutions:
>--- email included ---
>I've run some benchs in order to compare FP solutions on an IXP425 (rev0) 
>running at 533 MHz with Linux 2.4.21-rmk1-ds3 (with NWFPE patches from the 
>arm-kernel ML).
>
>Test softwares are : nbench v2 and flops 2.0 
>Test compilers are : 
>	- gcc 3.3.3 + glibc 2.3.2 => using kernel emulation NWFPE or FFPE
>	- gcc 3.3.3 + Nico's patches + glibc 2.3.2
>Compiler options are :
>	-O3 -fomit-frame-pointer -mcpu=xscale -mtune=xscale -mbig-endian
>-static  
>
>Results :
>*** nbench, Floating Point Index (vs P90 / vs K6/233) :
>	NWFPE : 0.028 / 0.015 
>	FFPE : 0.062 / 0.031 = NWFPE * 2.2
>	NICO : 0.260 / 0.144 = NWFPE * 9.3
>
>*** flops, mean of the 4 MFLOPS values returned by the test :
>	NWFPE : 0.52
>	FFPE : 1.89 = NWFPE * 3.63
>	NICO : 3.91 = NWFPE * 7.52
>--- end of email included ---
>
>
>
>If you want fast floating point anyway, you'd better do fix point
>computations on integers.
>
>It is not allowed by linux kernel developpers to do floating point
>computations in the kernel.
>
>
>Sharmila, if you want more information on floating point and arm, look at
>arm-linux mailing list archive. This has been discussed numerous times.
>
>
>Yours,
>david
>  
>




More information about the ixp1200 mailing list