当前位置: 技术问答>linux和unix
[新手求助]什么是memory image?
来源: 互联网 发布时间:2016-11-13
本文导语: 摘自《Operating Systems Design and Implementation, Third Edition》 In MINIX 3, there is only one system call to create a new process: fork. This call creates an exact clone of the calling process. After the fork, the two processes, the parent...
摘自《Operating Systems Design and Implementation, Third Edition》
In MINIX 3, there is only one system call to create a new process: fork. This call creates an exact clone of the calling process. After the fork, the two processes, the parent and the child, have the same memory image, the same environment strings, and the same open files. That is all there is. Usually, the child process then executes execve or a similar system call to change its memory image and run a new program.
In MINIX 3, there is only one system call to create a new process: fork. This call creates an exact clone of the calling process. After the fork, the two processes, the parent and the child, have the same memory image, the same environment strings, and the same open files. That is all there is. Usually, the child process then executes execve or a similar system call to change its memory image and run a new program.
|
大意应该是内存镜像或者内存拷贝的意思。意思是说父进程创建子进程之后,父子进程的代码其实在内存中只有一份拷贝,同样的运行环境和相同的已打开的文件描述符.通常 子进程使用execve类的调用改变自己的内存拷贝并运行一段新的代码。
这段英文将的大概是“写时拷贝”的概念,楼主了解一下这个概念就差不多理解了。
这段英文将的大概是“写时拷贝”的概念,楼主了解一下这个概念就差不多理解了。
|
C代码编译后,生成的目标机器的机器码(可执行文件),此可执行文件装载入内存后,即memory image(内存映象)。