Click on the title to obtain a gzip-ed PostScript version of the paper (67K).
Our proposal, which can be viewed either as a compile-time program specialisation preprocessing step, or as an enhancement to the HiLog encoding in predicate calculus presented by Chen, Kifer, and Warren, allows HiLog to be efficiently implemented on any Prolog system by simply modifying Prolog's input/output predicates to handle terms that are expressed using the flexible higher-order syntax of HiLog.
We formally prove that our proposal allows all HiLog programs that do not use any higher-order features to execute at the same speed as Prolog programs. Furthermore, we present performance results showing that generic HiLog predicates when compiled using the compilation scheme execute at least an order of magnitude faster than generic Prolog predicates, and with only minimal overhead compared to non-generic Prolog ones.