new debugger code would get lost in meta-calls
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@310 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
parent
2a156ddf33
commit
d70b5be256
14
C/modules.c
14
C/modules.c
@ -97,10 +97,16 @@ p_change_module(void)
|
||||
|
||||
static Int
|
||||
p_module_number(void)
|
||||
{ /* $change_module(New) */
|
||||
Term t = MkIntTerm(LookupModule(Deref(ARG1)));
|
||||
unify(t,ARG2);
|
||||
ARG2 = t;
|
||||
{ /* $module_number(Mod,Num) */
|
||||
Term tname = Deref(ARG1);
|
||||
Term t;
|
||||
if (IsVarTerm(tname)) {
|
||||
return(unify(tname, ModuleName[IntOfTerm(Deref(ARG2))]));
|
||||
}else {
|
||||
t = MkIntTerm(LookupModule(Deref(ARG1)));
|
||||
unify(t,ARG2);
|
||||
ARG2 = t;
|
||||
}
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
|
10
C/tracer.c
10
C/tracer.c
@ -102,12 +102,6 @@ check_trail_consistency(void) {
|
||||
}
|
||||
*/
|
||||
|
||||
static char *op_names[_std_top + 1] =
|
||||
{
|
||||
#define OPCODE(OP,TYPE) #OP
|
||||
#include "YapOpcodes.h"
|
||||
#undef OPCODE
|
||||
};
|
||||
|
||||
void
|
||||
low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
@ -115,14 +109,14 @@ low_level_trace(yap_low_level_port port, PredEntry *pred, CELL *args)
|
||||
char *s;
|
||||
char *mname;
|
||||
Int arity;
|
||||
extern int gc_calls;
|
||||
/* extern int gc_calls; */
|
||||
|
||||
vsc_count++;
|
||||
/* if (vsc_count < 49036000) return; */
|
||||
/* if (vsc_count > 500000) exit(0); */
|
||||
/* if (gc_calls < 1) return;*/
|
||||
#if defined(__GNUC__)
|
||||
YP_fprintf(YP_stderr,"%llu (%d) ", vsc_count, IntegerOfTerm(DEPTH));
|
||||
YP_fprintf(YP_stderr,"%llu (%p %p) ", vsc_count, P, CP);
|
||||
#endif
|
||||
/* check_trail_consistency(); */
|
||||
if (pred == NULL) {
|
||||
|
@ -710,6 +710,14 @@ debugging :-
|
||||
'$direct_spy'([Module|A]).
|
||||
|
||||
%'$creep'(G) :- $current_module(M),write(user_error,[creep,M,G]),nl(user_error),fail.
|
||||
% skip calls to assembly versions of execute.
|
||||
'$creep'([_|'$execute_in_mod'(G,ModNum)]) :- !,
|
||||
'$module_number'(Mod,ModNum),
|
||||
'$creep'([Mod|G]).
|
||||
'$creep'([M|'$execute_within'(G)]) :- !,
|
||||
'$creep'([M|G]).
|
||||
'$creep'([M|'$last_execute_within'(G)]) :- !,
|
||||
'$creep'([M|G]).
|
||||
'$creep'(G) :-
|
||||
'$get_value'('$alarm', true), !,
|
||||
'$set_value'('$alarm', []),
|
||||
|
Reference in New Issue
Block a user