[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: floor() broken on EV4?



On Feb 11 2007, Falk Hueffner wrote:
> prescott@phys.ufl.edu writes:
> 
> > In tracking down issues with ganglia/rrdtool, I found that floor()
> > is not working properly in testing on my Avanti - it always seems to
> > return zero:
<snip>
> 
> The EV4 FPU cannot round to minus infinity, as glibc's floor wants to
> do, so the kernel emulates this. So it's almost certainly a kernel
> bug. Can you show the output of this program:
> 
> #include <stdio.h>
> 
> int main() {
>     union { double x; unsigned long i; } u;
>     asm ("cvttq/svm %1,%0" : "=f"(u.x) : "f"(1.1));
>     printf("%016lx\n", u.i);
> 
>     u.i = 1;
>     asm ("cvtqt/m %0,%0" : "=f"(u.x) : "f"(u.x));
>     printf("%e\n", u.x);
> 
>     return 0;
> }
> 
> ?

Sure:

cpp@imladris:~$ ./junk2
3ff199999999999a
4.940656e-324


> BTW, are you really still working with these machines? I was planning
> on suggesting to drop EV4 support for lenny, because I couldn't really
> imagine anybody still using them with a current Debian system...

I use several EV4-based machines at my home office 24x7; a couple of 
AS250s and a couple of AS200s for mostly administrative/management work;  
firewalls, DNS, DHCP, web/mail/ftp/NIS/torque server, etc.  I'm also them
to create and test Debian packages for torque and openmpi.  These 
machines, while old, are still perfectly adequate for these purposes 
in my environment.  I'd be sorry to see support for them dropped from 
Debian just yet.  If I could do things to help avoid that fate, I'd
be glad to give it a shot.

Cheers,
Craig

> -- 
> 	Falk




Reply to: