Implementation of SMP system in Linux __linux

Source: Internet
Author: User

Reproduced:

Linux has increased support for SMP systems starting with 2.0. In the 2.2 kernel, the SMP implementation at the user level, the Linux kernel itself can not be accelerated because of multiple processors, after the 2.4 kernel, SMP implementation at the core level, the use of multiprocessor can speed up the processing speed of the kernel.

1. System Guidance in SMP
At the same time, a "context" can only be handled by one CPU. In the system boot and initialization phase, there is only one "context" that can be handled by only one processor. BP completes the system's boot and initialization, and creates multiple processes, allowing multiple processors to participate simultaneously, to start all the AP, so that they are ready to run after the initialization of their own.

In Linux, SMP system boot is a phased process, which requires the main CPU and secondary CPU in several places to synchronize, has achieved the same synchronization and coordination, and ultimately at the same time into the SMP process scheduling. The boot process for SMP systems in Linux on Intel's Pentium is as follows:

2, the process scheduling in SMP
in SMP-structured systems, there are multiple processes running simultaneously, requiring Linux to add two fields to the process's task_struct data structure, one is has_cpu, whether the table process is running on the CPU, and the other is processor, which CPU the table process runs on.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.