support for tabling

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@951 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc
2003-12-18 16:38:40 +00:00
parent 0c2a3b4aff
commit 221665bab8
18 changed files with 285 additions and 69 deletions

View File

@@ -1140,9 +1140,12 @@ Yap_InitStacks(int Heap,
aux_delayed_release_load);
#else /* Yap */
Yap_InitMemory (Trail, Heap, Stack);
#endif /* YAPOR || TABLING */
AtomHashTableSize = MaxHash;
HashChain = (AtomHashEntry *)Yap_AllocAtomSpace(sizeof(AtomHashEntry) * MaxHash);
#endif /* YAPOR || TABLING */
if (HashChain == NULL) {
Yap_Error(FATAL_ERROR,MkIntTerm(0),"allocating initial atom table");
}
for (i = 0; i < MaxHash; ++i) {
INIT_RWLOCK(HashChain[i].AERWLock);
HashChain[i].Entry = NIL;