Predictable Paging in Real-Time Systems: A Compiler Approach

Conventionally, the use of virtual memory in real-time systems has been avoided, the main reason being the difficulties it provides to timing analysis. However, there is a trend towards systems where different functions are implemented by concurrent processes. Such systems need spatial separation between processes, which can be easily implemented via the use of the memory management unit (MMU) of commercial processors. In addition, some systems have a limited amount of physical memory available. So far, attempts to provide real-time address spaces have focused on the predictability of virtual to physical address translation and do not implement demand-paging. In this paper we propose a compiler approach to introduce a predictable form of paging, in which page-in and page-out points are selected at compile-time. The problem under study can be formulated as a graph coloring problem, as in register allocation within compilers. Since the graph coloring problem is NP-complete for more than three colors, we define a heuristic, which in contrast to those used for register allocation, aim at minimizing worst-case performance instead of average-case performance. Experimental results applied on tasks code show that predictability does not come at the price of performance loss as compared to standard (dynamic) demand paging.

[1]  Hideyuki Tokuda,et al.  Real-Time Mach: Towards a Predictable Real-Time System , 1990, USENIX MACH Symposium.

[2]  Laszlo A. Belady,et al.  A Study of Replacement Algorithms for Virtual-Storage Computer , 1966, IBM Syst. J..

[3]  Douglas Niehaus Program representation and execution in real-time multiprocessor systems , 1994 .

[4]  Lin Gao,et al.  Memory coloring: a compiler approach for scratchpad memory management , 2005, 14th International Conference on Parallel Architectures and Compilation Techniques (PACT'05).

[5]  Ben H. H. Juurlink,et al.  Approximating the optimal replacement algorithm , 2004, CF '04.

[6]  Henrik Theiling,et al.  Reliable and Precise WCET Determination for a Real-Life Processor , 2001, EMSOFT.

[7]  R. J. Pankhurst Operating Systems: Program overlay techniques , 1968, CACM.

[8]  Reinhard Wilhelm,et al.  The influence of processor architecture on the design and the results of WCET tools , 2003, Proceedings of the IEEE.

[9]  Frank Müller,et al.  Timing Analysis for Instruction Caches , 2000, Real-Time Systems.

[10]  Alan Burns,et al.  Guest Editorial: A Review of Worst-Case Execution-Time Analysis , 2000, Real-Time Systems.

[11]  Neil C. Audsley,et al.  Predictable and efficient virtual addressing for safety-critical real-time systems , 2001, Proceedings 13th Euromicro Conference on Real-Time Systems.

[12]  Jay K. Strosnider,et al.  A Dynamic Programming Algorithm for Cache/Memory Partitioning for Real-Time Systems , 1993, IEEE Trans. Computers.

[13]  Isabelle Puaut,et al.  A modular and retargetable framework for tree-based WCET analysis , 2001, Proceedings 13th Euromicro Conference on Real-Time Systems.

[14]  Gregory J. Chaitin,et al.  Register allocation and spilling via graph coloring , 2004, SIGP.