mirror of
https://github.com/Interlisp/maiko.git
synced 2026-03-02 17:54:38 +00:00
WIP still, trying for a fix
This commit is contained in:
@@ -17,7 +17,7 @@ XFILES = $(OBJECTDIR)xmkicon.o \
|
||||
XFLAGS = -DXWINDOW
|
||||
|
||||
# OPTFLAGS is normally -O2.
|
||||
OPTFLAGS = -O2 -g3
|
||||
OPTFLAGS = -O0 -g3
|
||||
DFLAGS = $(XFLAGS) -DRELEASE=351
|
||||
|
||||
LDFLAGS = -L/usr/X11/lib -lX11 -lc -lm
|
||||
|
||||
@@ -78,7 +78,7 @@ typedef struct fnhead {
|
||||
typedef struct frameex1 {
|
||||
unsigned flags : 3;
|
||||
unsigned fast : 1;
|
||||
unsigned nil2 : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned mvscase : 1; /* was not used, prev: This frame treats N-func */
|
||||
unsigned incall : 1;
|
||||
unsigned validnametable : 1;
|
||||
/* 0: look for FunctionHeader
|
||||
@@ -109,7 +109,7 @@ typedef struct frameex1 {
|
||||
typedef struct frameex2 {
|
||||
unsigned flags : 3;
|
||||
unsigned fast : 1;
|
||||
unsigned nil2 : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned mvscase : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned incall : 1;
|
||||
unsigned validnametable : 1;
|
||||
/* 0: look for FunctionHeader
|
||||
@@ -200,7 +200,7 @@ typedef struct frameex1 {
|
||||
/* 0: look for FunctionHeader
|
||||
1: look for NameTable on this FrameEx */
|
||||
unsigned incall : 1;
|
||||
unsigned nil2 : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned mvscase : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned fast : 1;
|
||||
unsigned flags : 3; /* hi word */
|
||||
|
||||
@@ -235,7 +235,7 @@ typedef struct frameex2 {
|
||||
/* 0: look for FunctionHeader
|
||||
1: look for NameTable on this FrameEx */
|
||||
unsigned incall : 1;
|
||||
unsigned nil2 : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned mvscase : 1; /* not used, prev: This frame treats N-func */
|
||||
unsigned fast : 1;
|
||||
unsigned flags : 3;
|
||||
|
||||
|
||||
@@ -211,8 +211,13 @@ retry: /* this is retry entry after MAKE_FXCOPY etc */
|
||||
} else {
|
||||
if (CURRENTFX->nopush) {
|
||||
CURRENTFX->nopush = NIL;
|
||||
CurrentStackPTR = next68k - 2;
|
||||
TopOfStack = *((LispPTR *)CurrentStackPTR);
|
||||
if (CURRENTFX->mvscase) {
|
||||
CurrentStackPTR = next68k;
|
||||
CURRENTFX->mvscase = NIL;
|
||||
} else {
|
||||
CurrentStackPTR = next68k - 2;
|
||||
TopOfStack = *((LispPTR *)CurrentStackPTR);
|
||||
}
|
||||
CurrentStackPTR -= 2;
|
||||
|
||||
} else
|
||||
|
||||
13
src/mvs.c
13
src/mvs.c
@@ -100,9 +100,14 @@ newpc:
|
||||
/* BUT 3's not enough for big atoms, so add diff between FN op size & MISCN op size */
|
||||
if (caller == immediate_caller) PC = pc + (FN_OPCODE_SIZE - 3);
|
||||
#endif /* BIGATOMS */
|
||||
|
||||
else
|
||||
else {
|
||||
caller->pc = (UNSIGNED)pc + FN_OPCODE_SIZE - (UNSIGNED)fnhead;
|
||||
/* skip over FN opcode when we get there */
|
||||
prevcaller->fast = 0;
|
||||
caller->mvscase = 1;
|
||||
caller->nopush = 1;
|
||||
}
|
||||
|
||||
return (make_value_list(arg_count, args));
|
||||
}
|
||||
break;
|
||||
@@ -287,8 +292,8 @@ void simulate_unbind(FX2 *frame, int unbind_count, FX2 *returner) {
|
||||
ppvar = (LispPTR *)((DLword *)frame + FRAMESIZE + 2 + GetLoWord(value));
|
||||
for (i = num; --i >= 0;) { *--ppvar = 0xffffffff; }
|
||||
}
|
||||
if (returner)
|
||||
returner->fast = 0; /* since we've destroyed contiguity */
|
||||
/* if (returner)
|
||||
returner->fast = 0; since we've destroyed contiguity */
|
||||
/* in the stack, but that only
|
||||
matters if there's a return. */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user