Re: Prolog Execution Algorithm



On Sun, 23 Oct 2005, rush wrote:
"Struiver" <dieter.vanderelst@xxxxxxxxx> wrote in message

I'm looking for a good explanation of the algorithm (pseudocode ?) that
prolog uses to solve a query.

I know that the book by Ivan Bratko features a version of the
algorithm, but I'm looking for a more elaborate version (with
particular attention to the handling of variables).

Well, there are different approaches to implement prolog, wiht consequently
different algorithms. But try to get a hold of WAM thesis (ort any text on
WAM), which descirbes efficient abstract machine that executes compiled
prolog.

On a very detailed level. Rather like answering someone's explanation for how a language works by directing them to a compiler for it. On the whole it's best to have a feel for how the language works on a conceptual level first, and I doubt it's even possible to go in the reverse direction. I don't think looking at work on the WAM would help this poster.

Matthew Huntbach
.



Relevant Pages

  • Re: Planner, micro-planner, etc.
    ... emulator-based Prolog implementations had we followed the DEC-10 ... TOAM) is fundamentally better than the WAM. ... and probably many other implementation principles that one could ...
    (comp.lang.prolog)
  • Re: Prolog compiler correctness
    ... which in turn has an assembler that executes the ... WAM code. ... I'm only concerned about Prolog correctness, ... And for people who worked on popular open source Prolog compiler ...
    (comp.lang.prolog)
  • Re: Planner, micro-planner, etc.
    ... And also, if things like WAM were created for Prolog, why ... Prolog, but we could have ended up with similar or even faster ... emulator-based Prolog implementations had we followed the DEC-10 ... implementation or the traditional Pascal machine. ...
    (comp.lang.prolog)
  • Re: Prolog compiler correctness
    ... which in turn has an assembler that executes the ... WAM code. ... I'm not a professional compiler writer, ... If it is about a real Prolog engine ...
    (comp.lang.prolog)
  • Re: Mainstreaming Prolog a Pragmatic Approach?
    ... > written out in p-Prolog would open a lot a doors for a lot of students, ... Prolog to the WAM written in Prolog, in commercial systems, ... So you can find Prolog2WAM compilers for free in many places. ...
    (comp.lang.prolog)