Considering the Frequency Dimension into on Demand Adaptive Algorithms Jacinto C. A. Cansado University of São Paulo São Paulo, Brazil jacinto.cansado@poli.usp.br João H. S. Pereira University of São Paulo São Paulo, Brazil joaohs@usp.br Edson T. Midorikawa University of São Paulo São Paulo, Brazil edson.midorikawa@poli.usp.br ABSTRACT Efficient memory usage in high performance timesharing computing systems is a considerable challenge. Some re- search areas on adaptive algorithms concerning memory page replacement, analyze the memory access behavior seeking to store the pages that will be used in a near future and discarding the others. This is important due to the high cost of treating page faults. The proposal is to analyze the influence of page access frequency on adaptive algorithms, using its structure and applying page replacement with ac- cess frequency analysis, as a function of its execution state. The comparative performance analysis is conducted by using trace files that represent different memory access behaviors. Categories and Subject Descriptors D.4.2 [Operating System]: Storage Management - Vir- tual memory; D.4.8 [Operating System]: Performance - Modeling and prediction, simulation General Terms Algorithms, Management, Performance Keywords Adaptive replacement algorithm, demand paging, page ac- cess frequency, virtual memory 1. INTRODUCTION The use of virtual memory provides the execution of pro- cesses without being fully loaded in memory, thus allowing only the program sections being executed at an instant to reside in it [12]. This technique allows the memory to be shared by different processes with unforeseeable access pat- terns, hindering the development of a single efficient page re- placement algorithm that explores the time and space char- acteristics of each process individually. The replacement policy adopted has a marked influence on the computational system performance; therefore, efficient replacement policies are being researched and developed. According to Midorikawa [9], the use of an efficient page replacement policy is critically relevant for an operating sys- tem to execute tasks requiring high performance. The Optimum page replacement algorithm is the one with the best performance, yet it is not implementable in a real system due to the impossibility of previously knowing which page loaded in the memory will take the longest to be used, thus being liable to replacement. Since this is not possible to predict, some approximations are proposed, such as the algorithms widely used by mod- ern operating systems that somehow access the recent past to foresee the near future. As an example, there is LRU (Least Recently Used) algorithm, which replaces the page residing in the memory accessed longer ago, that is, the algorithm replaces the page that has been residing in the memory the longest without being accessed, and which thus has low probability of being accessed in a near future. As stated by Cassettari and Midorikawa [2], this algorithm is more efficient when compared to other traditional algo- rithms, such as FIFO (First In, First Out), which replaces the page loaded the longest, the MRU (Most Recently Used), which replaces the most recently accessed page and the LFU (Least Frequently Used), which replaces the least accessed page. Although the LRU algorithm is the most used because of its efficiency and simplicity, there are situations in which it provenly presents deficiencies [5]. Some examples are: a) sequential accesses in a large number of pages located in distinct memory addresses; b) access within large loops, leading to the access of many pages by iteration; and, c) irregular, unpredictable access frequency for the same page. The aim here is to present a proposal for page access fre- quency analysis, by introducing of the assessment of page reuse frequency in the replacement criterion. The proposal is based on the use of adaptive structure and the applica- tion of page replacement with access frequency analysis as a function of the adaptive execution state. This work is organized as follows. Section 2 presents some adaptive page replacement algorithms listing some of their characteristics. Section 3 describes the adaptation proposal for the page access frequency detection. The analysis of the simulation results and of the performance assessment are 110