DIRECTORY AlpineEnvironment USING[PageNumber], FileMap USING[Handle], FilePageMgrPrivateChunk USING[Chunk, ChunkType, ListChunkType, RefChunk], FilePageMgrPrivateFile USING[FPMFileHandle]; FilePageMgrLru: CEDAR DEFINITIONS = BEGIN PutMappedChunkOnLruList: PROCEDURE[refChunk: FilePageMgrPrivateChunk.RefChunk, lruListPlace: LruListPlace]; LruListPlace: TYPE = {mru, lru}; PutUnmappedChunkOnLruList: PROCEDURE[refChunk: FilePageMgrPrivateChunk.RefChunk]; GetOurChunkFromLruList: PROCEDURE [refChunk: FilePageMgrPrivateChunk.RefChunk, tellSweeperToHurry: BOOLEAN]; GetOtherChunkFromLruList: PROCEDURE [chunkType: FilePageMgrPrivateChunk.ListChunkType] RETURNS[mapped: BOOLEAN, refChunk: FilePageMgrPrivateChunk.RefChunk, fileHandle: FileMap.Handle, startFilePageNumber: AlpineEnvironment.PageNumber]; RelinkChunkAsLruOnLruList: PROCEDURE[refChunk: FilePageMgrPrivateChunk.RefChunk]; UsingTooMuchOfCache: PROCEDURE[fPMFileHandle: FilePageMgrPrivateFile.FPMFileHandle] RETURNS [yes: BOOLEAN]; WaitToSweep: PROCEDURE [oldNeedToHurry: BOOLEAN, chunkType: FilePageMgrPrivateChunk.ListChunkType] RETURNS[needToHurry: BOOLEAN, sweepList: LIST OF SweepItem]; SweepItem: TYPE = RECORD[fileHandle: FileMap.Handle, startFilePageNumber: AlpineEnvironment.PageNumber]; InitializeLruLists: PROCEDURE[nChunks: ARRAY FilePageMgrPrivateChunk.ListChunkType OF NAT]; CheckCacheInCleanState: PROCEDURE RETURNS [clean: BOOLEAN]; END. Edit Log Initial: Kolling: 23-Feb-82 17:21:13: private defs file for the lru lists manager part of File Page Manager. Nodified: Hauser: February 20, 1985 3:10:03 pm PST ώFilePageMgrLru.mesa Copyright c 1985 by Xerox Corporation. All rights reserved. Last edited by: Kolling on January 24, 1984 12:58:35 pm PST Hauser, March 7, 1985 5:18:42 pm PST See FilePageMgrPrivateFile for implementation details. Things of especial note are: Mapping and unmapping do not go on while a chunk is on an lru list; therefore, the lru procedures can read Chunk.fileHandle and Chunk.startFilePageNumber. The FPMFileObject monitor must not be entered by a process holding the FilePageMgrLruImpl monitor. non system-fatal errors: none. non system-fatal errors: none. non system-fatal errors: none. non system-fatal errors: none. if unmapped, we really got it; if mapped, just returns a hint but has also moved the chunk to the mru end of the list. non system-fatal errors: none. non system-fatal errors: none. only called for normal type chunks. non system-fatal errors: none. non system-fatal errors: none. non system-fatal errors: none. Hauser, March 7, 1985 3:07:51 pm PST Added copyright Κq˜šœ™Icodešœ Οmœ1™<—šœ™Jšœ+™+K™$—J˜J˜JšΟk ˜ ˜˜Jšžœ ˜—˜Jšžœ ˜—˜Jšžœ,˜1—˜Jšžœ˜J˜J˜——Jšœžœž œ˜#J˜Jšž˜J˜JšœΤ™ΤJ˜J˜J˜šΟnœž œ,˜NJ˜šœ™Jšœžœ˜ J˜——šŸœž œ-˜QJšœ™J˜J˜—šŸœž œ-˜NJšœžœ˜Jšœ™J˜—šŸœž œ ˜/Jšœ'žœ žœ ˜IJ˜RJ˜Jšœ™Jšœv™vJ˜J˜—šŸœž œ-˜QJšœ™J˜J˜—šŸœž œ5˜SJšžœžœ˜Jšœ™Jšœ#™#—J˜J˜šŸ œž œžœ ˜;Jšœ'žœžœ˜DJšœ žœžœ ˜Jšœ™J˜—šœ žœžœ1˜IJ˜J˜J˜J˜—šŸœž œ žœ'ž˜UJšžœ˜Jšœ™J˜—šŸœž œžœ žœ˜;Jšœ™J˜J˜J˜—Jšžœ˜˜J˜J˜—J˜lJ˜2J˜J˜™$K™—K™—…—N ½