Re: Intel floating-point initialization
H. Peter Anvin (hpa@transmeta.com)
Tue, 19 May 1998 04:15:12 -0700 (PDT)
> From: hpa@transmeta.com (H. Peter Anvin)
> Date: 19 May 1998 10:36:11 GMT
>
> 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.)
>
> Most ABI's I've seen say FPU regs are clobbered across a function
> call, or some subset of them are. And the same holds for system
> calls. The one case to be careful about, as Xavier has mentioned, is
> the FPU control register.
>
> Later,
> David S. Miller
> davem@dm.cobaltmicro.com
If so, it is perfectly OK to not initalize the FPU registers (as long
as it doesn't malfunction.) However, once again, if the FCR is
otherwise preserved across system calls, then it should be copied.
-hpa
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu