public
/
ack.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b1be3e3
)
ply adaption was wrong for EM replacements
author
ceriel
<none@none>
Thu, 17 Dec 1992 12:52:21 +0000
(12:52 +0000)
committer
ceriel
<none@none>
Thu, 17 Dec 1992 12:52:21 +0000
(12:52 +0000)
mach/proto/cg/codegen.c
patch
|
blob
|
history
mach/proto/ncg/codegen.c
patch
|
blob
|
history
diff --git
a/mach/proto/cg/codegen.c
b/mach/proto/cg/codegen.c
index
b56fc7c
..
e763e08
100644
(file)
--- a/
mach/proto/cg/codegen.c
+++ b/
mach/proto/cg/codegen.c
@@
-656,8
+656,10
@@
if (Debug > 1) fprintf(stderr, "cost after coercions: %u\n", t);
break;
}
}
- if (!toplevel)
- ply += emrepllen;
+ if (!toplevel) {
+ if (ply >= j) ply += emrepllen - j;
+ else ply = emrepllen;
+ }
break;
case DO_COST:
DEBUG("COST");
diff --git
a/mach/proto/ncg/codegen.c
b/mach/proto/ncg/codegen.c
index
61abf04
..
d73fc04
100644
(file)
--- a/
mach/proto/ncg/codegen.c
+++ b/
mach/proto/ncg/codegen.c
@@
-852,8
+852,14
@@
normalfailed: if (stackpad!=tokpatlen) {
break;
}
}
- if (!toplevel)
- ply += emrepllen;
+ if (!toplevel) {
+ if (ply >= j) ply = emrepllen + ply - j;
+ else ply = emrepllen;
+#ifndef NDEBUG
+ if (Debug > 4)
+ fprintf(stderr, "ply becomes %d\n", ply);
+#endif
+ }
break;
}
case DO_COST: {