- 1、本文档共90页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
03 并行程序设计基础.ppt
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * 14 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Parallel Processing Evaluation .8 Speedup measurement formula: Elapsed time of a uniprocessor Speedup = Elapsed time of the multiprocessors * Parallel Processing Evaluation .9 For example, if the uniprocessor took 40 seconds to perform a task, and two parallel systems took 20 seconds, then the value of speedup = 40 / 20 = 2. Value 2 indicates the ideal of linear speedup: when twice as much, hardware can perform the same task in half the time. * Parallel Processing Evaluation .10 Figure. Linear and actual speedup * Parallel Processing Evaluation .11 Amdahl’s Law Amdahls Law is a law governing the speedup of using parallel processors on a problem, versus using only one sequential processor. Amdahl’s law attempts to give a maximum bound for speedup from the nature of the algorithm: Amdahl 定律 出发点: 固定不变的计算负载; 固定的计算负载分布在多个处理器上的, 增加处理器加快执行速度,从而达到加速的目的。 * Parallel Processing Evaluation .12 Amdahl’s Law S: purely sequential part P: parallel part S + P = 1 (for simplicity) Maximum speedup = S + P S + P n = 1 * * Parallel Processing Evaluation .13 Gustafson’s Law If the size of a problem is scaled up as the number of processors increases, speedup very close to the ideal speedup is possible. That is, a problem size is virtually never independent of the number of processors. * Parallel Processing Evaluation .14 Gustafson’s Law Maximum speedup = S + ( P * n ) S + P = n + (1 - n) * S Gustafson 定律 出发点: 对于很多大型计算,精度要求很高,即在此类应用中精度是个关键因素,而计算时间是固定不变的。此时为了提高精度,必须加大计算量,相应地亦必须增多处理器数才能维持时间不变; 除非学术研究,在实际应用中没有必要固定工作负载而计算程序运行在不同数目的处理器上,增多处理器必须相应地增大问题规模才有实际意义。 * Parallel Processing Evaluation .15 Exam
文档评论(0)