[Top] [All Lists]

Re: config option vs. run-time detection (the debate continues ...)

To: Jun Sun <>
Subject: Re: config option vs. run-time detection (the debate continues ...)
From: "Maciej W. Rozycki" <>
Date: Tue, 13 Feb 2001 19:31:11 +0100 (MET)
Cc: "Kevin D. Kissell" <>,
In-reply-to: <>
Organization: Technical University of Gdansk
On Mon, 12 Feb 2001, Jun Sun wrote:

> >  I don't have an FPU-less system and I can't check such code.  I need to
> > depend on others (I couldn't test all possible configurations anyway).
> However, with CONFIG_HAS_FPU approach I know for sure it will work for any
> MIPS CPU, as long as the programmer specifies it correctly. :-)

 Tha latter being a BIG if.

> > If
> > we have a chance to get an exception we have to catch it, of course
> > (that's trivial to handle in Linux).
> > 
> No effort (as in CONFIG_HAS_FPU approach) is still better than trivial or
> small effort ( as in run-time detection).  :-)

 Regardless of the CONFIG_HAS_FPU option you still need to check if a FPU
is present.

> I am very curious what makes you object to the CONFIG_HAS_FPU approach,
> especially you said earlier it was not about the inability to support both FPU
> and FPU-less CPUs with the same kernel image.

 That's pretty orthogonal -- I do not object the CONFIG_HAS_FPU option (I
even favor it, if it could save us unneeded bits), but whether having it
or not, we still have to properly detect FP hardware.  A silent crash or
an obscure oops is not an option in case of a config error.

+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+        e-mail:, PGP key available        +

<Prev in Thread] Current Thread [Next in Thread>