Linux MIPS Architecture development
 help / color / mirror / Atom feed
* floating point on Nevada cpu
@ 2001-01-25  2:28 Pete Popov
  2001-01-25  2:33 ` Justin Carlson
  2001-01-25 22:12 ` Ralf Baechle
  0 siblings, 2 replies; 21+ messages in thread
From: Pete Popov @ 2001-01-25  2:28 UTC (permalink / raw)
  To: linux-mips@oss.sgi.com


This simple test fails on a Nevada (5231) cpu:

int main()
{
    float x1,x2,x3;

    x1 = 7.5;
    x2 = 2.0;
    x3 = x1/x2;
    printf("x3 = %f\n", x3);
}

Has anyone else used floating point with 52xx processors?

Pete

^ permalink raw reply	[flat|nested] 21+ messages in thread
* Re: floating point on Nevada cpu
@ 2001-01-25 17:37 Ralf Baechle
  0 siblings, 0 replies; 21+ messages in thread
From: Ralf Baechle @ 2001-01-25 17:37 UTC (permalink / raw)
  To: Justin Carlson; +Cc: Pete Popov, linux-mips@oss.sgi.com

On Wed, Jan 24, 2001 at 06:57:04PM -0800, Justin Carlson wrote:

> How are you compiling the code?  And are you compiling it the same way on
> both platforms?  Do you have fpu emulation enabled on a kernel that doesn't
> need it? 

All MIPS FPUs need it; the architecture specification leaves it to the
implementor of a CPU which parts of the FP architecture are implemented
in hardware if at all; the missing parts have to be replaced in
software.

This piece of code shouldn't result in any FPU operations as printf is
very careful to avoid inaccuracies that might result from floating point
operations.

  Ralf

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2001-01-28  2:55 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-01-25  2:28 floating point on Nevada cpu Pete Popov
2001-01-25  2:33 ` Justin Carlson
2001-01-25  2:52   ` Pete Popov
2001-01-25  2:57     ` Justin Carlson
2001-01-25  2:57       ` Justin Carlson
2001-01-25  3:05   ` Pete Popov
2001-01-25  3:16     ` Justin Carlson
2001-01-25 14:54       ` Steve Johnson
2001-01-25 18:02         ` Pete Popov
2001-01-26 10:14           ` Kevin D. Kissell
2001-01-26 10:14             ` Kevin D. Kissell
2001-01-26 13:01             ` Steve Johnson
2001-01-26 13:57               ` Kevin D. Kissell
2001-01-26 13:57                 ` Kevin D. Kissell
2001-01-27 19:16             ` Ralf Baechle
2001-01-27 19:16               ` Ralf Baechle
2001-01-25 17:26       ` Ralf Baechle
2001-01-25 20:01         ` Justin Carlson
2001-01-25 22:12 ` Ralf Baechle
2001-01-26  7:53   ` Carsten Langgaard
  -- strict thread matches above, loose matches on Subject: below --
2001-01-25 17:37 Ralf Baechle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox