[Openmcl-cvs-notifications] r14652 - in /trunk/source/lisp-kernel: x86-constants.s x86-spentry32.s

rme at clozure.com rme at clozure.com
Wed Feb 16 13:55:15 CST 2011


Author: rme
Date: Wed Feb 16 13:55:15 2011
New Revision: 14652

Log:
In SPffcall, don't use popfl to restore the state of DF.  Instead,
test the DF bit in the saved flags directly, and set DF with the std
instruction if needed.

This appears to resolve the issue described in ticket:819.  On the
other hand, I don't see how the TF bit is gettting set in the saved
flags, so this may simply be masking the symptoms of some underlying bug.

See ticket:819.

Modified:
    trunk/source/lisp-kernel/x86-constants.s
    trunk/source/lisp-kernel/x86-spentry32.s

Modified: trunk/source/lisp-kernel/x86-constants.s
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/source/lisp-kernel/x86-constants.s (original)
+++ trunk/source/lisp-kernel/x86-constants.s Wed Feb 16 13:55:15 2011
@@ -147,3 +147,6 @@
 TCR_FLAG_BIT_FOREIGN_EXCEPTION =3D (fixnumshift+6)
 TCR_FLAG_BIT_PENDING_SUSPEND =3D (fixnumshift+7)        =

 TCR_FLAG_BIT_FOREIGN_FPE =3D (fixnumshift+8)        =

+
+CF_BIT =3D 0
+DF_BIT =3D 10

Modified: trunk/source/lisp-kernel/x86-spentry32.s
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/source/lisp-kernel/x86-spentry32.s (original)
+++ trunk/source/lisp-kernel/x86-spentry32.s Wed Feb 16 13:55:15 2011
@@ -4225,8 +4225,11 @@
 	__(fnstsw rcontext(tcr.ffi_exception))
 	__(fnclex)
 	__endif
-1:	__(pushl rcontext(tcr.unboxed0))
-	__(popfl)
+1:	/* restore state of DF from saved flags */
+	__(bt $DF_BIT,rcontext(tcr.unboxed0))
+	__(jnc 2f)
+	__(std)
+2:	=

 	__(movl rcontext(tcr.save_vsp),%esp)
 	__(movl rcontext(tcr.save_ebp),%ebp)
 	__(movl $TCR_STATE_LISP,rcontext(tcr.valence))



More information about the Openmcl-cvs-notifications mailing list