Re: rounding issue
Peter Keller <psilord <at> cs.wisc.edu>
2011-09-02 08:30:39 GMT
On Fri, Sep 02, 2011 at 09:59:31AM +0200, Slobodan Milnovi?? wrote:
> I'm just an sbcl user like you, and I have tried the same with the latest
> stable 1.0.51 (compiled from source on x86-64 debian)
I forgot to mention in the first email (and I apologize) that
I'm on an x86 ubuntu 10.04.3 LTS box (and those other tests were on a
32-bit box).
> CL-USER> (round (* 10.004939019999991d0 1e8))
> 1000493902
> -8.344650268554688d-7
>
> So, my guess is that whatever issue has been with the 1.0.46/47, sbcl
> developers seem to have solved it with 1.0.51. Perhaps you could test your
> code with that one and see if it works?
Sure, I'll give 1.0.51 a try.
Hrm. Nope. It still doesn't work.
Linux black > sbcl
This is SBCL 1.0.51, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.
SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses. See the CREDITS and COPYING files in the
distribution for more information.
* (round (* 10.004939019999991d0 1e8))
1000493901
0.9999991655349731d0
If I start it with --no-userinit, the round call still doesn't work.
Since it worked for you, this has the signature of a 32/64 bit problem.
My specific processor is this:
Linux black > cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 13
model name : Intel(R) Celeron(R) M processor 1.60GHz
stepping : 8
cpu MHz : 1596.238
cache size : 1024 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov clflush dts acpi mmx fxsr sse sse2 ss tm pbe nx
up bts
bogomips : 3192.47
clflush size : 64
cache_alignment : 64
address sizes : 32 bits physical, 32 bits virtual
power management:
Thank you for your help!
-pete
------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev