Run-time profiling of functional logic programs

  • Authors:
  • B. Brassel;M. Hanus;F. Huch;J. Silva;G. Vidal

  • Affiliations:
  • Institut für Informatik, CAU Kiel, Kiel, Germany;Institut für Informatik, CAU Kiel, Kiel, Germany;Institut für Informatik, CAU Kiel, Kiel, Germany;DSIC, Tech. University of Valencia, Valencia, Spain;DSIC, Tech. University of Valencia, Valencia, Spain

  • Venue:
  • LOPSTR'04 Proceedings of the 14th international conference on Logic Based Program Synthesis and Transformation
  • Year:
  • 2004

Quantified Score

Hi-index 0.02

Visualization

Abstract

In this work, we introduce a profiling scheme for modern functional logic languages covering notions like laziness, sharing, and non-determinism. Firstly, we instrument a natural (big-step) semantics in order to associate a symbolic cost to each basic operation (e.g., variable updates, function unfoldings, case evaluations). While this cost semantics provides a formal basis to analyze the cost of a computation, the implementation of a cost-augmented interpreter based on it would introduce a huge overhead. Therefore, we also introduce a sound transformation that instruments a program such that its execution—under the standard semantics—yields not only the corresponding results but also the associated costs. Finally, we describe a prototype implementation of a profiler based on the developments in this paper.