Linux内存管理模拟器

所属分类:操作系统开发
开发工具:C++
文件大小:4KB
下载次数:88
上传日期:2006-01-12 19:37:11
上 传 者eprometheus
说明:  Linux下使用c语言实现的内存管理模拟器 假设有台计算机物理内存大小为4MB,每个内存页大小为4k。采用分页机制,使用二级页表,第一级为页目录,共有1024项,每个页目录项指向一个页表,每个页表项指向一个实际的物理页面,每个页表共有1024个页表项。假设页目录和页表不占用内存空间。 系统中还有一个交换设备,采用分块管理机制,每块大小为4K,共1024个。有一系列内存访问指令,系统根据内存访问指令的内存虚地址访问内存。如果页目录项为空,则分配一个页表,并将相关值存入页目录项,如果页表项为空,则请求分配一个内存页,如果没有空闲内存,则使用页面置换算法换出一个内存页到交换设备上。如果页表项表明内存页在交换设备上,则先请求一个物理内存页,然后从交换设备上读入内存内容,释放交换设备上的磁盘块。
(use Linux c language memory management simulator assumptions computers to the physical memory size 4 MB, each memory page size to 4k. Pagination mechanism, the use of two-page questionnaire, the first level of Contents page, a total of 1,024. each page directory entry point to a page table, each page table at an actual item of the physical pages, each page table pages of a total of 1,024 items table. Assuming page catalog and page table off memory space. There is also a system to exchange equipment, a sub-block management mechanism, each 4K block size, a total of 1,024. A series of memory access instructions, the system memory access instructions under the virtual memory address access memory. If the page directory entry is empty, one-page questionnaire distribution, and related value depo)

文件列表:
MemSimu.c (4243, 2006-01-03)

近期下载者

相关文件


收藏者