Is there an easy way to view "stack traces" with the interpreter?

Tabling does use memoization. Even with subsumption
and modes, you are kind of enumerating and storing
a larger number of Self Avoiding Walks (SAWs).

@kuniaki.mukai was recently using hours and
giga bytes of memory, to compute something similar,
i.e. Grid Graph Path Counting A007764,

this series somehow grows 2^(n^2). Since you use
triples trait(X,P,V) your work is also related to the
Resource Description Framework (RDF).

I already suggested @kuniaki.mukai to use hard disk,
in particular streaming algorithms. One could elaborate
this idea again here, in case the use case is still

statically cataloging something.