古斯塔夫森定律
通过扩大问题规模,可以在并行处理系统中获得显著加速。
显示原始英文内容
Gustafson's Law
It is possible to achieve significant speedup in parallel processing by increasing the problem size.
Takeaways
- As computing resources grow, you can compute more problems in a given time, rather than solving the same issues faster.
- It opposes the pessimism of Amdahl's Law by assuming the size of the problem to be solved will increase proportionally with computing power, so that parallel processors remain busy.
- Practically, Gustafson's Law promotes the use of more resources in computation to achieve more in terms of the scope of tasks, rather than obtaining diminishing returns.
- Software should be designed to scale out: as more cores or machines are added, the problem size grows and the extra capacity does useful work.
Overview
Gustafson's Law is a principle in parallel computing that offers an optimistic view of scalability. Where Amdahl's Law assumes a fixed problem size and concludes that speedup is limited by serial work, Gustafson's Law changes the perspective.
It observes that when more processors are available, developers tend to increase the problem size to use that extra power. If you have a cluster twice as powerful, you might process twice as much data in the same time.
The parallel portion of work grows with N processors while the serial portion remains about the same, leading to "scaled speedup" that can be almost linear.
Gustafson's insight is that developers naturally use more computing power by asking bigger questions.
Examples
In high-performance computing, climate modeling or molecular simulations routinely increase model resolution when more processors are available. A weather simulation on 1000 CPUs won't just finish 1000x faster; instead, they run a far more detailed global model in the same time, yielding a better forecast.
In big data processing, if analyzing 1 million records takes an hour on one machine, a 10-machine cluster might analyze 10 million records in an hour instead of finishing in 6 minutes.
Modern distributed systems like MapReduce and Spark encourage splitting datasets into more partitions as nodes increase, keeping all processors busy.
Origins
Gustafson's Law was formulated by computer scientist John L. Gustafson (with Edwin Barsis) in 1988, in a paper titled "Reevaluating Amdahl's Law." Gustafson was working at Sandia National Laboratories on high-performance computing.
At that time, Amdahl's 1967 result cast doubt on massively parallel supercomputers. Gustafson observed that this held only if workload was kept constant. His 1988 argument demonstrated that by increasing problem size, a 1024-processor system could achieve near-1024x speedup on suitably scaled tasks.
核心含义
阿姆达尔定律关注固定大小的任务,而实际工作中往往会在获得更多资源后处理更大的数据集、更高的分辨率或更多用户。此时并行部分的价值会增加,串行部分占总时间的比例可能下降。
扩展系统时要同时问:同样的任务能快多少,以及我们能否用新增资源完成更大的任务。
实践例子
图像处理服务增加机器后,不只是更快处理同样的图片,还可以在同样时间内处理更高分辨率或更多用户请求,这就是扩大问题规模带来的收益。
来源与边界
John Gustafson 提出这一视角来补充阿姆达尔定律。它不消除串行瓶颈,也不替代对成本、通信和数据分布的实际测量。