[racket] Untyped arithmetics performance

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sat Jan 24 13:00:06 EST 2015

At Sat, 24 Jan 2015 18:14:39 +0100, Daniel Kvasnička wrote:
> What about the segmentation fault? Am I doing something wrong?

You're missing an conversion from fixnum to flonum in the second
argument to `unsafe-fl/`:

> (time (exact->inexact (for/sum ([x (in-range 10000)]) (unsafe-fl/ (->fl x) 
> (unsafe-fx- 10000 x)))))



Posted on the users mailing list.