ViewVC logotype

Diff of /src/code/irrat.lisp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.24 by dtc, Sat Nov 1 22:58:14 1997 UTC revision 1.25 by dtc, Mon Dec 15 06:46:54 1997 UTC
# Line 376  Line 376 
376           (complex-sqrt number)           (complex-sqrt number)
377           (coerce (%sqrt (coerce number 'double-float)) 'single-float)))           (coerce (%sqrt (coerce number 'double-float)) 'single-float)))
378      (((foreach single-float double-float))      (((foreach single-float double-float))
379       ;; NOTE there is a problem with (at least x86 NPX) of what result       (if (< (float-sign number)
      ;; should be returned for (sqrt -0.0). The x86 hardware FSQRT  
      ;; instruction returns -0d0. The result is that Python will perhaps  
      ;; note the following test in generic sqrt, non-negatively constrained  
      ;; float types will be passed to FSQRT (or libm on other boxes).  
      ;; So, in the interest of consistency of compiled and interpreted  
      ;; codes, the following test is disabled for now. Maybe the float-sign  
      ;; test could be moved to the optimization codes.  
      (if (< (#+nil float-sign #-nil identity number)  
380              (coerce 0 '(dispatch-type number)))              (coerce 0 '(dispatch-type number)))
381           (complex-sqrt number)           (complex-sqrt number)
382           (coerce (%sqrt (coerce number 'double-float))           (coerce (%sqrt (coerce number 'double-float))

Removed from v.1.24  
changed lines
  Added in v.1.25

  ViewVC Help
Powered by ViewVC 1.1.5