From 65d3704e4bb4cd0230218d6475cbec7637e03507 Mon Sep 17 00:00:00 2001 From: vsc Date: Sun, 23 Dec 2007 22:48:44 +0000 Subject: [PATCH] recover stack space git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@2046 b08c6af1-5177-4d33-ba66-4b1c6b8b522a --- C/cdmgr.c | 8 ++++++-- C/dbase.c | 5 +++++ changes-5.1.html | 2 ++ pl/preds.yap | 3 ++- 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/C/cdmgr.c b/C/cdmgr.c index 83854f3a4..532ccac62 100644 --- a/C/cdmgr.c +++ b/C/cdmgr.c @@ -11,8 +11,12 @@ * File: cdmgr.c * * comments: Code manager * * * -* Last rev: $Date: 2007-12-18 17:46:58 $,$Author: vsc $ * +* Last rev: $Date: 2007-12-23 22:48:44 $,$Author: vsc $ * * $Log: not supported by cvs2svn $ +* Revision 1.215 2007/12/18 17:46:58 vsc +* purge_clauses does not need to do anything if there are no clauses +* fix gprof bugs. +* * Revision 1.214 2007/11/28 23:52:14 vsc * junction tree algorithm * @@ -1259,7 +1263,6 @@ kill_off_lu_block(LogUpdIndex *c, LogUpdIndex *parent, PredEntry *ap) static void kill_first_log_iblock(LogUpdIndex *c, LogUpdIndex *parent, PredEntry *ap) { - decrease_log_indices(c, (yamop *)&(ap->cs.p_code.ExpandCode)); /* parent is always locked, now I lock myself */ if (parent != NULL) { /* remove myself from parent */ @@ -1285,6 +1288,7 @@ kill_first_log_iblock(LogUpdIndex *c, LogUpdIndex *parent, PredEntry *ap) /* make sure that a child cannot remove us */ kill_children(c, ap); /* check if we are still the main index */ + decrease_log_indices(c, (yamop *)&(ap->cs.p_code.ExpandCode)); if (!((c->ClFlags & InUseMask) || c->ClRefCount)) { kill_off_lu_block(c, parent, ap); } else { diff --git a/C/dbase.c b/C/dbase.c index e86297c23..ef6dcd38c 100644 --- a/C/dbase.c +++ b/C/dbase.c @@ -3807,6 +3807,11 @@ p_total_erased(void) LogUpdClause *cl = DBErasedList; LogUpdIndex *icl = DBErasedIList; + int i=200000; + while (cl && i>0) + cl=cl->ClNext,i--; + if (cl) + fprintf(stderr,"cl=%p\n",cl); /* only for log upds */ while (cl) { cls++; diff --git a/changes-5.1.html b/changes-5.1.html index b225c6119..a1aeb4b45 100644 --- a/changes-5.1.html +++ b/changes-5.1.html @@ -17,6 +17,8 @@

Yap-5.1.3: