gprolog
TLDR
Start GNU Prolog interpreter
SYNOPSIS
gprolog [options]
gplc [options] files
DESCRIPTION
GNU Prolog is a Prolog compiler with constraint solving over finite domains. It compiles Prolog to native code and provides an interactive interpreter.
GNU Prolog supports ISO Prolog with extensions for constraint logic programming, making it suitable for combinatorial problems, scheduling, and AI applications.
PARAMETERS
--consult-file file
Load Prolog file at startup.--query-goal goal
Execute goal after loading.--init-goal goal
Execute initialization goal.--entry-goal goal
Entry point goal.--no-top-level
Exit after executing goals.
INTERPRETER COMMANDS
?- listing. % Show predicates
?- halt. % Exit
?- trace. % Enable tracing
COMPILING
gplc program.pl -o program
# With optimization
gplc --fast-math program.pl -o program
CAVEATS
Syntax differs slightly from SWI-Prolog. Native compilation adds startup complexity. Constraint solving requires finite domain declarations. Interactive debugging requires trace mode.
HISTORY
GNU Prolog was created by Daniel Diaz at INRIA, first released in 1996. It emphasizes native code compilation and constraint solving, distinguishing it from interpreted Prolog systems.


