Real-Time Systems

, Volume 45, Issue 1–2, pp 72–105

Transforming flow information during code optimization for timing analysis

Open Access

DOI: 10.1007/s11241-010-9091-8

Cite this article as:
Kirner, R., Puschner, P. & Prantl, A. Real-Time Syst (2010) 45: 72. doi:10.1007/s11241-010-9091-8


The steadily growing embedded-systems market comprises many application domains in which real-time constraints must be satisfied. To guarantee that these constraints are met, the analysis of the worst-case execution time (WCET) of software components is mandatory. In general WCET analysis needs additional control-flow information, which may be provided manually by the user or calculated automatically by program analysis. For flexibility and simplicity reasons it is desirable to specify the flow information at the same level at which the program is developed, i.e., at the source level. In contrast, to obtain precise WCET bounds the WCET analysis has to be performed at machine-code level. Mapping and transforming the flow information from the source-level down to the machine code, where flow information is used in the WCET analysis, is challenging, even more so if the compiler generates highly optimized code.

In this article we present a method for transforming flow information from source code to machine code. To obtain a mapping that is safe and accurate, flow information is transformed in parallel to code transformations performed by an optimizing compiler. This mapping is not only useful for transforming manual code annotations but also if platform-independent flow information is automatically calculated at the source level.

We show that our method can be applied to every type of semantics-preserving code transformation. The precision of this flow-information transformation allows its users to calculate tight WCET bounds.


Worst-case execution time analysis Real-time languages Compiler optimizations Code transformation Abstract interpretation Graph transformation 



Worst-case execution time


Best-case execution time


Implicit path enumeration technique


Control-flow graph with loop-scope information

Copyright information

© The Author(s) 2010

Authors and Affiliations

  1. 1.Institut für Technische InformatikVienna University of TechnologyViennaAustria
  2. 2.Institut für ComputersprachenVienna University of TechnologyViennaAustria

Personalised recommendations