[Top] [All Lists]

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

To: "Maciej W. Rozycki" <>, "Jun Sun" <>
Subject: Re: config option vs. run-time detection (the debate continues ...)
From: "Kevin D. Kissell" <>
Date: Fri, 9 Feb 2001 23:12:00 +0100
Cc: <>
References: <>
> > Another question.  I know with mips32 and mips64 we can do run-time
> > reliably.  What about other existing processors?
>  I've sent a quote from an IDT manual recently.  It recommended to use the
> FPU implementation ID to check if an FP hw is present.  I believe it
> should work for any sane implementation of a MIPS CPU.  See the mail for
> details.

The best method I know for post-R3000 CPUs is to
write and read back the CU1 bit of the Status register.
CPUs without an integrated FPU will not have a flip-flop
for the bit, and will read back a 0 even after writing a 1.
There was never any architectural requirement that
this be so, however, and this cannot be absolutely
guaranteed to work.  If anyone has a counter-example,
however, I'd be interested in hearing about it.

            Kevin K.

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