lkml.org 
[lkml]   [1998]   [May]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Intel floating-point initialization
Date
Followup to:  <19980519101452.11458@pauillac.inria.fr>
By author: Xavier Leroy <Xavier.Leroy@inria.fr>
In newsgroup: linux.dev.kernel
>
> I beg to disagree with Linus. The parent process/thread may have set
> the FPU control word to a non-default value (i.e. change rounding
> modes, etc). The programmer legitimely expects the child process to
> inherit those settings (just like it inherits pretty much everything
> else from its parent).
>

If the FPU registers are otherwise preserved across a system call,
they should be copied by fork(). Otherwise it will not work properly
if you use floating point in the same routine that does a fork()
(remember, to the C compiler, fork() is just another function.)

-hpa
--
PGP: 2047/2A960705 BA 03 D3 2C 14 A8 A8 BD 1E DF FE 69 EE 35 BD 74
See http://www.zytor.com/~hpa/ for web page and full PGP public key
I am Bahá'í -- ask me about it or see http://www.bahai.org/
"To love another person is to see the face of God." -- Les Misérables

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

\
 
 \ /
  Last update: 2005-03-22 13:42    [W:0.091 / U:0.568 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site