📜  虚拟内存和作业池的区别

📅  最后修改于: 2022-05-13 01:56:11.321000             🧑  作者: Mango

虚拟内存和作业池的区别

虚拟内存 :
虚拟内存是操作系统中的一种内存管理技术,它给用户一种错觉,即他们正在使用的内存等于二级存储介质的内存(即非常大的内存)。因此,这允许程序员编写需要比实际内存更多的内存的程序。

工作池:
作业池是批处理系统中的一种数据结构,其中当所有资源都可供系统使用时,各种作业会排队等待执行。它决定接下来将执行哪个作业。

这里的主要思想是,每当创建一个新作业时,它都会存储在作业池中,当它准备好执行时,它需要存储在物理内存中。但是当需要非常大的内存时,只有一部分主内存被执行,而其余部分内存被存储在虚拟内存中。

虚拟内存和作业池都用于在硬盘中存储进程一段时间,然后将它们加载到主内存中。

虚拟内存和作业池的区别如下:



Virtual Memory

Job Pool

Virtual memory is a memory management technique that gives the users an illusion of infinite memory Job pool is a program of the operating system that is located in operating system and stores newly created processes while they are waiting for their respective resources.
The concept behind virtual memory is that it creates an illusion that we are working with a very large memory when actually we are using only a part of the memory.The concept of the job pool states that a newly created process is stored in a pool called a job pool, where these processes wait for the resources to get allocated in order to get executed.
Virtual Memory represents the address generated by the CPU virtually.Job pool represents the pool from which the long-term scheduler chooses which job will be executed first.  
While loading processes from the hard disk to the main memory, virtual memory is not required if there is no need of infinite memory.While loading processes from the hard disk to the main memory, a job pool is always required to store a newly created process. 
A part of the process needs to be in memory for executionA newly created process is stored here, waiting for required resources