In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-20 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article will explain in detail the example analysis of By Amdahl's law to improve the performance of the system after optimization. The editor thinks it is very practical, so I share it with you for reference. I hope you can get something after reading this article.
After the completion of the system optimization, how do we evaluate the effect of the optimization? The simplest way is to measure the ratio of time spent after optimization to that before optimization, which is also called acceleration ratio S (Speed Up).
Amdahl's law has important guiding significance in understanding performance optimization. Before optimization, the total system time is To (old), and after optimization, the total time is Tn (new), and the speedup is S=To/Tn.
Understand through the following picture: (α is the original time-consuming ratio of the part to be increased)
S = To/Tn = 1 / (1-α) + α / k
When the speed of the part to be optimized is increased infinitely (k is close to infinity and does not take time), S = 1 / (1-α), that is, for example, α = 60%, if 60% of the system can be speeded up so that it does not take time, then the highest speedup is still only 1max 0.4 / 2.5, and the system can speed up 2.5 times. This is the main point of Amdahl's law: to significantly accelerate the entire system, you must increase most of the speed of the whole system.
When we describe parallel programs, ideally, as the number of cpu cores increases, the expected run time will decrease linearly. In other words, if the expected number of threads is doubled, the running time will be halved.
As shown in the figure:
The actual situation:
Ideal:
The key indicator of performance improvement is the speedup, the old time / new time, as the thread increases, the time corresponding decreases, in fact, as the thread increases, the running time may increase because of the overhead of thread context switching.
This is the end of this article on "example analysis of By Amdahl's law for improving system performance after optimization". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.