Skip to content
Snippets Groups Projects
Commit 2e15472b authored by dtc's avatar dtc
Browse files

Provide our own implementation of setfpucw for the Linux port, as

recent libraries are reported to no long provide __setfpucw.
parent 7e0a936e
No related branches found
No related tags found
No related merge requests found
......@@ -14,7 +14,7 @@
* Morfed from the FreeBSD file by Peter Van Eynde (July 1996)
* GENCGC support by Douglas Crosher, 1996, 1997.
*
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/Linux-os.c,v 1.4 1998/05/01 01:21:40 dtc Exp $
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/Linux-os.c,v 1.5 1999/02/02 10:58:24 dtc Exp $
*
*/
......@@ -97,7 +97,7 @@ os_init(void)
#else
os_vm_page_size=getpagesize();
#endif
__setfpucw(0x1372|4|8|16|32); /*no interrupts */
setfpucw(0x1372|4|8|16|32); /*no interrupts */
}
int
......
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/Linux-os.h,v 1.6 1998/06/16 06:58:58 dtc Exp $
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/Linux-os.h,v 1.7 1999/02/02 10:58:24 dtc Exp $
This code was written as part of the CMU Common Lisp project at
Carnegie Mellon University, and has been placed in the public domain.
......@@ -60,6 +60,8 @@ typedef struct sigcontext_struct sigcontext;
#define GET_CONTEXT int code=0; struct sigcontext_struct *context=&contextstruct;
#endif
#define setfpucw(cw) asm("fldcw %0" : : "m" (cw));
#define sigvec sigaction
#define sv_mask sa_mask
#define sv_flags sa_flags
......
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/interrupt.c,v 1.15 1998/05/01 01:21:42 dtc Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/interrupt.c,v 1.16 1999/02/02 10:58:25 dtc Exp $ */
/* Interrupt handing magic. */
......@@ -267,7 +267,7 @@ interrupt_handle_now(HANDLER_ARGS)
union interrupt_handler handler;
#ifdef __linux__
__setfpucw(contextstruct.fpstate->cw);
setfpucw(contextstruct.fpstate->cw);
#endif
handler = interrupt_handlers[signal];
......@@ -356,7 +356,7 @@ maybe_now_maybe_later(HANDLER_ARGS)
SAVE_CONTEXT(); /**/
#ifdef __linux__
__setfpucw(contextstruct.fpstate->cw);
setfpucw(contextstruct.fpstate->cw);
#endif
if (SymbolValue(INTERRUPTS_ENABLED) == NIL) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment