多核技术摘要

简介:
多核技术虽然在性能上比传统的uniprocessiing优越,但是在设计上有很多挑战。几个很明显的问题包括如何将不同应用负载到多cpu的问题和资源调度共享问题等等。诸如这些问题的考虑,多核设计上出现了AMP、SMP以及BMP架构。
Asymmetric multiprocessing (AMP):
clip_image001
A separate OS, or a separate instantiation of the same OS, runs on each CPU.
Some systems use asymmetric multiprocessing, in which each processor is assigned a specific task. A master processor controls the system; the other processors either look to the master for instruction or have predefined tasks. The scheme defines a master-slave relationship. The master processor schedules and allocates work to the slave processors.
With AMP, you decide how the shared hardware resources used by applications are divided up between the CPUs. Normally, this resource allocation occurs statically during boot time and includes physical memory allocation, peripheral usage, and interrupt handling. While the system could allocate the resources dynamically, doing so would entail complex coordination between the CPUs.
In an AMP system, a process always runs on the same CPU, even when other CPUs run idle. As a result, one CPU can end up being under- or overutilized. To address the problem, the system could allow applications to migrate dynamically from CPU to another. Doing so, however, can involve complex checkpointing of state information or a possible service interruption as the application is stopped on one CPU and restarted on another. Also, such migration is difficult, if not impossible, if the CPUs run different OSs.
Symmetric multiprocessing (SMP):
clip_image002
A single instantiation of an OS manages all CPUs simultaneously, and applications can float to any of them.
The most common systems use symmetric multiprocessing (SMP), in which each processor performs all tasks within the operating system. SMP means that all processors are peers; no master-slave relationship exists between processors.SMP(symmetric multiprocessing)is the processing of programs by multiple processors that share a common operating system and memory. In symmetric (or "tightly coupled") multiprocessing, the processors share memory and the I/O bus or data path. A single copy of the operating system is in charge of all the processors. SMP, also known as a "shared everything" system, does not usually exceed 16 processors.
Symmetric multiprocessing addresses the issue by running only one copy of Neutrino on all of the system's CPUs. Because the OS has insight into all system elements at all times, it can allocate resources on the multiple CPUs with little or no input from the application designer.
Bound multiprocessing (BMP):
A single instantiation of an OS manages all CPUs simultaneously, but each application is locked to a specific CPU.
As with SMP, a single copy of the OS maintains an overall view of all system resources, allowing them to be dynamically allocated and shared among applications. But, during application initialization, a setting determined by the system designer forces all of an application's threads to execute only on a specified CPU.
Compared to full, floating SMP operation, this approach offers several advantages:
  • It eliminates the cache thrashing that can reduce performance in an SMP system by allowing applications that share the same data set to run exclusively on the same CPU.
  • It offers simpler application debugging than SMP since all execution threads within an application run on a single CPU.
  • It helps legacy applications that use poor techniques for synchronizing shared data to run correctly, again by letting them run on a single CPU.
 
The most difference between AMP, SMP, and BMP as bellow:
  • AMP works well with legacy applications, but has limited scalability beyond two CPUs.
  • SMP offers transparent resource management, but software that hasn't been properly designed for concurrency might have problems.
  • BMP offers many of the same benefits as SMP, but guarantees that uniprocessor applications will behave correctly, greatly simplifying the migration of legacy software.









本文转自 chris_lee 51CTO博客,原文链接:http://blog.51cto.com/ipneter/369782,如需转载请自行联系原作者

目录
相关文章
|
编解码 网络安全 CDN
使用cdn为github pages加速
第一次使用cdn
2951 0
如何用限制立方样条(RCS)做生存分析?
如何用限制立方样条(RCS)做生存分析?
1859 0
如何用限制立方样条(RCS)做生存分析?
|
网络安全
DDoS防护中的全力防护、弹性防护、高级防护和全局高级防护是指什么?
DDoS防护中的全力防护、弹性防护、高级防护和全局高级防护是指什么?
850 0
|
机器学习/深度学习 人工智能 人机交互
微软开源可解释机器学习工具包lnterpretML
当人工智能系统能够影响人类生活时,人们对它的行为理解是非常重要的。
614 0
科创板7天受理28家公司,但后者“含金量”备受质疑
受理名单中,一些公司的核心技术水平、行业地位以及可持续发展等均受到了质疑。
818 0
|
监控 Java API
看大牛是如何使用和理解线程池
  前言 平时接触过多线程开发的童鞋应该都或多或少了解过线程池,之前发布的《阿里巴巴 Java 手册》里也有一条:   可见线程池的重要性。
1251 0
|
监控 关系型数据库 MySQL
解决mysqld无法启动的记录
服务器重启后,mysqld无法启动,启动命令是:service mysqld start mysql的错误日志如下图: mysql错误日志 日志中显示了两个错误,一是:Permission denied;二是:可能有一个mysqld服务器运行在3330端口了; netstat -tunlp 也没有看到3330端口在运行: image.png ps aux | grep mysql 也没有mysql相关进程在运行: image.png 这就将第二种错误排除了。
2857 0
|
JSON 前端开发 JavaScript