Subversion Repositories planix.SVN

Rev

Rev 87 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 87 Rev 101
Line 755... Line 755...
755
 * Note: the encodings for the FCLEX, FINIT, FSAVE, FSTCW, FSENV and FSTSW
755
 * Note: the encodings for the FCLEX, FINIT, FSAVE, FSTCW, FSENV and FSTSW
756
 * instructions do NOT have the WAIT prefix byte (i.e. they act like their
756
 * instructions do NOT have the WAIT prefix byte (i.e. they act like their
757
 * FNxxx variations) so WAIT instructions must be explicitly placed in the
757
 * FNxxx variations) so WAIT instructions must be explicitly placed in the
758
 * code as necessary.
758
 * code as necessary.
759
 */
759
 */
760
#define	FPOFF(l)						 ;\
760
#define	iOFPOFF(l)						 ;\
761
	MOVL	CR0, AX 					 ;\
761
	MOVL	CR0, AX 					 ;\
762
	ANDL	$0xC, AX			/* EM, TS */	 ;\
762
	ANDL	$0xC, AX			/* EM, TS */	 ;\
763
	CMPL	AX, $0x8					 ;\
763
	CMPL	AX, $0x8					 ;\
764
	JEQ 	l						 ;\
764
	JEQ 	l						 ;\
765
	WAIT							 ;\
765
	WAIT							 ;\
766
l:								 ;\
766
l:								 ;\
767
	MOVL	CR0, AX						 ;\
767
	MOVL	CR0, AX						 ;\
768
	ANDL	$~0x4, AX			/* EM=0 */	 ;\
768
	ANDL	$~0x4, AX			/* EM=0 */	 ;\
769
	ORL	$0x28, AX			/* NE=1, TS=1 */ ;\
769
	ORL	$0x28, AX			/* NE=1, TS=1 */ ;\
770
	MOVL	AX, CR0
770
	MOVL	AX, CR0
-
 
771
 
-
 
772
 
-
 
773
#define	FPOFF(l)						 ;\
-
 
774
        MOVL    CR0, AX                                          ;\
-
 
775
        ORL     $0x28, AX                       /* NE=1, TS=1 */ ;\
-
 
776
        MOVL    AX, CR0	;\
-
 
777
l:;\
-
 
778
 
771
 
779
 
772
#define	FPON							 ;\
780
#define	FPON							 ;\
773
	MOVL	CR0, AX						 ;\
781
	MOVL	CR0, AX						 ;\
774
	ANDL	$~0xC, AX			/* EM=0, TS=0 */ ;\
782
	ANDL	$~0xC, AX			/* EM=0, TS=0 */ ;\
775
	MOVL	AX, CR0
783
	MOVL	AX, CR0