google云计算系列课程第一讲介绍PPT课件下载推荐.ppt
- 文档编号:14290255
- 上传时间:2022-10-21
- 格式:PPT
- 页数:37
- 大小:842KB
google云计算系列课程第一讲介绍PPT课件下载推荐.ppt
《google云计算系列课程第一讲介绍PPT课件下载推荐.ppt》由会员分享,可在线阅读,更多相关《google云计算系列课程第一讲介绍PPT课件下载推荐.ppt(37页珍藏版)》请在冰豆网上搜索。
GFS2Theoretical:
AlgorithmsfordistributedcomputingReadings+QuestionsnightlyReadings:
http:
/http:
/,Outline,IntroductiontoDistributedComputingParallelvs.DistributedComputingHistoryofDistributedComputingParallelizationandSynchronizationNetworkingBasics,ComputerSpeedup,MooresLaw:
“Thedensityoftransistorsonachipdoublesevery18months,forthesamecost”(1965),Image:
TomsHardwareandnotsubjecttotheCreativeCommonslicenseapplicabletotherestofthiswork.,Image:
TomsHardware,Scopeofproblems,Whatcanyoudowith1computer?
Whatcanyoudowith100computers?
Whatcanyoudowithanentiredatacenter?
Distributedproblems,Renderingmultipleframesofhigh-qualityanimation,Image:
DreamWorksAnimationandnotsubjecttotheCreativeCommonslicenseapplicabletotherestofthiswork.,Distributedproblems,Simulatingseveralhundredorthousandcharacters,HappyFeetKingdomFeatureProductions;
LordoftheRingsNewLineCinema,neitherimageissubjecttotheCreativeCommonslicenseapplicabletotherestofthework.,Distributedproblems,Indexingtheweb(Google)SimulatinganInternet-sizednetworkfornetworkingexperiments(PlanetLab)Speedingupcontentdelivery(Akamai),Whatisthekeyattributethatalltheseexampleshaveincommon?
Parallelvs.Distributed,Parallelcomputingcanmean:
VectorprocessingofdataMultipleCPUsinasinglecomputerDistributedcomputingismultipleCPUsacrossmanycomputersoverthenetwork,ABriefHistory1975-85,ParallelcomputingwasfavoredintheearlyyearsPrimarilyvector-basedatfirstGraduallymorethread-basedparallelismwasintroduced,Image:
ComputerPicturesDatabaseandCrayResearchCorpandisnotsubjecttotheCreativeCommonslicenseapplicabletotherestofthiswork.,“Massivelyparallelarchitectures”startrisinginprominenceMessagePassingInterface(MPI)andotherlibrariesdevelopedBandwidthwasabigproblem,ABriefHistory1985-95,ABriefHistory1995-Today,Cluster/gridarchitectureincreasinglydominantSpecialnodemachineseschewedinfavorofCOTStechnologiesWeb-wideclustersoftwareCompanieslikeGoogletakethistotheextreme,Parallelization&
Synchronization,ParallelizationIdea,Parallelizationis“easy”ifprocessingcanbecleanlysplitintonunits:
ParallelizationIdea
(2),Inaparallelcomputation,wewouldliketohaveasmanythreadsaswehaveprocessors.e.g.,afour-processorcomputerwouldbeabletorunfourthreadsatthesametime.,ParallelizationIdea(3),ParallelizationIdea(4),ParallelizationPitfalls,Butthismodelistoosimple!
Howdoweassignworkunitstoworkerthreads?
Whatifwehavemoreworkunitsthanthreads?
Howdoweaggregatetheresultsattheend?
Howdoweknowalltheworkershavefinished?
Whatiftheworkcannotbedividedintocompletelyseparatetasks?
Whatisthecommonthemeofalloftheseproblems?
ParallelizationPitfalls
(2),Eachoftheseproblemsrepresentsapointatwhichmultiplethreadsmustcommunicatewithoneanother,oraccessasharedresource.Goldenrule:
Anymemorythatcanbeusedbymultiplethreadsmusthaveanassociatedsynchronizationsystem!
WhatisWrongWithThis?
Thread1:
voidfoo()x+;
y=x;
Thread2:
voidbar()y+;
x+=3;
Iftheinitialstateisy=0,x=6,whathappensafterthesethreadsfinishrunning?
Multithreaded=Unpredictability,Whenwerunamultithreadedprogram,wedontknowwhatorderthreadsrunin,nordoweknowwhentheywillinterruptoneanother.,Thread1:
voidfoo()eax=memx;
inceax;
memx=eax;
ebx=memx;
memy=ebx;
voidbar()eax=memy;
memy=eax;
eax=memx;
addeax,3;
Manythingsthatlooklike“onestep”operationsactuallytakeseveralstepsunderthehood:
Multithreaded=Unpredictability,Thisappliestomorethanjustintegers:
PullingworkunitsfromaqueueReportingworkbacktomasterunitTellinganotherthreadthatitcanbeginthe“nextphase”ofprocessingAllrequiresynchronization!
SynchronizationPrimitives,Asynchronizationprimitiveisaspecialsharedvariablethatguaranteesthatitcanonlybeaccessedatomically.Hardwaresupportguaranteesthatoperationsonsynchronizationprimitivesonlyevertakeonestep,Semaphores,AsemaphoreisaflagthatcanberaisedorloweredinonestepSemaphoreswereflagsthatrailroadengineerswouldusewhenenteringasharedtrack,Onlyonesideofthesemaphorecaneverbered!
(Canbothbegreen?
),Semaphores,set()andreset()canbethoughtofaslock()andunlock()Callstolock()whenthesemaphoreisalreadylockedcausethethreadtoblock.Pitfalls:
Must“bind”semaphorestoparticularobjects;
mustrememberto
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- google 计算 系列 课程 第一 介绍