The basic unit of CPU scheduling is the thread. A thread is the smallest unit that the operating system can perform operation scheduling.
#A thread refers to a single sequential control flow in a process. Multiple threads can run concurrently in a process, and each thread performs different tasks in parallel. It is also called lightweight processes in Unix System V and SunOS, but lightweight processes refer more to kernel threads, while user threads are called threads. (Recommended learning: web front-end video tutorial)
CPU Scheduler
Whenever the CPU is idle, the operation must be selected from the ready queue a process to execute. Process selection is performed by a short-term scheduler or CPU scheduler. The scheduler selects an executable process from the kernel and allocates the CPU to it.
The ready queue does not have to be a first-in-first-out (FIFO) queue. Ready queues can be implemented as FIFO queues, priority queues, trees, or simple unordered linked lists. Conceptually, however, all processes in the ready queue are queued to wait to run on the CPU. Records in the queue are usually process control blocks (PCBs).
Preemptive Scheduling
CPU scheduling decisions can occur in the following 4 environments:
When a process changes from the running state Switch to a waiting state (for example, an I/O request, or calling wait to wait for the termination of a child process).
When a process switches from the running state to the ready state (for example, when an interrupt occurs)
When a process switches from the waiting state to the ready state (for example, I/O is completed)
When a process terminates
For cases 1 and 4, there is no choice but scheduling. A new process (if a process already exists in the ready queue) must be selected for execution. However, for cases 2 and 3, there is a choice.
When scheduling can only occur in the 1st and 4th situations, the scheduling plan is called nonpreemptive or cooperative; otherwise, the scheduling plan is called preemptive. ). With non-preemptive scheduling, once the CPU is allocated to a process, the process will always use the CPU until the process terminates or switches to a waiting state.
Interrupts can occur at any time and cannot always be ignored by the kernel, so the code segments affected by interrupts must be protected from simultaneous access. In order to prevent these code segments from being accessed by multiple processes at the same time, interrupts must be disabled when entering, and interrupts must be re-enabled when exiting.
The above is the detailed content of The smallest unit of processor scheduling. For more information, please follow other related articles on the PHP Chinese website!

octa core处理器是“全志”厂商的;octa core处理器相当于麒麟中的一种八核处理器芯片,octa core处理器采用了类似麒麟710的14nm工艺,全志科技经营的范围包括电子元器件、软件的研发及销售。

“mt6877 5g”指的是天玑900系列芯片;2021年5月,联发科发布了旗下的天玑900系列芯片,又名mt6877,天玑900是基于6nm工艺制造,采用八核CPU架构,包括2个主频“2.4GHz”的“arm Cortex-A78”大核和6个主频“2.0GHz”的“Arm Cortex-A55”高能效核心。

sdm710是高通骁龙710处理器;骁龙710是高通首款700系列处理器,代号为sdm710,该处理器于2018年5月推出,基于10nm制程工艺,拥有八核心CPU架构,两个2.2GHz大核,六个1.7GHz小核,GPU型号是Adreno 616,支持“QC 4+”快充技术。

iPhone搭载A12仿生处理器的手机有iPhone XS,6.5英寸版iPhone XS Max,以及6.1英寸iPhone XR。A12处理器的CPU是六核心设计,其中两个性能大核心相较于前代提速15%、功耗降低40%,四个能效小核心的功耗最多可降低50%;A12仿生采用了7纳米制程工艺芯片,提升了能效和性能表现。

三星s10搭载了高通骁龙855处理器,使用台积电7nm工艺,CPU采用八核Kryo 485架构,GPU使用的是Adreno 640,内存速度为2133MHz;支持GPS、GLONASS、北斗、Galileo、QZSS,SBAS和双频定位。

intel xeon是Intel的至强处理器,是英特尔生产的微处理器,它用于"中间范围"的企业服务器和工作站。Xeon基于奔腾微处理器P6构架,它被设计成与新的快速外围元件互连线以及加速图形端口一起工作;装有Xeon微处理器的计算机一般可使用Windows NT、NetWare或Unix操作系统。

“mali g610”是“mali GPU”中“ARM Valhall GPU”架构处理器的第三代产品;Mali是一款高端GPU,主要应用基于ARM体系结构的移动设备上,“mali GPU”最早由挪威科技大学项目独立出来成立的Falanx公司开发。

E080八核是指Exynos 1080八核处理器。Exynos 1080采用5nm工艺制程,采用1个大核+3个中核+4个小核的核心配置,其中大核与中核采用的是A78的架构,小核采用的是A55的架构。Exynos 1080的GPU采用来自ARM的Mali-G78核心MP10,在Mahattan v3标准下,GPU的性能整体提升了2.3倍之多;并且独家开发了Amigo电源分配方案。

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version
Visual web development tools

Notepad++7.3.1
Easy-to-use and free code editor

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft
