資源描述:
《The Memory System-II.pdf》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在學(xué)術(shù)論文-天天文庫(kù)。
1、SFTW230:SystemsandNetworksIComputerOrganizationTopicscovered:Chapter5.TheMemorySystem(II)Dr.WUWen,FST,UMOutline?Interleavingmemoryaccessacrossmemorymodules?Virtualmemories?Secondarystoragedevices15.6.1Interleaving?Themainmemoryisstructuredasacollectionofphy
2、sicallyseparatemodules.Eachmodulehasitsownaddressanddatabufferregister(ABR&DBR).……Mainmemory?Wehopetheaddressoffetchingdatacanbeevenlydistributed-->severalmodulesarekeptbusyduringtheexecutionprocess.Thisiscalled“interleavingmemoryaccesses”acrossseveralmemor
3、ymodules.2Interleaving?Howtolettheaddressesdistributeoverthemodules??Twopossibleaddresslayouts.?Whichschemebelowcanbeinterleaved??Interleavingmemoryaccessescanhideaccesslatency?FasteraccesstoablockofdataIninterleaved?Higheraverageuseofthememorysystemstructu
4、re,theremustbe2kmodules.3Example:theeffectofinterleavingissubstantial?Supposewehaveacachewith8words/blockOnareadmiss,weneedtoloadablockofdatafrommainmemory.What’sthetimeneeded??Ittakes1clockcycletosendanaddresstothemainmemoryandonetosendbacktocache.DRAMallo
5、wsthefirstwordtobeaccessedin8cycles,andsubsequentwordsoftheblockareaccessedin4cyclesperwordA.Forsinglememorymodule:1+8+(7x4)+1=38cyclesprocessorcachememory4Example:theeffectofinterleavingissubstantialB.Forinterleavedscheme,thememoryisconstructedas4interleav
6、edmodules?Sendaddresses(1),all4modulesaccesstherequireddata(8cycles)?Transferback(4cycles),atthesametime,thenextwordineachmoduleisaccessed?4cyclestotransferthemtocache1+8+4+4=17cycles.181181181Interleavingreduces181theblocktransfertime141bymorethanafactor14
7、1141of2.14155.7Virtualmemories?Virtualmemorytechnique?Themainmemorycanactasa“cache”forthesecondarystorage(magneticdisks).?Thephysicalmainmemoryinacomputerislimited?Alargeprogram?Itcannotcompletelyloadintothemainmemorytorunatonce.?Partsarestoredonsecondaryst
8、orage.?Whenanewpieceofaprogramistobetransferredintothemainmemory–Mainmemoryisfull->Someotherpiecemustbereplaced?Thenalleventuallyarebroughtintothemainmemory(usingDMA)asneeded?Operatingsystemautomatical