Program-Counter-Based Prediction Techniques in Operating Systems


Overview of PCOS

Program instructions uniquely identified by their program counters (PCs) provide a convenient and accurate means of recording the context of program execution and PC-based prediction techniques have been widely used for performance optimizations at the architectural level. Operating systems, on the other hand, have not fully explored the benefits of PC-based prediction for resource management. This research explores the potential benefits provided by PC-based prediction in operating systems (PCOS). In particular, we investigate the potential of using PC-based prediction techniques for managing I/O devices in operating systems.

As a first demonstration of PCOS, we developed a PC-based access pattern classification (PCC) technique for buffer cache management. PCC allows the operating system to correlate the I/O operations with the program context in which they are issued via the PCs of the call instructions that trigger the I/O requests. This correlation allows the operating system to classify I/O access pattern on a per-call-site basis which achieves significantly better accuracy than previous per-file or per-application classification techniques.

We have also developed a PC-based technique (PCAP) for power management that dynamically learns the application I/I access patterns and associated disk idle times to predict when an I/O device can be shut down to save energy. PCAP uses path-based correlation to observe a particular sequence of I/O triggering instructions leading to each idle period, and accurately predicts future occurrences of that idle period.

We are current investigating other areas of resource management and allocation in operating systems where the PCOS principle can be exploited, such as I/O prefetching, energy management for processors and other devices.