A Coordinated Approach for Practical OS-Level Cache Management in Multi-core Real-Time Systems

Many modern multi-core processors sport a large shared cache with the primary goal of enhancing the statistic performance of computing workloads. However, due to resulting cache interference among tasks, the uncontrolled use of such a shared cache can significantly hamper the predictability and analyzability of multi-core real-time systems. Software cache partitioning has been considered as an attractive approach to address this issue because it does not require any hardware support beyond that available on many modern processors. However, the state-of-the-art software cache partitioning techniques face two challenges: (1) the memory co-partitioning problem, which results in page swapping or waste of memory, and (2) the availability of a limited number of cache partitions, which causes degraded performance. These are major impediments to the practical adoption of software cache partitioning. In this paper, we propose a practical OS-level cache management scheme for multi-core real-time systems. Our scheme provides predictable cache performance, addresses the aforementioned problems of existing software cache partitioning, and efficiently allocates cache partitions to schedule a given task set. We have implemented and evaluated our scheme in Linux/RK running on the Intel Core i7 quad-core processor. Experimental results indicate that, compared to the traditional approaches, our scheme is up to 39% more memory space efficient and consumes up to 25% less cache partitions while maintaining cache predictability. Our scheme also yields a significant utilization benefit that increases with the number of tasks.

[1]  Zhao Zhang,et al.  Gaining insights into multicore cache partitioning: Bridging the gap between simulation and real systems , 2008, 2008 IEEE 14th International Symposium on High Performance Computer Architecture.

[2]  Ragunathan Rajkumar,et al.  Shared-Page Management for Improving the Temporal Isolation of Memory Reservations in Resource Kernels , 2012, 2012 IEEE International Conference on Embedded and Real-Time Computing Systems and Applications.

[3]  Chang-Gun Lee,et al.  Bounding Cache-Related Preemption Delay for Real-Time Systems , 2001, IEEE Trans. Software Eng..

[4]  Ragunathan Rajkumar,et al.  Linux/RK: A Portable Resource Kernel in Linux , 2005 .

[5]  Isabelle Puaut,et al.  PDPA: period driven task and cache partitioning algorithm for multi-core systems , 2012, RTNS '12.

[6]  Sangyeun Cho,et al.  Managing Distributed, Shared L2 Caches through OS-Level Page Allocation , 2006, 2006 39th Annual IEEE/ACM International Symposium on Microarchitecture (MICRO'06).

[7]  Wang Yi,et al.  Cache-aware scheduling and analysis for multicores , 2009, EMSOFT '09.

[8]  Kai Li,et al.  The PARSEC benchmark suite: Characterization and architectural implications , 2008, 2008 International Conference on Parallel Architectures and Compilation Techniques (PACT).

[9]  Kelvin D. Nilsen,et al.  Cache Issues in Real-Time Systems , 1994 .

[10]  David K. Tam,et al.  Managing Shared L2 Caches on Multicore Systems in Software , 2007 .

[11]  Shuichi Oikawa,et al.  Resource kernels: a resource-centric approach to real-time and multimedia systems , 2001, Electronic Imaging.

[12]  Andy J. Wellings,et al.  Hybrid instruction cache partitioning for preemptive real-time systems , 1997, Proceedings Ninth Euromicro Workshop on Real Time Systems.

[13]  Ragunathan Rajkumar,et al.  Parallel scheduling for cyber-physical systems: Analysis and case study on a self-driving car , 2013, 2013 ACM/IEEE International Conference on Cyber-Physical Systems (ICCPS).

[14]  Xiao Zhang,et al.  Towards practical page coloring-based multicore cache management , 2009, EuroSys '09.

[15]  Ragunathan Rajkumar,et al.  Energy-aware memory firewalling for QoS-sensitive applications , 2005, 17th Euromicro Conference on Real-Time Systems (ECRTS'05).

[16]  Chung Laung Liu,et al.  Scheduling Algorithms for Multiprogramming in a Hard-Real-Time Environment , 1989, JACM.

[17]  Oded Lempel,et al.  2nd Generation Intel® Core Processor Family: Intel® Core i7, i5 and i3 , 2011, 2011 IEEE Hot Chips 23 Symposium (HCS).

[18]  Andrew Wolfe,et al.  Software-based cache partitioning for real-time applications , 1994 .

[19]  Balaram Sinharoy,et al.  POWER4 system microarchitecture , 2002, IBM J. Res. Dev..

[20]  Lui Sha,et al.  Optimizing Tunable WCET with Shared Resource Allocation and Arbitration in Hard Real-Time Multicore Systems , 2011, 2011 IEEE 32nd Real-Time Systems Symposium.

[21]  Francisco J. Cazorla,et al.  Hardware support for WCET analysis of hard real-time multicore systems , 2009, ISCA '09.

[22]  Xiaorui Wang,et al.  Cache-Aware Utilization Control for Energy Efficiency in Multi-Core Real-Time Systems , 2011, 2011 23rd Euromicro Conference on Real-Time Systems.

[23]  Robert I. Davis,et al.  Cache Related Pre-emption Delay Aware Response Time Analysis for Fixed Priority Pre-emptive Systems , 2011, RTSS.

[24]  Francisco J. Cazorla,et al.  IA^3: An Interference Aware Allocation Algorithm for Multicore Hard Real-Time Systems , 2011, 2011 17th IEEE Real-Time and Embedded Technology and Applications Symposium.

[25]  Lui Sha,et al.  Impact of Cache Partitioning on Multi-tasking Real Time Embedded Systems , 2008, 2008 14th IEEE International Conference on Embedded and Real-Time Computing Systems and Applications.

[26]  Mathai Joseph,et al.  Finding Response Times in a Real-Time System , 1986, Comput. J..

[27]  Jochen Liedtke,et al.  OS-controlled cache predictability for real-time systems , 1997, Proceedings Third IEEE Real-Time Technology and Applications Symposium.

[28]  Robert I. Davis,et al.  Integrating cache related pre-emption delay analysis into EDF scheduling , 2013, 2013 IEEE 19th Real-Time and Embedded Technology and Applications Symposium (RTAS).

[29]  Raj Rajkumar,et al.  Coordinated Cache Management for Predictable Multi-Core Real-Time Systems , 2013 .

[30]  Marco Caccamo,et al.  A Predictable Execution Model for COTS-Based Embedded Systems , 2011, 2011 17th IEEE Real-Time and Embedded Technology and Applications Symposium.