-- Performers.mesa -- Edited by Paul Rovner on 7-Jan-82 15:57:49 DIRECTORY Plotter USING [Create], RealEvent USING [CreateTimerDrivenStream], RTProcess USING [StartWatchingFaults, GetTotalPageFaults], SafeStorage USING [NWordsAllocated], Timer USING[Seconds]; Performers: PROGRAM IMPORTS Plotter, RealEvent, RTProcess, SafeStorage = BEGIN samplingInterval: Timer.Seconds = 5; nEvents: NAT = 100; -- SAMPLING PROCEDURES WordsAllocatedSampler: PROC[s: REF ANY] RETURNS[REAL] = {RETURN[SafeStorage.NWordsAllocated[]]; }; PageFaultSampler: PROC[s: REF ANY] RETURNS[REAL] = {RETURN[RTProcess.GetTotalPageFaults[]]; }; -- START HERE...Create performance plotters [] ← Plotter.Create[label: "wordsPerSecHistory", autoRepaint: TRUE, nEvents: nEvents, plotValueDifferences: TRUE, plotValuePerSecond: TRUE, eventSource: RealEvent.CreateTimerDrivenStream[interval: samplingInterval, sampler: WordsAllocatedSampler]]; [] ← Plotter.Create[label: "pageFaultsPerSecHistory", autoRepaint: TRUE, nEvents: nEvents, plotValueDifferences: TRUE, plotValuePerSecond: TRUE, eventSource: RealEvent.CreateTimerDrivenStream[interval: samplingInterval, sampler: PageFaultSampler]]; RTProcess.StartWatchingFaults[]; END.