Skip to content
Snippets Groups Projects
Commit f101ba1a authored by toy's avatar toy
Browse files

o Oops. It's i386, not x86.

o Remove the code in fake_foreign_function_call that was moved to
  build_fake_control_stack_frame
parent 72f0aa1e
No related branches found
No related tags found
No related merge requests found
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/interrupt.c,v 1.28 2003/05/29 22:03:01 toy Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/interrupt.c,v 1.29 2003/05/30 01:07:20 toy Exp $ */
/* Interrupt handing magic. */
......@@ -121,43 +121,7 @@ fake_foreign_function_call(struct sigcontext *context)
current_binding_stack_pointer = (lispobj *)SC_REG(context, reg_BSP);
#endif
#if !defined(i386) && 0
/* Build a fake stack frame */
current_control_frame_pointer = (lispobj *)SC_REG(context, reg_CSP);
if ((lispobj *)SC_REG(context, reg_CFP)==current_control_frame_pointer) {
/* There is a small window during call where the callee's frame */
/* isn't built yet. */
if (LowtagOf(SC_REG(context, reg_CODE)) == type_FunctionPointer) {
/* We have called, but not built the new frame, so
build it for them. */
current_control_frame_pointer[0] = SC_REG(context, reg_OCFP);
current_control_frame_pointer[1] = SC_REG(context, reg_LRA);
current_control_frame_pointer += 8;
/* Build our frame on top of it. */
oldcont = (lispobj)SC_REG(context, reg_CFP);
}
else {
/* We haven't yet called, build our frame as if the
partial frame wasn't there. */
oldcont = (lispobj)SC_REG(context, reg_OCFP);
}
}
/* ### We can't tell if we are still in the caller if it had to
reg_ALLOCate the stack frame due to stack arguments. */
/* ### Can anything strange happen during return? */
else
/* Normal case. */
oldcont = (lispobj)SC_REG(context, reg_CFP);
current_control_stack_pointer = current_control_frame_pointer + 8;
current_control_frame_pointer[0] = oldcont;
current_control_frame_pointer[1] = NIL;
current_control_frame_pointer[2] = (lispobj)SC_REG(context, reg_CODE);
#else
build_fake_control_stack_frame(context);
#endif
/* Do dynamic binding of the active interrupt context index
and save the context in the context array. */
......@@ -565,7 +529,7 @@ interrupt_install_low_level_handler (int signal, void handler (HANDLER_ARGS))
/* But we only need this on x86 since the Lisp control stack and the
C control stack are the same. For others, they're separate so
the C stack can still be used. */
#if defined(RED_ZONE_HIT) && defined(x86)
#if defined(RED_ZONE_HIT) && defined(i386)
if (signal == PROTECTION_VIOLATION_SIGNAL)
{
stack_t sigstack;
......
/*
$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/os-common.c,v 1.10 2003/05/29 22:03:01 toy Exp $
$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/os-common.c,v 1.11 2003/05/30 01:07:20 toy 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.
......@@ -319,7 +319,7 @@ os_stack_grows_down (void)
static void
guard_zones (char **yellow_start, char **red_start)
{
#ifdef x86
#ifdef i386
if (os_stack_grows_down ())
{
char *end = (char *) CONTROL_STACK_START;
......
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