Want to understand better how swi prolog works

Hi dear SWI prolog folks, I recently played with swi prolog and really love it. I am wondering if there is a good source, books or websites, that can help me understand more and deeper about how prolog works. As a software engineer, my philosophy is you have to know how a language works in order to get the real power of it.


See: Useful Prolog references

Very nice!! Thanks Eric!

1 Like

Notably: SWI-Prolog 0.0.0 was based on A Portable Prolog Compiler by D.L. Bowen, L.H. Byrd and W.F. Clocksin.

Really old, but it was what got me hooked and it is not hard to understand. Once you get that there are some more tricks to learn for understanding how various extensions work. IMO a simple mental model dealing with the crude translation of Prolog source to a VM and how this VM is roughly implemented makes understanding everything that is built on top relatively easy.

1 Like

For Prolog in general:

The Implementation of Prolog, Patrice Boizumault. Princeton University Press, 1993.

Applied Logic: its use an implementation as a programming tool, David H.D. Warren. SRI International, 1983 - https://www.sri.com/wp-content/uploads/pdf/656.pdf

An Abstract Prolog Instruction Set, David H.D. Watten. SRI International, 1983 - http://www.ai.sri.com/pubs/files/641.pdf


Just noticed this paper:

Instead of describing implementation structures only, the paper further elaborates and explains why they are the way they are. I found it very instructive.

It would be great if other sources (such as the one Jan cited that triggered his interest) could be annotated to explain at that level of detail as well.