This paper compares the performance of executing compiled Prolog code on two different architectures under development at U. C. Berkeley. The first is the PLM, a special-purpose CISC architecture intended as a coprocessor for a host machine. The second is SPUR, a general-purpose RISC architecture that supports tagged data. Fourteen standard benchmark programs were run on both the PLM and SPUR simulators. The compiled code for SPUR was obtained by simple macro-expansion of PLM code generated by the PLM Prolog compiler. The two implementations are compared with regard to static and dynamic program size, execution speed, and memory system performance. On average, the macrocoded SPUR implementation has a static code size 14 times larger than the PLM, executes 16 times more instructions, yet requires only 2.3 times the number of machine cycles (or has the performance of 0.43 PLMs). When memory system performance is taken into account, SPUR is equivalent to 0.29 PLMs. Optimizations of the macro-expanded code and minor architectural changes to SPUR would increase this ratio to 0.53, or 0.60 for the largest benchmarks. Thus a tagged RISC architecture can execute Prolog at least half as fast as a special-purpose CISC architecture for Prolog.
[1]
Tep P. Dobry.
A High Performance Architecture For Prolog
,
1987
.
[2]
Yale N. Patt,et al.
Design decisions influencing the microarchitecture for a Prolog machine
,
1984,
MICRO 17.
[3]
David A. Patterson,et al.
Architecture of SOAR: Smalltalk on a RISC
,
1984,
ISCA '84.
[4]
Naoyuki Tamura.
Knowledge-Based Optimization in Prolog Compiler
,
1986,
FJCC.
[5]
Mark N. Wegman,et al.
Constant propagation with conditional branches
,
1985,
POPL.
[6]
Shing I. Kong,et al.
SPUR Coprocessor Interface Description
,
1987
.
[7]
Gaetano Borriello,et al.
Special- or General-Purpose Hardware for Prolog: A Comparison
,
1986
.
[8]
James R. Larus,et al.
Evaluation of the SPUR Lisp Architecture
,
1986,
ISCA.
[9]
Barry Fagin,et al.
The Berkeley PLM Instruction Set: An Instruction Set for Prolog
,
1986
.
[10]
David H. D. Warren,et al.
Applied logic : its use and implementation as a programming tool
,
1978
.
[11]
Yale N. Patt,et al.
Performance studies of a Prolog machine architecture
,
1985,
ISCA '85.
[12]
Emmanuel Katevenis,et al.
Reduced instruction set computer architectures for VLSI
,
1984
.