Linux-kernel mailing list archive 1998-31,: Re: floating-point abuse in 2.1.113

# Re: floating-point abuse in 2.1.113

Jakub Jelinek (jj@sunsite.ms.mff.cuni.cz)
Tue, 4 Aug 1998 13:21:26 +0200 (MET DST)

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: Thomas Molina: "compiling 2.1.113"
- Previous message: Jakub Jelinek: "Re: How to extend the task_struct?"

>
> On Tue, 4 Aug 1998, Mikael Pettersson wrote:
>
> > Right. Floating-point is banned within the Linux kernel, yet some
>
> Uh... Just a stupid question... Why floating-point is banned?

On most platforms (all but sparc64, I think), FPU regs are always owned by
application, ie. there is no save/restore around traps. So you clutter up
apps registers (the compiler of course does not generate any code to save
it/restore it when entering a function using FPU, as it is call clobbered).

If you want, take a look at my latest sparc64 FPU saving/restoring code to
see how complex is it to do it right and quickly. And even on sparc64, you
cannot use FPU in normal code, unless you before call some asm and
afterwards as well, so it is designed just for the high bandwidth VIS
operations, like memcpy/memset/IP csum/xor_block.

Cheers,
Jakub
___________________________________________________________________
Jakub Jelinek | jj@sunsite.mff.cuni.cz | http://sunsite.mff.cuni.cz
Administrator of SunSITE Czech Republic, MFF, Charles University
___________________________________________________________________
Ultralinux - first 64bit OS to take full power of the UltraSparc
Linux version 2.1.112 on a sparc64 machine (498.80 BogoMips).
___________________________________________________________________

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html

- Next message: Thomas Molina: "compiling 2.1.113"
- Previous message: Jakub Jelinek: "Re: How to extend the task_struct?"