change Heap.h to YapHeap.h

rename $live to prolog/0 (for SWI compatibility).
This commit is contained in:
Vitor Santos Costa 2009-10-23 14:22:17 +01:00
parent 253444d7ca
commit 0179998d60
56 changed files with 67 additions and 63 deletions

View File

@ -21,7 +21,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "alloc.h"
#include "yapio.h"
#if HAVE_STRING_H

View File

@ -25,7 +25,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"

View File

@ -25,7 +25,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
static Term

View File

@ -25,7 +25,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#include "arith2.h"

View File

@ -21,7 +21,7 @@ static char SccsId[]="%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "heapgc.h"
#include "attvar.h"
#ifndef NULL

View File

@ -23,7 +23,7 @@ static char SccsId[] = "%W% %G%";
#ifdef USE_GMP
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#include "alloc.h"
#if HAVE_STRING_H

View File

@ -5543,7 +5543,7 @@ p_choicepoint_info(void)
break;
case _Nstop:
{
Atom at = AtomLive;
Atom at = AtomProlog;
t = MkAtomTerm(at);
pe = RepPredProp(PredPropByAtom(at, CurrentModule));
}

View File

@ -20,7 +20,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#if HAVE_STRING_H
#include <string.h>

View File

@ -59,7 +59,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "compile.h"
#include "yapio.h"
#if HAVE_STRING_H

View File

@ -20,7 +20,7 @@ static char SccsId[]="%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "heapgc.h"
#include "attvar.h"
#ifndef NULL

View File

@ -2,7 +2,7 @@
#if USE_DL_MALLOC
#include "Heap.h"
#include "YapHeap.h"
#if HAVE_STRING_H
#include <string.h>
#endif

View File

@ -24,7 +24,7 @@ static char SccsId[] = "%W% %G%";
*/
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#if HAVE_STDARG_H
#include <stdarg.h>

View File

@ -20,7 +20,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "iopreds.h"
#include "attvar.h"

View File

@ -17,7 +17,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#if USE_GMP

View File

@ -16,7 +16,7 @@
*************************************************************************/
#include "absmi.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "alloc.h"
#include "sshift.h"

View File

@ -26,7 +26,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include <stdlib.h>
#if HAVE_STDARG_H

View File

@ -15,7 +15,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "Foreign.h"
#ifdef COFF

View File

@ -15,7 +15,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "Foreign.h"

View File

@ -15,7 +15,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "Foreign.h"

View File

@ -15,7 +15,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "Foreign.h"

View File

@ -19,7 +19,7 @@ static char SccsId[] = "%W% %G%.2";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include <stdlib.h>
#if HAVE_STRING_H

View File

@ -15,7 +15,7 @@
#include "Yap.h"
#include "Foreign.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#ifdef HAVE_STRING_H
#include <string.h>
#endif

View File

@ -1,7 +1,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "Foreign.h"

View File

@ -20,7 +20,7 @@
#ifdef MULTI_ASSIGNMENT_VARIABLES
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
STD_PROTO(static Int p_setarg, (void));

View File

@ -20,7 +20,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
STATIC_PROTO(Int p_current_module, (void));
STATIC_PROTO(Int p_current_module1, (void));

View File

@ -21,7 +21,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#if HAVE_STRING_H
#include <string.h>
#endif

View File

@ -48,7 +48,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#if HAVE_STRING_H
#include <string.h>

View File

@ -20,7 +20,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "iopreds.h"

View File

@ -34,7 +34,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "alloc.h"
#include "eval.h"

View File

@ -19,7 +19,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#ifndef NULL
#define NULL (void *)0
#endif

View File

@ -270,7 +270,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#include "yapio.h"
#include <stdio.h>

View File

@ -20,7 +20,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "eval.h"
#include "yapio.h"
#include <stdio.h>

View File

@ -20,7 +20,7 @@
#ifdef LOW_LEVEL_TRACER
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "attvar.h"
#include "yapio.h"
#include "tracer.h"

View File

@ -40,7 +40,7 @@ static char SccsId[] = "%W% %G%";
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#if EUROTRA
#include "yapio.h"
#if HAVE_UNISTD_H

View File

@ -20,7 +20,7 @@ static char SccsId[] = "@(#)utilpreds.c 1.3";
#include "Yap.h"
#include "clause.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "eval.h"
#include "attvar.h"

View File

@ -21,7 +21,7 @@ static char SccsId[] = "%W% %G%";
#include <stdlib.h>
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#if COROUTINING
#include "attvar.h"

View File

@ -19,7 +19,7 @@
#include "Yap.h"
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#if USE_SOCKET

View File

@ -7,7 +7,7 @@
* *
**************************************************************************
* *
* File: Heap.h *
* File: YapHeap.h *
* mods: *
* comments: Heap Init Structure *
* version: $Id: Heap.h,v 1.136 2008-08-08 14:05:34 vsc Exp $ *

View File

@ -1383,7 +1383,7 @@ typedef enum
TERMS_MODULE = 5
} default_modules;
#include "Heap.h"
#include "YapHeap.h"
EXTERN inline UInt STD_PROTO(PRED_HASH, (FunctorEntry *, Term, UInt));

View File

@ -148,7 +148,7 @@ register struct yami* P1REG asm ("bp"); /* can't use yamop before Yap.h */
#include "or.macros.h"
#endif /* YAPOR */
#ifdef USE_SYSTEM_MALLOC
#include "Heap.h"
#include "YapHeap.h"
#endif
#ifdef TABLING
#include "tab.macros.h"

View File

@ -16,7 +16,7 @@
*************************************************************************/
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
/* consulting files */

View File

@ -118,7 +118,7 @@ HEADERS = \
$(srcdir)/H/Tags_32LowTag.h $(srcdir)/H/Tags_64bits.h \
$(srcdir)/H/Tags_24bits.h $(srcdir)/H/sshift.h \
$(srcdir)/H/Yap.h $(srcdir)/H/Yatom.h \
$(srcdir)/H/Heap.h \
$(srcdir)/H/YapHeap.h \
$(srcdir)/H/Regs.h $(srcdir)/H/Yapproto.h \
$(srcdir)/H/absmi.h $(srcdir)/H/alloc.h \
$(srcdir)/H/amidefs.h $(srcdir)/H/amiops.h $(srcdir)/H/arrays.h \

View File

@ -17,7 +17,7 @@
#if defined(YAPOR) || defined(TABLING)
#define OPT_MAVAR_STATIC
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include <unistd.h>
#include <signal.h>
#ifdef YAPOR

View File

@ -25,7 +25,7 @@
#include <sys/shm.h>
#include <sys/mman.h>
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "alloc.h"
#include "heapgc.h"

View File

@ -20,7 +20,7 @@
#include <string.h>
#endif /* HAVE_STRING_H */
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#ifdef YAPOR
#if HAVE_SYS_TIME_H

View File

@ -25,7 +25,7 @@
#include <unistd.h>
#include <stdio.h>
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "or.macros.h"

View File

@ -16,7 +16,7 @@
#include "Yap.h"
#ifdef YAPOR
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "or.macros.h"
#ifdef TABLING
#include "tab.macros.h"

View File

@ -19,7 +19,7 @@
#include <string.h>
#endif /* HAVE_STRING_H */
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "or.macros.h"
#ifdef TABLING
#include "tab.macros.h"

View File

@ -23,7 +23,7 @@
#ifdef SBA
#include <stdio.h>
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "or.macros.h"
#include "opt.mavar.h"

View File

@ -16,7 +16,7 @@
#include "Yap.h"
#ifdef YAPOR
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "or.macros.h"
#ifdef TABLING
#include "tab.macros.h"

View File

@ -16,7 +16,7 @@
#include "Yap.h"
#if defined(TABLING) && defined(YAPOR)
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "tab.macros.h"
#include "or.macros.h"

View File

@ -20,7 +20,7 @@
#include <string.h>
#endif /* HAVE_STRING_H */
#include "Yatom.h"
#include "Heap.h"
#include "YapHeap.h"
#include "yapio.h"
#include "tab.macros.h"

View File

@ -224,6 +224,7 @@ print_usage(void)
fprintf(stderr,"\n[ Valid switches for command line arguments: ]\n");
fprintf(stderr," -? Shows this screen\n");
fprintf(stderr," -b Boot file \n");
fprintf(stderr," -dump-runtime-variables\n");
fprintf(stderr," -f initialization file or \"none\"\n");
fprintf(stderr," -g Run Goal Before Top-Level \n");
fprintf(stderr," -z Run Goal Before Top-Level \n");
@ -295,6 +296,13 @@ add_end_dot(char arg[])
static int
dump_runtime_variables(void)
{
fprintf(stderr,"CC=\"%s\"\n",YAP_CC);
fprintf(stderr,"YAP_ROOTDIR=\"%s\"\n",YAP_ROOTDIR);
fprintf(stderr,"YAP_LIBS=\"%s\"\n",YAP_LIBS);
fprintf(stderr,"YAP_SHLIB_SUFFIX=\"%s\"\n",YAP_SHLIB_SUFFIX);
fprintf(stderr,"YAP_VERSION=%d\n",YAP_VERSION);
exit(0);
return 1;
}
/*
@ -346,6 +354,7 @@ parse_yap_arguments(int argc, char *argv[], YAP_init_args *iap)
ssize = &(iap->DelayedReleaseLoad);
goto GetSize;
#else
case 'd':
if (!strcmp("dump-runtime-variables",p))
return dump_runtime_variables();
#endif /* ENV_COPY || ACOW || SBA */
@ -807,7 +816,7 @@ exec_top_level(int BootMode, YAP_init_args *iap)
YAP_Atom livegoal;
/* read the bootfile */
do_bootfile (iap->YapPrologBootFile ? iap->YapPrologBootFile : BootFile);
livegoal = YAP_FullLookupAtom("$live");
livegoal = YAP_FullLookupAtom("prolog");
/* initialise the top-level */
if (BootMode == YAP_FULL_BOOT_FROM_PROLOG) {
char init_file[256];
@ -846,7 +855,7 @@ exec_top_level(int BootMode, YAP_init_args *iap)
/* read it before case someone, that is, Ashwin, hides
the atom false away ;-).
*/
livegoal = YAP_FullLookupAtom("$live");
livegoal = YAP_FullLookupAtom("prolog");
atomfalse = YAP_MkAtomTerm (YAP_FullLookupAtom("$false"));
while (YAP_GetValue (livegoal) != atomfalse) {
YAP_Reset();

View File

@ -59,10 +59,6 @@ typedef intptr_t ssize_t; /* signed version of size_t */
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
}
#endif
/*******************************

View File

@ -149,7 +149,6 @@ A LT N "<"
A LastExecuteWithin F "$last_execute_within"
A Leash F "$leash"
A List N "list"
A Live F "$live"
A LoadAnswers N "load_answers"
A Local N "local_sp"
A LocalA N "local"

View File

@ -21,7 +21,7 @@
true :- true.
'$live' :-
prolog :-
'$init_system',
'$do_live'.
@ -161,7 +161,7 @@ true :- true.
get_value('$top_level_goal',GA), GA \= [], !,
set_value('$top_level_goal',[]),
'$run_atom_goal'(GA),
set_value('$live','$false').
set_value(prolog,'$false').
'$enter_top_level' :-
prompt(_,' ?- '),
prompt(' | '),
@ -174,7 +174,7 @@ true :- true.
prompt(_,' |: '),
'$command'((?-Command),Varnames,Pos,top),
'$sync_mmapped_arrays',
set_value('$live','$false').
set_value(prolog,'$false').
'$startup_goals' :-
get_value('$extend_file_search_path',P), P \= [],
@ -958,7 +958,7 @@ break :-
format(user_error, '% Break (level ~w)~n', [NBL]),
'$do_live',
!,
set_value('$live','$true'),
set_value(prolog,'$true'),
b_setval('$spy_glist',GList),
nb_setval('$spy_gn',SPY_GN),
'$set_input'(InpStream), '$set_output'(OutStream),