当前位置:网站首页>Fundamentals of process management
Fundamentals of process management
2022-07-07 02:33:00 【A bumpy programmer】
Process management is also called processor management
Procedures and processes
- The order of execution of the program :1-2-3,1 yes 2 The precursor of ,2 yes 1 In the subsequent
- The program with no precursor relationship of the same job or the program segments of different jobs can be executed in parallel .
- The characteristics of concurrent execution of programs : Lost the closeness of the program , The execution sequence of the program and the machine is no longer one-to-one correspondence , The mutual restriction of concurrent programs
Process composition
- pcb Is the only criterion for the existence of a process
- Program : A program can be shared and executed by multiple processes at the same time , Then this part should be compiled in the form of pure code , The program cannot be modified during execution
- data : The data part includes the data required for program execution and the work area , This part can only be used by one process , Is the modifiable part of the process
State of process
- Three state model
function : When a process is running on the processor
be ready : A process is ready for everything , Ready to run
Blocking : When a process is running, it needs to wait for something to run
Five state model
establish : Created but not submitted
End : When the process is finished , Free memory
Pending state
Active and ready : Processes can be scheduled in main memory
Stand still : The process is switched to secondary storage , Only wait for a location in main memory , Will be scheduled , Or it has a higher priority
Active blocking : The process is in main memory , Once the waiting event is completed , Enter ready
Stand still : It's been blocked for too long , Will be switched to secondary storage , Only let the waiting event complete , Only when it is static and ready , Wait for opportunities to be active and ready
Process control
All processes from creation to extinction are effectively controlled
Process control is implemented by primitives in the operating system kernel
Interprocess communication
- Synchronization and mutual exclusion
- Sync : Inter process coordination ,a Process complete ,b Process start
- Mutually exclusive : You can't take mine
- Management principles : Enter when you are free , No time to wait , Limited waiting , Let the right waiting
- Limited waiting : To ensure that the process enters the critical zone in a limited time
- Let the right waiting : When the process cannot enter the critical zone , Let go
- Semaphore mechanism : public : Mutually exclusive ,1 Private use ; Sync 0
Advanced communication primitives
- Shared storage mode : Processes communicating with each other share some data structures to realize communication
- Messaging mode : Communicate through primitives
- Pipeline communication : adopt pip file , Write process and read process
Tube side
- Centralize resources , Abstract the resources in the system .
- The tube side is made of : Shared data , A collection of operations that can be performed by concurrent processes on shared data , The initial code and access rights consist of .
Process scheduling
- Advanced scheduling : Advanced scheduling is also called : Long scheduling , Admission scheduling , Job scheduling . Put the process into the ready state
- Intermediate dispatch : Also called : Medium range scheduling , Swap scheduling , Drop the process of the swap area to run , Or throw the blocked state to the exchange area , Make way for other processes
- Low level scheduling : Also called short-range scheduling or process scheduling , Drop the process in memory to run
- Scheduling algorithm :
- First come, first served : Who will use it first
- Time slice rotation : Fixed time slice : The time slices allocated to each process are equal , Variable time slice : Change according to the actual situation
- Priority scheduling : Schedule according to priority , Static priority : A priority will be created at the beginning , Can't change , Dynamic priority : It can change
- Multi level feedback scheduling : The highest priority queue can run first
- Process priority determination :
- about I/O Type process , Topmost queue , Computational process , Lowest level queue ,I/O Not many times , Mainly cpu The process of , At the completion of I/O after , Priority return I/O Queue of process end
Deadlock - Yes 2 A resource , One for one , But they all want to rob each other , It will form a loop , Cause a deadlock
- Deadlock solution :
- Pre static distribution : Request all resources at once , Don't give them a chance
- Orderly allocation of resources : Sort the resources in order , Don't let them form a loop
边栏推荐
- Apifox,你的API接口文档卷成这样了吗?
- Zhang Ping'an: accelerate cloud digital innovation and jointly build an industrial smart ecosystem
- C#/VB. Net to delete watermarks in word documents
- ODBC database connection of MFC windows programming [147] (with source code)
- MetaForce原力元宇宙佛萨奇2.0智能合约系统开发(源码部署)
- leetcode:736. LISP syntax parsing [flowery + stack + status enumaotu + slots]
- CDB PDB user rights management
- [C # notes] use file stream to copy files
- 纽约大学 CITIES 研究中心招聘理学硕士和博士后
- A new path for enterprise mid Platform Construction -- low code platform
猜你喜欢
leetcode:5. Longest palindrome substring [DP + holding the tail of timeout]
Several classes and functions that must be clarified when using Ceres to slam
[unity] upgraded version · Excel data analysis, automatically create corresponding C classes, automatically create scriptableobject generation classes, and automatically serialize asset files
豆瓣平均 9.x,分布式领域的 5 本神书!
Collection recommandée!! Quel plug - in de gestion d'état flutter est le plus fort? Regardez le classement des manons de l'île, s'il vous plaît!
Introduction to FLIR blackfly s industrial camera
【服务器数据恢复】raid损坏导致戴尔某型号服务器崩溃的数据恢复案例
3D laser slam: time synchronization of livox lidar hardware
Zhang Ping'an: accelerate cloud digital innovation and jointly build an industrial smart ecosystem
Infrared camera: juge infrared mag32 product introduction
随机推荐
go swagger使用
【论文阅读|深读】DNGR:Deep Neural Networks for Learning Graph Representations
pgpool-II和pgpoolAdmin的使用
[unity] upgraded version · Excel data analysis, automatically create corresponding C classes, automatically create scriptableobject generation classes, and automatically serialize asset files
Use of pgpool II and pgpooladmin
Processus général de requête pour PostgreSQL
Draco - gltf model compression tool
1 -- Xintang nuc980 nuc980 porting uboot, starting from external mx25l
C#/VB.NET 删除Word文档中的水印
1个月增长900w+播放!总结B站顶流恰饭的2个新趋势
1500万员工轻松管理,云原生数据库GaussDB让HR办公更高效
Application analysis of face recognition
Difference and the difference between array and array structure and linked list
【论文阅读|深读】RolNE: Improving the Quality of Network Embedding with Structural Role Proximity
The empirical asset pricing package (EAP) can be installed through pypi
Halcon instance to opencvsharp (C openCV) implementation -- bottle mouth defect detection (with source code)
Web3's need for law
6-6漏洞利用-SSH安全防御
建議收藏!!Flutter狀態管理插件哪家强?請看島上碼農的排行榜!
[paper reading | deep reading] rolne: improving the quality of network embedding with structural role proximity