(1) Assume SWI-Prolog calls C code. (2) And then C code calls SWI-Prolog. All inside the same process, even inside the same thread.
Can I call SWI-Prolog in such a way that it opens a new garbage collection (GC) window? So that only what gets produce by the call to SWI-Prolog is marked and sweeped, and the rest stays untouched.
Reason for this question: Assume in transition from (1) to (2) something dirty happens. i.e. Prolog terms are created but garbage collection anchors are not registered.
An isolate would help that these Prolog terms are not eliminated.