On Tue, 14 Dec 2004, Harvey J. Stein wrote:
> When I compile this snippet, preceeded by: > > (eval-when (compile) > (proclaim '(optimize (speed 3) (safety 1) (space 0) (debug 0)))) > > (defconstant SQRT2OVERE (the double-float (sqrt (/ 2d0 (exp 1d0))))) > > (eval-when (compile) > (proclaim '(type double-float SQRT2OVERE))) > > I get a compilation note: > Note: Doing float to pointer coercion (cost 13) to "<return value>". > > I don't know if this is faster or not, but it doesn't clear up the > cost 13 coercion to pointer note. Sure! But when you now inline (which you can do as it is no longer calling itself), consing of the intermediary floatingpoint number can be omitted. > And, using inlining & block compilation doesn't help much either. Well, I'd say it does for this version, only (1) you have to improve the other parts that slow down your code first. (2) there have to be enough float registers available. -- regards, [EMAIL PROTECTED] (o_ Thomas Fischbacher - http://www.cip.physik.uni-muenchen.de/~tf //\ (lambda (n) ((lambda (p q r) (p p q r)) (lambda (g x y) V_/_ (if (= x 0) y (g g (- x 1) (* x y)))) n 1)) (Debian GNU)
