## Discrete Loops and Worst Case Performance (1994)

### Cached

### Download Links

- [www.auto.tuwien.ac.at]
- [www.auto.tuwien.ac.at]
- DBLP

### Other Repositories/Bibliography

Venue: | Computer Languages |

Citations: | 15 - 7 self |

### BibTeX

@ARTICLE{Blieberger94discreteloops,

author = {Johann Blieberger},

title = {Discrete Loops and Worst Case Performance},

journal = {Computer Languages},

year = {1994},

volume = {20},

pages = {193--212}

}

### Years of Citing Articles

### OpenURL

### Abstract

In this paper so-called discrete loops are introduced which narrow the gap between general loops (e.g. while- or repeat-loops) and for-loops. Alt- hough discrete loops can be used for applications that would otherwise require general loops, discrete loops are known to complete in any case. Furthermore it is possible to determine the number of iterations of a discrete loop, while this is trivial to do for for-loops and extremely difficult for general loops. Thus discrete loops form an ideal frame-work for determining the worst case timing behavior of a program and they are especially useful in implementing real-time systems and proving such systems correct.

### Citations

3053 | Scheduling Algorithms for Multiprogramming in a Hard Real-Time Environment
- Liu, Layland
- 1973
(Show Context)
Citation Context ...ntee the timeliness of real-time systems can only be achieved if the scheduling problem is solved accordingly. Most scheduling algorithms assume that the runtime of a task is known a priori (cf. e.g. =-=[1, 2, 3]-=-). Thus the worst case performance of a task plays a crucial role. The most difficult task in estimating the timing behavior of a program is to determine the number of iterations of a certain loop. Or... |

1422 | An axiomatic basis for computer programming
- Hoare
- 1969
(Show Context)
Citation Context ...gherlevel languages has been introduced in [8]. So-called schemas are used to estimate the best and worst case performance of statements of higher-level languages and an extension of Hoare logic (cf. =-=[9]-=-) is employed to prove the timeliness (and correctness) of real-time programs. The method is also able to handle certain real-time language constructs such as delays and time-outs. Although Hoare logi... |

543 | Concrete mathematics
- Graham, Knuth, et al.
- 1994
(Show Context)
Citation Context ...mples showing the advantages of discrete loops over general while or repeat-loops include the bottom-up version of Mergesort (cf. [17]), Euclid's algorithm, and the solution of Josephus' Problem (cf. =-=[16]-=-). 4. The Number of Iterations of a Monotonical Discrete Loop Because of the indeterminism involved in the definition of discrete loops, the number of iterations of such a loop cannot be determined ex... |

448 |
Algorithms
- Sedgewick
- 1988
(Show Context)
Citation Context ...t the Technical University of Vienna. 3.2.2. Other Examples. Other examples showing the advantages of discrete loops over general while or repeat-loops include the bottom-up version of Mergesort (cf. =-=[17]-=-), Euclid's algorithm, and the solution of Josephus' Problem (cf. [16]). 4. The Number of Iterations of a Monotonical Discrete Loop Because of the indeterminism involved in the definition of discrete ... |

277 |
Calculating the Maximum Execution Time of Real-Time Programs
- Puschner, Koza
- 1989
(Show Context)
Citation Context ...formed exactly i11 il il irl General loops, however, represent a very difficult task. In order to estimate the worst case performance of general loops many methods and tools have been developed, e.g. =-=[2, 5, 6, 7]-=-. In the following we will discuss some of them:sIn [5] language constructs have been introduced in order to let the programmer integrate knowledge about the actual behavior of algorithms which can no... |

258 |
Sorting and Searching, volume 3 of The Art of Computer Programming
- Knuth
- 1998
(Show Context)
Citation Context ...the loop body. Thus discrete loops ease estimating the worst-case performance of real-time programs. By the way, a loop like that in Figure 2 occurs in a not-recursive implementation of Heapsort (cf. =-=[13]-=- or [14] for a more readable form in a high-order programming language). Sections 3.2 and 6.2 will be concerned with algorithms that can profit from discrete loops; Heapsort will be treated in detail ... |

163 | Reasoning about Time in Higher-Level Language Software
- Shaw
- 1989
(Show Context)
Citation Context ... of concurrent programming and synchronization of concurrent processes at compile time.sThe idea to estimate worst case performance of programs written in higherlevel languages has been introduced in =-=[8]-=-. So-called schemas are used to estimate the best and worst case performance of statements of higher-level languages and an extension of Hoare logic (cf. [9]) is employed to prove the timeliness (and ... |

124 |
Predicting Program Execution Times by Analyzing Static and Dynamic Program Paths
- Park
- 1993
(Show Context)
Citation Context ...formed exactly i11 il il irl General loops, however, represent a very difficult task. In order to estimate the worst case performance of general loops many methods and tools have been developed, e.g. =-=[2, 5, 6, 7]-=-. In the following we will discuss some of them:sIn [5] language constructs have been introduced in order to let the programmer integrate knowledge about the actual behavior of algorithms which can no... |

117 |
Computability and Unsolvability
- DAVIS
- 1958
(Show Context)
Citation Context ...ably great if we restrict our interest to applications which do not loop forever. Theorem 7.1. If the number of iterations of a general loop can be determined by an integer-valued computable function =-=[21]-=- , a discrete loop with a remainder function can be used to achieve the same effect. Proof. We define the remainder function of the discrete loop by r :-- , i.e., the number of iterations of the gener... |

81 |
Binary search trees of bounded balance
- Nievergelt, Reingold
- 1973
(Show Context)
Citation Context ...ends on which kind of tree is used, e.g. standard binary trees or AVL-trees. Vienna Project WOOP 22 J. BLIEBERGER 6.2.2. Weight-Balanced Trees. So-called weight-balanced trees have been introduced in =-=[18]-=- and are treated in detail in [19] and in [20]. Definition 6.4. We define: (1) Let T be a binary tree with left subtree Tt and right subtree Tr. Then is called the root balance of T. Here IT] denotes ... |

58 |
Object-Oriented Real-Time Language Design: Constructs for Timing Constraints
- Ishikawa, Tokuda, et al.
- 1990
(Show Context)
Citation Context ...neral loops, i.e., by forcing the user to supply constant upper bounds for the number of iterations. Another approach is to let the user specify a time bound within the loop has to complete (cf. e.g. =-=[12]-=-). In any case the user, i.e., the programmer, has to react to such exceptional cases. In this paper we will follow a different approach: We will narrow the gap between general loops and for-loops by ... |

45 |
Evaluating Tight Execution Time Bounds of Programs by Annotations
- Mok, Amerasinghe, et al.
- 1989
(Show Context)
Citation Context ...user must specify upper bounds for general loop statements.sDetermining the execution time of a code segment is also mentioned in [10]. Real-time concurrent C uses a tool which originally is based on =-=[11]-=-. The code can have loops with user-specified loop bounds. Summing up, most researchers try to ease the task of estimating the number of general loop iterations by forbidding general loops, i.e., by f... |

34 |
Constructing Predictable Real Time Systems
- Halang, Stoyenko
- 1991
(Show Context)
Citation Context ...ntee the timeliness of real-time systems can only be achieved if the scheduling problem is solved accordingly. Most scheduling algorithms assume that the runtime of a task is known a priori (cf. e.g. =-=[1, 2, 3]-=-). Thus the worst case performance of a task plays a crucial role. The most difficult task in estimating the timing behavior of a program is to determine the number of iterations of a certain loop. Or... |

31 |
Real-time concurrent C: A language for programming dynamic real-time systems
- Gehani, Ramamritham
- 1991
(Show Context)
Citation Context ...tight bounds can be derived using this method. On the other hand, the user must specify upper bounds for general loop statements.sDetermining the execution time of a code segment is also mentioned in =-=[10]-=-. Real-time concurrent C uses a tool which originally is based on [11]. The code can have loops with user-specified loop bounds. Summing up, most researchers try to ease the task of estimating the num... |

31 |
Sorting and Searching, Volume 1 of Data Structures and Algorithms
- Mehlhorn
- 1984
(Show Context)
Citation Context ..., e.g. standard binary trees or AVL-trees. Vienna Project WOOP 22 J. BLIEBERGER 6.2.2. Weight-Balanced Trees. So-called weight-balanced trees have been introduced in [18] and are treated in detail in =-=[19]-=- and in [20]. Definition 6.4. We define: (1) Let T be a binary tree with left subtree Tt and right subtree Tr. Then is called the root balance of T. Here IT] denotes the number of leaves of tree T. (2... |

24 |
The design of real-time programming systems based on process models
- Mok
- 1984
(Show Context)
Citation Context ...ntee the timeliness of real-time systems can only be achieved if the scheduling problem is solved accordingly. Most scheduling algorithms assume that the runtime of a task is known a priori (cf. e.g. =-=[1, 2, 3]-=-). Thus the worst case performance of a task plays a crucial role. The most difficult task in estimating the timing behavior of a program is to determine the number of iterations of a certain loop. Or... |

22 |
On the average number of rebalancing operations in weight-balanced trees
- BLUM, MEHLHORN
- 1980
(Show Context)
Citation Context ...ard binary trees or AVL-trees. Vienna Project WOOP 22 J. BLIEBERGER 6.2.2. Weight-Balanced Trees. So-called weight-balanced trees have been introduced in [18] and are treated in detail in [19] and in =-=[20]-=-. Definition 6.4. We define: (1) Let T be a binary tree with left subtree Tt and right subtree Tr. Then is called the root balance of T. Here IT] denotes the number of leaves of tree T. (2) Tree T is ... |

18 |
The analysis of heapsort
- Schaffer, Sedgewick
- 1993
(Show Context)
Citation Context ... body. Thus discrete loops ease estimating the worst-case performance of real-time programs. By the way, a loop like that in Figure 2 occurs in a not-recursive implementation of Heapsort (cf. [13] or =-=[14]-=- for a more readable form in a high-order programming language). Sections 3.2 and 6.2 will be concerned with algorithms that can profit from discrete loops; Heapsort will be treated in detail in Secti... |

15 |
Graph algorithms and NP-completeness, volume 2 of Data structures and algorithms
- Mehlhorn
- 1984
(Show Context)
Citation Context ...initions the following lemma is trivially true. Lemma 2.1. A discrete loop completes if and only if the corresponding loop digraph is acyclic. [] Each acyclic digraph can be topologically sorted (cf. =-=[15]-=-), i.e., we can find a mapping ord: V - {0, 1,..., N, N + 1) such that for all edges (v, w)sE we have ord(v)srestrict ourselves to discrete loops that result in topologically sorted loop digraphs. Thi... |

12 |
A Partial Evaluator for the Maruti Hard-Real-Time System
- Nirkhe, Pugh
- 1993
(Show Context)
Citation Context ...formed exactly i11 il il irl General loops, however, represent a very difficult task. In order to estimate the worst case performance of general loops many methods and tools have been developed, e.g. =-=[2, 5, 6, 7]-=-. In the following we will discuss some of them:sIn [5] language constructs have been introduced in order to let the programmer integrate knowledge about the actual behavior of algorithms which can no... |

1 |
Reference manual for the Ada programming language
- ANSIMIL-STD
- 1983
(Show Context)
Citation Context ... is of a very general form and is considered for implementing those loops that can not be handled by for-loops. These loops include while-loops, repeat-loops, and loops with exit-statements (cf. e.g. =-=[4]-=-). Determining the number of iterations of a for-loop is trivial. For example the loop-body of the loop for i in 1..N loop -- loop body end loop; is performed exactly N times. Even nested loops do not... |

1 |
An axiomatic basis for computer progrsmmlng
- Hoare
- 1969
(Show Context)
Citation Context ...gherlevel languages has been introduced in [8]. So-called schemas are used to estimate the best and worst case performance of statements of higher-level languages and an extension of Hoare logic (cf. =-=[9]-=-) is employed to prove the timeliness (and correctness) of real-time programs. The method is also able to handle certain real-time language constructs such as delays and time-outs. Although Hoare logi... |