# Towards a General Framework for Static Cost Analysis of Parallel Logic   Programs

**Authors:** Maximiliano Klemen, Pedro Lopez-Garcia, John P. Gallagher, Jose F., Morales, Manuel V. Hermenegildo

arXiv: 1907.13272 · 2019-08-01

## TL;DR

This paper introduces a novel, flexible framework for static resource analysis of parallel logic programs, capable of estimating resource bounds and parallelism potential on multi-core platforms, filling a significant gap in existing research.

## Contribution

It presents the first approach to cost analysis of parallel logic programs, with a general framework adaptable to various resources, platforms, and execution models.

## Key findings

- Developed a method for solving max-based cost relations.
- Implemented the framework within the CiaoPP system.
- Provided experimental results demonstrating effectiveness.

## Abstract

The estimation and control of resource usage is now an important challenge in an increasing number of computing systems. In particular, requirements on timing and energy arise in a wide variety of applications such as internet of things, cloud computing, health, transportation, and robots. At the same time, parallel computing, with (heterogeneous) multi-core platforms in particular, has become the dominant paradigm in computer architecture. Predicting resource usage on such platforms poses a difficult challenge. Most work on static resource analysis has focused on sequential programs, and relatively little progress has been made on the analysis of parallel programs, or more specifically on parallel logic programs. We propose a novel, general, and flexible framework for setting up cost equations/relations which can be instantiated for performing resource usage analysis of parallel logic programs for a wide range of resources, platforms and execution models. The analysis estimates both lower and upper bounds on the resource usage of a parallel program (without executing it) as functions on input data sizes. In addition, it also infers other meaningful information to better exploit and assess the potential and actual parallelism of a system. We develop a method for solving cost relations involving the max function that arise in the analysis of parallel programs. Finally, we instantiate our general framework for the analysis of logic programs with Independent And-Parallelism, report on an implementation within the CiaoPP system, and provide some experimental results. To our knowledge, this is the first approach to the cost analysis of parallel logic programs.

## Full text

_Full body text omitted from this summary view._ Fetch the complete paper as Markdown: https://tomesphere.com/paper/1907.13272/full.md

## Figures

4 figures with captions in the complete paper: https://tomesphere.com/paper/1907.13272/full.md

## References

27 references — full list in the complete paper: https://tomesphere.com/paper/1907.13272/full.md

---
Source: https://tomesphere.com/paper/1907.13272