Process Creation进程创建

Most operating systems (including UNIX, Linux, and Windows) identify processes according to a unique process identifier (or pid), which is typically an integer number

大多数的系统(Unix,Linux, Windows)都是根据唯一标示的进程标示符(pid)来表示进程的。pid通常是一个整数。

We use the term process rather loosely, as Linux prefers the term task instead.

我们这里使用术语:进程,而不用Linux习惯叫法:任务。

Restricting a child process to a subset of the parent’s resources prevents any process from overloading the system by creating too many child processes.

限制一个孩子进程只使用父母进程资源的子集,可以防止任何进程因为创建太多子进程而过载系统。

The only difference is that the value of pid (the process identifier) for the child process is zero, while that for the parent is an integer value greater than zero (in fact, it is the actual pid of the child process).

仅仅不同的是pid的值,子进程pid值为零,而父母进程的pid是一个整型值大于零(实际上这也是子进程的实际pid)

Because the child is a copy of the parent, each process has its own copy of any data.

因为子进程是父母进程的一份拷贝,每个进程都有自己的一份数据拷贝。

fork() has the child process inheriting the address space of its parent, CreateProcess() requires loading a specified program into the address space of the child process at process creation.

linux中的fork函数创建子进程时,子进程继承了父母进程的地址空间,而Windows的CreateProcess()要求在进程创建时加载一个特定进程到子进程的地址空间去。

when one process creates a new process, the identity of the newly created process is passed to the parent.

当一个进程创建一个新的进程时, 其新创建进程的标示符传给父母进程。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值