Changeset 726


Ignore:
Timestamp:
Mar 25, 2004, 5:13:46 PM (21 years ago)
Author:
Gary Byers
Message:

%SET-FPSCR-CONTROL: maintain stack discipline. Write zeroes to status
fields as well, to avoid enabling a signaled exception.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ccl/level-0/PPC/ppc-float.lisp

    r508 r726  
    546546  (blr))
    547547
    548 ; Set the low 8 bits of the FPSCR; leave the high 24 unchanged
     548; Set the low 8 bits of the FPSCR.  Zero the upper 24 bits
    549549(defppclapfunction %set-fpscr-control ((new arg_z))
    550550  (unbox-fixnum imm0 new)
    551   (stwu tsp -16 tsp)
    552   (stw tsp 4 tsp)
     551  (clrlwi imm0 imm0 24)                 ; ensure that "status" fields are clear
    553552  (stw imm0 target::tcr.lisp-fpscr-low rcontext)
    554553  (lfd fp0 target::tcr.lisp-fpscr-high rcontext)
    555   (mtfsf #x03 fp0)                      ; set control fields [6-7]
     554  (mtfsf #xff fp0)                      ; set all fields [0-7]
    556555  (blr))
    557556
Note: See TracChangeset for help on using the changeset viewer.