简体   繁体   English

古斯塔夫森定律想论证什么?

[英]What is Gustafson's law trying to argue?

Gustafson's law is a counter to Amdahl's law claiming that most parallel processing applications actually increase the workload when having increased access to parallel processing. Gustafson 定律与 Amdahl 定律相反,后者声称大多数并行处理应用程序在增加对并行处理的访问权限时实际上会增加工作量。 Thus, Amdahl's law which assumes constant workload to measure speedup is a poor method for determining benefits from parallel processing.因此,阿姆达尔定律假设恒定的工作负载来衡量加速比,这是一种用于确定并行处理收益的糟糕方法。

However, I'm confused as to what exactly Gustafson is trying to argue.然而,我对古斯塔夫森到底想争论什么感到困惑。

For example, say I take Gustafson's law and apply it to a sequential processor and two parallel processors:例如,假设我采用 Gustafson 定律并将其应用于一个顺序处理器和两个并行处理器:

I generate a workload to run on parallel processor #1.我生成了一个在并行处理器 #1 上运行的工作负载。 It takes 1 second to execute on the parallel processor and takes 10 seconds to execute on the sequential processor.在并行处理器上执行需要 1 秒,在顺序处理器上执行需要 10 秒。

I generate a bigger workload and run it on parallel processor #2.我生成了更大的工作负载并在并行处理器 #2 上运行它。 It takes 1 second to execute on the parallel processor and takes 50 seconds to execute on the sequential processor.在并行处理器上执行需要 1 秒,在顺序处理器上执行需要 50 秒。

For each workload, there is a speedup relative to the sequential processor.对于每个工作负载,相对于顺序处理器都有一个加速。 However, this doesn't seem to violate Amdahl's law since there is still some upper speedup limit for each workload.然而,这似乎并不违反阿姆达尔定律,因为每个工作负载仍然有一些加速上限。 All this is doing is varying the workload such that the "serial only" portion of the code is likely reduced.所有这些都是改变工作量,从而可能减少代码的“仅串行”部分。 As per Amdahl's law, decreasing the serial only portion will increase the speed-up limit.根据阿姆达尔定律,减少仅串行部分将增加加速限制。

So I'm confused, Gustafson's law which advocates for increasing the workload and maintain constant execution time doesn't seem to add any new information.所以我很困惑,主张增加工作量并保持恒定执行时间的古斯塔夫森定律似乎没有添加任何新信息。

What exactly is Gustafson arguing?古斯塔夫森到底在争论什么? And specifically, what does "scaled-speedup" even mean?具体来说,“缩放加速”甚至意味着什么?

Gustafson's law is a counter to Amdahl's law claiming that most parallel processing applications actually increase the workload when having increased access to parallel processing. Gustafson 定律与 Amdahl 定律相反,后者声称大多数并行处理应用程序在增加对并行处理的访问权限时实际上会增加工作量。 Thus, Amdahl's law which assumes constant workload to measure speedup is a poor method for determining benefits from parallel processing.因此,阿姆达尔定律假设恒定的工作负载来衡量加速比,这是一种用于确定并行处理收益的糟糕方法。

No.不。

First of all, the two laws are not claiming anything.首先,这两项法律都没有要求任何东西。 They show the theoretical (maximum) speed-up an application can get based on a specific configuration.它们显示了应用程序基于特定配置可以获得的理论(最大)加速。 The two are basic mathematical formula modelling the behaviour of a parallel algorithm.这两个是模拟并行算法行为的基本数学公式。 They goals is to understand some limitations of parallel computing (Amdahl's law) and what developers can do to overcomes them (Gustafson's law).他们的目标是了解并行计算的一些限制(阿姆达尔定律)以及开发人员可以采取哪些措施来克服这些限制(古斯塔夫森定律)。

The Amdahl's law is a mathematical formula describing the theoretical speed-up of an application with a variable-time given workload (but the amount of computation is fixed) computed by several processing units.阿姆达尔定律是一个数学公式,描述了由多个处理单元计算的具有可变时间给定工作负载(但计算量是固定的)的应用程序的理论加速。 The workload contains a serial execution part and a parallel one.工作负载包含一个串行执行部分和一个并行执行部分。 It shows that the speed-up is bounded by the portion of serial portion of the program.它表明加速受到程序串行部分的限制。 This is not great for developers of parallel applications since this means that the scalability of their application will be quite bad for some rather-sequential workload assuming the workload is fixed .这对并行应用程序的开发人员来说不是很好,因为这意味着假设工作负载是固定的,他们的应用程序的可伸缩性对于一些相当顺序的工作负载来说将是非常糟糕的。

The Gustafson's law break this assumption and add a new one to look at the problem differently.古斯塔夫森定律打破了这一假设,并添加了一个新的假设,以不同的方式看待问题。 Indeed, the mathematical formula describes the theoretical speed-up of an application with a fixed-time workload (but the amount of computation is variable) computed by several processing units.实际上,数学公式描述了具有固定时间工作负载(但计算量是可变的)的应用程序的理论加速,该工作负载由多个处理单元计算。 It shows that the speed-up can be good as long as application developers can add more parallel work to a given workload.它表明只要应用程序开发人员可以为给定的工作负载添加更多并行工作,加速就可以很好。

I generate a workload to run on parallel processor #1.我生成了一个在并行处理器 #1 上运行的工作负载。 It takes 1 second to execute on the parallel processor and takes 10 seconds to execute on the sequential processor.在并行处理器上执行需要 1 秒,在顺序处理器上执行需要 10 秒。 I generate a bigger workload and run it on parallel processor #2.我生成了更大的工作负载并在并行处理器 #2 上运行它。 It takes 1 second to execute on the parallel processor and takes 50 seconds to execute on the sequential processor.在并行处理器上执行需要 1 秒,在顺序处理器上执行需要 50 秒。

A parallel program cannot be more than 2 time faster with 2 processing unit compared to one processing unit with these two models.与使用这两种模型的一个处理单元相比,具有 2 个处理单元的并行程序的速度不能超过 2 倍。 This is possible in practice due to some confounding factors (typically due to cache-effects) but the effect do not uniquely come from the processing units.由于一些混杂因素(通常是由于缓存效应),这在实践中是可能的,但这种效应并非唯一来自处理单元。 What do you means by "two parallel processors"? “两个并行处理器”是什么意思? The number of processing units is missing in your example (unless you want to find it from the provided informations).您的示例中缺少处理单元的数量(除非您想从提供的信息中找到它)。

So I'm confused, Gustafson's law which advocates for increasing the workload and maintain constant execution time doesn't seem to add any new information.所以我很困惑,主张增加工作量并保持恒定执行时间的古斯塔夫森定律似乎没有添加任何新信息。

The two laws are like two point-of-views of the same scalability problem.这两条定律就像是同一可扩展性问题的两种观点。 However, they make different assumptions: fixed amount of work with a variable work time VS variable amount of work with a fixed work time.然而,他们做出了不同的假设:固定工作量和可变工作时间VS可变工作量和固定工作时间。

If you are familiar with the concepts of strong/weak scaling, please note that the Amdahl's law is to the strong scaling what the Gustafson's law is to the weak scaling .如果您熟悉强/弱缩放的概念,请注意阿姆达尔定律对强缩放的作用就像古斯塔夫森定律对弱缩放的作用一样

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM