http://blog.csdn.net/yueyinwanchuan/article/details/17994121
multi-core processors (CMP) are the integration of multiple computing cores into a single processor chip, thereby increasing computational power. CMP can be divided into isomorphic multi-core and heterogeneous multi-core according to the equivalence of computing kernel. The computation kernel is the same, and the status equivalence is called Isomorphic multi-core. The converse is called heterogeneous multi-core.
Multi-processor
Multi-processor refers to multiple CPUs, each CPU can be single or multi-core. Although multiple CPUs are used at the same time, they behave like a single computer from a management standpoint. Symmetric multiprocessor (SMP) structure is the most popular multiprocessor structure, the system distributes task queues symmetrically on multiple CPUs, which greatly improves the data processing capability of the whole system, but the asymmetric structure is relatively rare.
The difference between multi-core development and multithreaded development
In essence, multi-core development is the use of multithreading for program development, so that the process of different functions in different cores run, or the same process of different functions of the thread on different cores run. In the past, we have studied the algorithms are single-threaded, and multi-core development to transform these algorithms to support multi-threaded algorithms, and then the system will be running the multithread distributed to multi-core processors, to achieve the acceleration of the operation.
However, unlike traditional multithreaded programming, multi-core development is simpler for synchronous locking, but it needs careful analysis of code blocks that can be computed in parallel, allowing multithreading to be parallel in one task. multithreaded development, you do not know how many physical CPUs, while for multi-core development, you must know how much of the physical CPU.
With the advent of the CPU, people will certainly associate the Pentium processor, and then recall the 286,386 and so on. The Pentium is almost synonymous with the processor, because it was only the intel that designed the High-tech gadgets. With the development of society, Pentium gradually became a history, slowly we began to accept a new word, dual-core processor.
Core Duo is a landmark product, he broke the traditional CPU operation mode, into synchronous operation, greatly increased the computational efficiency. As the dual-core concept was slowly accepted, it was later developed to four cores, until the recent release of the original four core i7 has eight logical cores of processors. Let us feel the high speed of High-tech blood flow, IT products update very fast, the cycle is very short. Only the continuous development of better performance products, can always maintain the market leading position.
Intel has said that the company will spare no effort to continue to develop its Tick-tock development strategy, every other year to launch a new chip products. Quitting a new product every other year is easier said than done, but it's actually very difficult. But due to the release of such rhetoric, on the one hand, and their own confidence in their own strength, on the other hand also showed the value of the processor market.
Tick-tock a vivid picture of Intel's current global semiconductor industry's fast-moving trend in the CPU world. "Tick" represents an odd-year import of a new generation of silicon wafer processes with improved microarchitecture; "Tock" indicates an even-numbered year to import a completely fresh microarchitecture, and a set of "Tick-tock" runs for two years. The most recent "tick-tock" turnover occurred between the 65 nm core microarchitecture and the 45 nm Penryn family, and Intel is on time to honor the promise of an annual update of the silicon wafer process with improved micro-architecture or a new micro-architecture.
To maintain a leading position in the industry, not only to maintain a leading speed, but also in the heat, power consumption and other performance, we must be in the leading edge. The constant improvement of the product frequency, calorific value is also gradually rising, the system stability decline at the same time, more detrimental to environmental protection, which is intel to adopt a new core architecture of the purpose, Intel Asia Pacific Vice president and general manager Yang Xu said, compared with the best Pentium processor, the Core 2 product performance increased by 40%, and energy consumption was reduced by 40%.
Products to do excellent, but also look at the market share. Lenovo, Hewlett-Packard, Dell, Shenzhou and other well-known manufacturers have also begun to fully adopt the Intel Core series of products, I believe that in the future Intel will also launch more heavy products to meet the needs of the market and users, multi-core technology will be continued to develop.
For applications that only care about data forwarding, such as IDs, only care about data parsing, alerting, and forwarding. All cores can be processed as simple executive, and each core runs a copy of the same program, which communicates through shared data structures, shared memory, and communication mechanisms provided by the hardware. Give full play to the advantages of multi-core, to achieve high-performance data processing.
Bootloader supports loading different applications onto different core, core 0 as Control Core,core 1-15 as service core. Core 0 runs Linux kernel as a control plane, core 1-15 runs applications, as a data plane, completes data processing and message forwarding protocol stack.
The Linux 2.6 kernel provides good support for SMP (symmetric multiprocessor). A new O (1) Scheduler has been introduced, which includes better SMP system support. Can load balance between CPUs while maintaining affinity to improve cache efficiency.
The kernel maintains two runqueue (expired and active Runqueue) for each processor. Each runqueue supports 140 priorities, the previous 100 for real-time tasks, and the following 40 for user tasks. Tasks are performed in time slices, which are moved from the active runqueue to the expired runqueue when they are finished using the time they are allocated. If a given priority task is not already in the active run queue, the pointer to the active run queue and the expired run queue is exchanged so that the expiration priority list becomes the list of active precedence. This provides a fair access to the CPU for all tasks (locked only on a per-CPU basis).
With each CPU's task queue, load Balancing can be carried out based on the load of all CPUs in the system. Every 200 milliseconds, the scheduler performs a load balancing adjustment to redistribute the task load and maintain balance between the processors.
At present, the Linux 2.6 kernel has been more mature, by the Linux kernel multi-core hardware resource management, scheduling, built in Linux applications. Can greatly reduce the workload of development, software systems will also have a high stability.
At present, multi-core technology has become the most concerned topic and research direction. Multi-core architecture has opened a new direction in the fields of performance improvement and energy saving calculation. However, there is no uniform standard for multi-core processors and is basically in the exploratory phase. The connection mode between nucleus and nucleus, communication coordination mode, the difference between core and core structure in the same processor, device resource allocation strategy, task scheduling strategy, energy saving strategy and software and hardware collaborative design strategy are all studied and explored. Multi-Core will bring great changes to all aspects of the computer industry, including architecture research, embedded system design and solution design, compiling technology, operating system core algorithm, application software design and other computer systems in various fields.
In the research of single core processor, the main focus is to improve the frequency and the degree of parallelism of instruction level. In the multi-core system, we pay more attention to the cooperation between nucleus and nucleus, the allocation of shared resources and the improvement of thread level parallelism.
The problem with multi-core processors is that there is a need to increase the degree of parallelism in the program, because single-threaded programs do not play the advantage of multi-core processors. By compiling optimizations, you can compile the original single-threaded code into multithreaded form. OpenMP provides a way for programmers to add code that can be processed in parallel, according to their needs, and compile the code into multithreaded program segments based on these tags. Multithreading development involves the problem of multithreaded debugging, which becomes more difficult on multi-core processors, so the multicore system leads to great changes in program development patterns.
Task scheduling on multi-core processors is also a new problem, and the common scheduling algorithms include global queue scheduling and local queue scheduling. The former refers to the operating system to maintain a global task wait queue, when the system has a CPU core idle, the operating system from the global task waiting queue to select the ready task started on this core execution. The advantage of this method is that CPU core utilization is high. The latter refers to the operating system for each CPU core maintenance of a local task waiting queue, when a system has a CPU kernel idle, then from the core of the task waiting queue to select the appropriate task execution, the advantage of this method is that the task is basically no need to switch between the core of multiple CPUs, It is helpful to improve the CPU's core local cache hit ratio and improve the system performance. At present, most CMP operating systems adopt the task scheduling algorithm based on global queues.
How to use multi-core technology effectively is a primary problem for application programmers on multi-core platforms. The advent of the multicore ERA requires software developers to find new ways to develop software and to select program execution models. In multi-core systems, the core is the sharing of data and communication through memory. To make the most of multi-core, the program needs to do a lot of things at once. Parallel programs execute instructions much faster than traditional serial programs because they can assign workloads to different cores of processors according to different requirements
Original address: http://blog.csdn.net/alphayi/article/details/4529277