* Sorry, accidentally sent a draft of this mail *
> I'm sorry for delayed post.
> I'm trying to write the sketched description of inter-language debugger.
> I'd like to clarify some aspects to make sure that we're talking about
> the same things.
> 1. Java application is debugged using JDI i.e. 2 processes for 2 JVMs.
> 1st JVM debugger (process#1) controls debugging (using GUI)),
> 2nd (remote) JVM - debuggee(process#2) (that executes the application).
> 2. Logtalk is compiled to backed Prolog in debug mode.
> So we deal with Prolog interpreter executing code with the
> clauses wrapped by Logtalk;
As long as the Logtalk runtime is loaded.
> Debugger should map this clauses to Logtalk (GUI)
> Further, as in Prolog.
Do you mean something like SWI-Prolog graphical debugger where the user can follow where in the sources is the goal currently being executed? That also works to some extent for Logtalk (i.e. you can the SWI-Prolog graphical debugger with Logtalk code).
> 3. Prolog uses its own debugger.
> 4. Inter-language calls.
> Correct me if I'm wrong - in debug mode we, in principle, could
> switch Logtalk from current backed Prolog to the one
> implemented in Java (JIProlog, GNU Prolog for Java, tuProlog).
Only for trivial applications if at all. Logtalk does use Prolog as an intermediate language when compiling source files but there are often portability issues if we try to use the generated intermediate Prolog code with a different Prolog backend compiler. Besides, in non-trivial Logtalk applications, proprietary Prolog resources are sometimes used, which will also prevent running the generated code with a different backend.
> So, we will have two similar debug units from item 1:
> First for java debugging ( process#1,2 )
> Second for Java-Prolog ( process#3,4 )
Not for Logtalk/Prolog for the reasons described above. Prolog is far different from Java in that there are multiple implementations with all sorts of portability issues due in part to limited standardization.
> Also, maybe there's the reason to have a look at PDT or something like this,
> for an example.
PDT definitely is worth a closer look. It supports both SWI-Prolog and Logtalk.