generic fixes, mostly indentin
This commit is contained in:
276
C/tracer.c
276
C/tracer.c
@@ -26,12 +26,10 @@
|
||||
#include "clause.h"
|
||||
#include "tracer.h"
|
||||
|
||||
|
||||
static void
|
||||
send_tracer_message(char *start, char *name, Int arity, char *mname, CELL *args)
|
||||
{
|
||||
static void send_tracer_message(char *start, char *name, Int arity, char *mname,
|
||||
CELL *args) {
|
||||
if (name == NULL) {
|
||||
#ifdef YAPOR
|
||||
#ifdef YAPOR
|
||||
fprintf(stderr, "(%d)%s", worker_id, start);
|
||||
#else
|
||||
fprintf(stderr, "%s", start);
|
||||
@@ -41,19 +39,21 @@ send_tracer_message(char *start, char *name, Int arity, char *mname, CELL *args)
|
||||
|
||||
if (arity) {
|
||||
if (args)
|
||||
fprintf(stderr, "%s %s:%s(", start, mname, name);
|
||||
fprintf(stderr, "%s %s:%s(", start, mname, name);
|
||||
else
|
||||
fprintf(stderr, "%s %s:%s/%lu", start, mname, name, (unsigned long int)arity);
|
||||
fprintf(stderr, "%s %s:%s/%lu", start, mname, name,
|
||||
(unsigned long int)arity);
|
||||
} else {
|
||||
fprintf(stderr, "%s %s:%s", start, mname, name);
|
||||
}
|
||||
if (args) {
|
||||
for (i= 0; i < arity; i++) {
|
||||
if (i > 0) fprintf(stderr, ",");
|
||||
Yap_plwrite(args[i], NULL, 15, Handle_vars_f|AttVar_Portray_f, 1200);
|
||||
for (i = 0; i < arity; i++) {
|
||||
if (i > 0)
|
||||
fprintf(stderr, ",");
|
||||
Yap_plwrite(args[i], NULL, 15, Handle_vars_f | AttVar_Portray_f, 1200);
|
||||
}
|
||||
if (arity) {
|
||||
fprintf(stderr, ")");
|
||||
fprintf(stderr, ")");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -78,15 +78,16 @@ check_trail_consistency(void) {
|
||||
ptr = --ptr;
|
||||
if (!IsVarTerm(TrailTerm(ptr))) {
|
||||
if (IsApplTerm(TrailTerm(ptr))) {
|
||||
CELL *cptr = (CELL *)ptr;
|
||||
ptr = (tr_fr_ptr)(cptr-1);
|
||||
CELL *cptr = (CELL *)ptr;
|
||||
ptr = (tr_fr_ptr)(cptr-1);
|
||||
} else {
|
||||
if (IsPairTerm(TrailTerm(ptr))) {
|
||||
CELL *p = RepPair(TrailTerm(ptr));
|
||||
if IsAttVar(p) continue;
|
||||
}
|
||||
printf("Oops at call %ld, B->cp(%p) TR(%p) pt(%p)\n", vsc_count,B->cp_tr, TR, ptr);
|
||||
return(FALSE);
|
||||
if (IsPairTerm(TrailTerm(ptr))) {
|
||||
CELL *p = RepPair(TrailTerm(ptr));
|
||||
if IsAttVar(p) continue;
|
||||
}
|
||||
printf("Oops at call %ld, B->cp(%p) TR(%p) pt(%p)\n",
|
||||
vsc_count,B->cp_tr, TR, ptr);
|
||||
return(FALSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -100,16 +101,13 @@ CELL old_value = 0L, old_value2 = 0L;
|
||||
|
||||
void jmp_deb(int), jmp_deb2(void);
|
||||
|
||||
void
|
||||
jmp_deb2( void )
|
||||
{
|
||||
fprintf(stderr,"Here\n");
|
||||
}
|
||||
void jmp_deb2(void) { fprintf(stderr, "Here\n"); }
|
||||
|
||||
void
|
||||
jmp_deb(int i) {
|
||||
if (i) printf("Here we go %ld\n", old_value++);
|
||||
if (old_value == 716) jmp_deb2();
|
||||
void jmp_deb(int i) {
|
||||
if (i)
|
||||
printf("Here we go %ld\n", old_value++);
|
||||
if (old_value == 716)
|
||||
jmp_deb2();
|
||||
}
|
||||
|
||||
struct various_codes *sc;
|
||||
@@ -126,8 +124,8 @@ check_area(void)
|
||||
for (i= 0; i < 332; i++) {
|
||||
if (array[i] !=((CELL *)0x187a800)[i]) {
|
||||
if (first != -1) {
|
||||
first = i;
|
||||
found = TRUE;
|
||||
first = i;
|
||||
found = TRUE;
|
||||
}
|
||||
fprintf(stderr,"%lld changed %d\n",vsc_count,i);
|
||||
}
|
||||
@@ -141,89 +139,95 @@ check_area(void)
|
||||
PredEntry *old_p[10000];
|
||||
Term old_x1[10000], old_x2[10000], old_x3[10000];
|
||||
|
||||
//static CELL oldv;
|
||||
// static CELL oldv;
|
||||
|
||||
void
|
||||
low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
{
|
||||
void low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args) {
|
||||
CACHE_REGS
|
||||
char *s;
|
||||
char *mname;
|
||||
Int arity;
|
||||
/* extern int gc_calls; */
|
||||
vsc_count++;
|
||||
//if (HR < ASP ) return;
|
||||
//fif (vsc_count == 12534) jmp_deb( 2 );
|
||||
// if (HR < ASP ) return;
|
||||
// fif (vsc_count == 12534) jmp_deb( 2 );
|
||||
#if __ANDROID__ && 0
|
||||
PredEntry *ap = pred;
|
||||
if (pred && port == enter_pred) {
|
||||
UInt flags = ap->PredFlags;
|
||||
if (ap->ArityOfPE && ap->ModuleOfPred != IDB_MODULE)
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP ", " %s/%ld %lx\n", NameOfFunctor(ap->FunctorOfPred)->StrOfAE, ap->ArityOfPE, flags);
|
||||
/* printf(" %s/%ld %lx\n", NameOfFunctor(ap->FunctorOfPred)->StrOfAE, ap->ArityOfPE, flags); */
|
||||
else if (ap->ModuleOfPred != IDB_MODULE)
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP "," %s/%ld %lx\n", ((Atom)(ap->FunctorOfPred))->StrOfAE, ap->ArityOfPE, flags);
|
||||
/* printf(" %s/%ld %lx\n", ((Atom)(ap->FunctorOfPred))->StrOfAE, ap->ArityOfPE, flags); */
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP "," %x ", ap->src.OwnerFile);
|
||||
}
|
||||
UInt flags = ap->PredFlags;
|
||||
if (ap->ArityOfPE && ap->ModuleOfPred != IDB_MODULE)
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP ", " %s/%ld %lx\n",
|
||||
NameOfFunctor(ap->FunctorOfPred)->StrOfAE,
|
||||
ap->ArityOfPE, flags);
|
||||
/* printf(" %s/%ld %lx\n", NameOfFunctor(ap->FunctorOfPred)->StrOfAE,
|
||||
* ap->ArityOfPE, flags); */
|
||||
else if (ap->ModuleOfPred != IDB_MODULE)
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP ", " %s/%ld %lx\n",
|
||||
((Atom)(ap->FunctorOfPred))->StrOfAE, ap->ArityOfPE,
|
||||
flags);
|
||||
/* printf(" %s/%ld %lx\n", ((Atom)(ap->FunctorOfPred))->StrOfAE,
|
||||
* ap->ArityOfPE, flags); */
|
||||
__android_log_print(ANDROID_LOG_INFO, "YAP ", " %x ", ap->src.OwnerFile);
|
||||
}
|
||||
return;
|
||||
#endif
|
||||
|
||||
// if (!worker_id) return;
|
||||
LOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
sc = Yap_heap_regs;
|
||||
//if (vsc_count == 161862) jmp_deb(1);
|
||||
fprintf(stderr,"B=%ld ", LCL0-(CELL*)B);
|
||||
#ifdef THREADS
|
||||
// if (vsc_count == 161862) jmp_deb(1);
|
||||
#ifdef THREADS
|
||||
LOCAL_ThreadHandle.thread_inst_count++;
|
||||
#endif
|
||||
#endif
|
||||
#ifdef COMMENTED
|
||||
fprintf(stderr,"in %p\n");
|
||||
CELL * gc_ENV = ENV;
|
||||
while (gc_ENV != NULL) { /* no more environments */
|
||||
fprintf(stderr,"%ld\n", LCL0-gc_ENV);
|
||||
gc_ENV = (CELL *) gc_ENV[E_E]; /* link to prev
|
||||
* environment */
|
||||
fprintf(stderr, "in %p\n");
|
||||
CELL *gc_ENV = ENV;
|
||||
while (gc_ENV != NULL) { /* no more environments */
|
||||
fprintf(stderr, "%ld\n", LCL0 - gc_ENV);
|
||||
gc_ENV = (CELL *)gc_ENV[E_E]; /* link to prev
|
||||
* environment */
|
||||
}
|
||||
return;
|
||||
{
|
||||
choiceptr b_p = B;
|
||||
while (b_p) {
|
||||
fprintf(stderr,"%p %ld\n",b_p,Yap_op_from_opcode(b_p->cp_ap->opc));
|
||||
fprintf(stderr, "%p %ld\n", b_p, Yap_op_from_opcode(b_p->cp_ap->opc));
|
||||
b_p = b_p->cp_b;
|
||||
}
|
||||
}
|
||||
{ choiceptr myB = B;
|
||||
while (myB) myB = myB->cp_b;
|
||||
{
|
||||
choiceptr myB = B;
|
||||
while (myB)
|
||||
myB = myB->cp_b;
|
||||
}
|
||||
//*(H0+(0xb65f2850-0xb64b2008)/sizeof(CELL))==0xc ||
|
||||
//0x4fd4d
|
||||
//*(H0+(0xb65f2850-0xb64b2008)/sizeof(CELL))==0xc ||
|
||||
// 0x4fd4d
|
||||
if (vsc_count > 1388060LL && vsc_count < 1388070LL) {
|
||||
if (vsc_count==1388061LL)
|
||||
if (vsc_count == 1388061LL)
|
||||
jmp_deb(1);
|
||||
if (vsc_count % 1LL == 0) {
|
||||
UInt sz = Yap_regp->H0_[17];
|
||||
UInt end = sizeof(MP_INT)/sizeof(CELL)+sz+1;
|
||||
fprintf(stderr,"VAL %lld %d %x/%x\n",vsc_count,sz,H0[16],H0[16+end]);
|
||||
UInt end = sizeof(MP_INT) / sizeof(CELL) + sz + 1;
|
||||
fprintf(stderr, "VAL %lld %d %x/%x\n", vsc_count, sz, H0[16],
|
||||
H0[16 + end]);
|
||||
}
|
||||
} else
|
||||
return;
|
||||
} else
|
||||
return;
|
||||
{
|
||||
tr_fr_ptr pt = (tr_fr_ptr)LOCAL_TrailBase;
|
||||
if (pt[140].term == 0 && pt[140].value != 0)
|
||||
jmp_deb(1);
|
||||
}
|
||||
if (worker_id != 04 || worker_id != 03) return;
|
||||
if (worker_id != 04 || worker_id != 03)
|
||||
return;
|
||||
// if (vsc_count == 218280)
|
||||
// vsc_xstop = 1;
|
||||
if (vsc_count < 1468068888) {
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
if (port != enter_pred ||
|
||||
!pred ||
|
||||
pred->ArityOfPE != 4 ||
|
||||
strcmp(RepAtom(NameOfFunctor(pred->FunctorOfPred))->StrOfAE,"in_between_target_phrases")) {
|
||||
if (port != enter_pred || !pred || pred->ArityOfPE != 4 ||
|
||||
strcmp(RepAtom(NameOfFunctor(pred->FunctorOfPred))->StrOfAE,
|
||||
"in_between_target_phrases")) {
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
@@ -243,7 +247,8 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
if (vsc_count == 123536441LL) vsc_xstop = 1;
|
||||
if (vsc_count == 123536441LL)
|
||||
vsc_xstop = 1;
|
||||
if (vsc_count < 5530257LL) {
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
@@ -259,17 +264,14 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
jmp_deb(1);
|
||||
{
|
||||
tr_fr_ptr pt = (tr_fr_ptr)LOCAL_TrailBase;
|
||||
if (pt[153].term == 0 && pt[153].value == 0 &&
|
||||
pt[154].term != 0 && pt[154].value != 0 && ( TR > pt+154 ||
|
||||
TR_FZ > pt+154))
|
||||
if (pt[153].term == 0 && pt[153].value == 0 && pt[154].term != 0 &&
|
||||
pt[154].value != 0 && (TR > pt + 154 || TR_FZ > pt + 154))
|
||||
jmp_deb(2);
|
||||
if (pt[635].term == 0 && pt[635].value == 0 &&
|
||||
pt[636].term != 0 && pt[636].value != 0 && ( TR > pt+636 ||
|
||||
TR_FZ > pt+636))
|
||||
if (pt[635].term == 0 && pt[635].value == 0 && pt[636].term != 0 &&
|
||||
pt[636].value != 0 && (TR > pt + 636 || TR_FZ > pt + 636))
|
||||
jmp_deb(3);
|
||||
if (pt[138].term == 0 && pt[138].value == 0 &&
|
||||
pt[139].term != 0 && pt[139].value != 0 && ( TR > pt+138 ||
|
||||
TR_FZ > pt+138) )
|
||||
if (pt[138].term == 0 && pt[138].value == 0 && pt[139].term != 0 &&
|
||||
pt[139].value != 0 && (TR > pt + 138 || TR_FZ > pt + 138))
|
||||
jmp_deb(4);
|
||||
}
|
||||
if (vsc_count == 287939LL)
|
||||
@@ -277,8 +279,7 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
if (vsc_count == 173118LL)
|
||||
jmp_deb(1);
|
||||
if (!(vsc_count >= 287934LL && vsc_count <= 287939LL) &&
|
||||
!(vsc_count >= 173100LL && vsc_count <= 173239LL) &&
|
||||
vsc_count != -1)
|
||||
!(vsc_count >= 173100LL && vsc_count <= 173239LL) && vsc_count != -1)
|
||||
return;
|
||||
if (vsc_count == 51021) {
|
||||
printf("Here I go\n");
|
||||
@@ -287,38 +288,40 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
if (vsc_count > 52000) exit(0);
|
||||
if (vsc_count > 52000)
|
||||
exit(0);
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
if (vsc_count == 837074) {
|
||||
printf("Here I go\n");
|
||||
}
|
||||
}
|
||||
if (gc_calls < 1) {
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
{
|
||||
CELL *env_ptr = ENV;
|
||||
CELL *env_ptr = ENV;
|
||||
PredEntry *p;
|
||||
|
||||
while (env_ptr) {
|
||||
PredEntry *pe = EnvPreg(env_ptr[E_CP]);
|
||||
|
||||
printf("%p->",env_ptr,pe);
|
||||
if (vsc_count == 52LL) printf("\n");
|
||||
printf("%p->", env_ptr, pe);
|
||||
if (vsc_count == 52LL)
|
||||
printf("\n");
|
||||
if (p == pe) {
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
return;
|
||||
}
|
||||
if (env_ptr != NULL)
|
||||
env_ptr = (CELL *)(env_ptr[E_E]);
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
env_ptr = (CELL *)(env_ptr[E_E]);
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
#endif
|
||||
fprintf(stderr,"%lld ",vsc_count);
|
||||
fprintf(stderr, "%lld ", vsc_count);
|
||||
#if defined(THREADS) || defined(YAPOR)
|
||||
fprintf(stderr,"(%d)", worker_id);
|
||||
fprintf(stderr, "(%d)", worker_id);
|
||||
#endif
|
||||
/* check_trail_consistency(); */
|
||||
if (pred == NULL) {
|
||||
@@ -338,7 +341,7 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
else
|
||||
s = (char *)RepAtom(NameOfFunctor((pred->FunctorOfPred)))->StrOfAE;
|
||||
/* if ((pred->ModuleOfPred == 0) && (s[0] == '$'))
|
||||
return; */
|
||||
return; */
|
||||
send_tracer_message("CALL: ", s, arity, mname, args);
|
||||
break;
|
||||
case try_or:
|
||||
@@ -362,7 +365,7 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
send_tracer_message("FAIL ", NULL, 0, NULL, args);
|
||||
mname = (char *)RepAtom(AtomOfTerm(Yap_Module_Name(pred)))->StrOfAE;
|
||||
arity = pred->ArityOfPE;
|
||||
if (arity == 0) {
|
||||
if (arity == 0) {
|
||||
s = (char *)RepAtom((Atom)pred->FunctorOfPred)->StrOfAE;
|
||||
send_tracer_message("RETRY CONSUMER: ", s, 0, mname, NULL);
|
||||
} else {
|
||||
@@ -378,9 +381,9 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
mname = (char *)RepAtom(AtomOfTerm(Yap_Module_Name(pred)))->StrOfAE;
|
||||
arity = pred->ArityOfPE;
|
||||
if (arity == 0)
|
||||
s = (char *)RepAtom((Atom)pred->FunctorOfPred)->StrOfAE;
|
||||
s = (char *)RepAtom((Atom)pred->FunctorOfPred)->StrOfAE;
|
||||
else
|
||||
s = (char *)RepAtom(NameOfFunctor((pred->FunctorOfPred)))->StrOfAE;
|
||||
s = (char *)RepAtom(NameOfFunctor((pred->FunctorOfPred)))->StrOfAE;
|
||||
send_tracer_message("RETRY LOADER: ", s, 0, mname, NULL);
|
||||
}
|
||||
break;
|
||||
@@ -390,12 +393,12 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
mname = (char *)RepAtom(AtomOfTerm(Yap_Module_Name(pred)))->StrOfAE;
|
||||
arity = pred->ArityOfPE;
|
||||
if (pred->ModuleOfPred == IDB_MODULE) {
|
||||
s = "recorded";
|
||||
arity = 3;
|
||||
s = "recorded";
|
||||
arity = 3;
|
||||
} else if (arity == 0) {
|
||||
s = (char *)RepAtom((Atom)pred->FunctorOfPred)->StrOfAE;
|
||||
s = (char *)RepAtom((Atom)pred->FunctorOfPred)->StrOfAE;
|
||||
} else {
|
||||
s = (char *)RepAtom(NameOfFunctor((pred->FunctorOfPred)))->StrOfAE;
|
||||
s = (char *)RepAtom(NameOfFunctor((pred->FunctorOfPred)))->StrOfAE;
|
||||
}
|
||||
send_tracer_message("RETRY: ", s, arity, mname, args);
|
||||
}
|
||||
@@ -405,41 +408,34 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
UNLOCK(Yap_heap_regs->low_level_trace_lock);
|
||||
}
|
||||
|
||||
void
|
||||
toggle_low_level_trace(void)
|
||||
{
|
||||
void toggle_low_level_trace(void) {
|
||||
Yap_do_low_level_trace = !Yap_do_low_level_trace;
|
||||
}
|
||||
|
||||
static Int start_low_level_trace( USES_REGS1 )
|
||||
{
|
||||
static Int start_low_level_trace(USES_REGS1) {
|
||||
Yap_do_low_level_trace = TRUE;
|
||||
return(TRUE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
static Int total_choicepoints( USES_REGS1 )
|
||||
{
|
||||
return Yap_unify(MkIntegerTerm(LOCAL_total_choicepoints),ARG1);
|
||||
static Int total_choicepoints(USES_REGS1) {
|
||||
return Yap_unify(MkIntegerTerm(LOCAL_total_choicepoints), ARG1);
|
||||
}
|
||||
|
||||
static Int reset_total_choicepoints( USES_REGS1 )
|
||||
{
|
||||
static Int reset_total_choicepoints(USES_REGS1) {
|
||||
LOCAL_total_choicepoints = 0;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static Int show_low_level_trace( USES_REGS1 )
|
||||
{
|
||||
fprintf(stderr,"Call counter=%lld\n",vsc_count);
|
||||
return(TRUE);
|
||||
static Int show_low_level_trace(USES_REGS1) {
|
||||
fprintf(stderr, "Call counter=%lld\n", vsc_count);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
#ifdef THREADS
|
||||
static Int start_low_level_trace2( USES_REGS1 )
|
||||
{
|
||||
thread_trace = IntegerOfTerm(Deref(ARG1))+1;
|
||||
static Int start_low_level_trace2(USES_REGS1) {
|
||||
thread_trace = IntegerOfTerm(Deref(ARG1)) + 1;
|
||||
Yap_do_low_level_trace = TRUE;
|
||||
return(TRUE);
|
||||
return (TRUE);
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -449,52 +445,52 @@ static Int start_low_level_trace2( USES_REGS1 )
|
||||
|
||||
Stop displaying messages at procedure entry and retry.
|
||||
|
||||
Note that using this compile-time option will slow down execution, even if messages are
|
||||
Note that using this compile-time option will slow down execution, even if
|
||||
messages are
|
||||
not being output.
|
||||
|
||||
*/
|
||||
static Int stop_low_level_trace( USES_REGS1 )
|
||||
{
|
||||
static Int stop_low_level_trace(USES_REGS1) {
|
||||
Yap_do_low_level_trace = FALSE;
|
||||
LOCAL_do_trace_primitives = TRUE;
|
||||
#if DEBUG_LOCKS
|
||||
debug_locks = TRUE;
|
||||
#endif
|
||||
return(TRUE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
volatile int v_wait;
|
||||
|
||||
static Int vsc_wait( USES_REGS1 )
|
||||
{
|
||||
while (!v_wait);
|
||||
static Int vsc_wait(USES_REGS1) {
|
||||
while (!v_wait)
|
||||
;
|
||||
return true;
|
||||
}
|
||||
|
||||
static Int vsc_go( USES_REGS1 )
|
||||
{
|
||||
v_wait=1;
|
||||
static Int vsc_go(USES_REGS1) {
|
||||
v_wait = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
void
|
||||
Yap_InitLowLevelTrace(void)
|
||||
{
|
||||
Yap_InitCPred("start_low_level_trace", 0, start_low_level_trace, SafePredFlag);
|
||||
/** @pred start_low_level_trace
|
||||
void Yap_InitLowLevelTrace(void) {
|
||||
Yap_InitCPred("start_low_level_trace", 0, start_low_level_trace,
|
||||
SafePredFlag);
|
||||
/** @pred start_low_level_trace
|
||||
|
||||
|
||||
Begin display of messages at procedure entry and retry.
|
||||
|
||||
|
||||
|
||||
*/
|
||||
#if THREADS
|
||||
Yap_InitCPred("start_low_level_trace", 1, start_low_level_trace2, SafePredFlag);
|
||||
Yap_InitCPred("start_low_level_trace", 1, start_low_level_trace2,
|
||||
SafePredFlag);
|
||||
#endif
|
||||
Yap_InitCPred("stop_low_level_trace", 0, stop_low_level_trace, SafePredFlag);
|
||||
Yap_InitCPred("show_low_level_trace", 0, show_low_level_trace, SafePredFlag);
|
||||
Yap_InitCPred("total_choicepoints", 1, total_choicepoints, SafePredFlag);
|
||||
Yap_InitCPred("reset_total_choicepoints", 0, reset_total_choicepoints, SafePredFlag);
|
||||
Yap_InitCPred("reset_total_choicepoints", 0, reset_total_choicepoints,
|
||||
SafePredFlag);
|
||||
Yap_InitCPred("vsc_wait", 0, vsc_wait, SafePredFlag);
|
||||
Yap_InitCPred("vsc_go", 0, vsc_go, SafePredFlag);
|
||||
}
|
||||
|
Reference in New Issue
Block a user