红联Linux门户
Linux帮助

Linux Programing

发布时间:2008-01-25 01:07:26来源:红联作者:Daxianfeng
For a working definition,we've said that a process is a running program.This means that the operating system h-as loaded the executable file for the program into memory,has arranged for it to have access to its command-lin-e arguments and environment variables,and has started it running.A process has five conceptually different are-as of memory allocated to it:

Code:

Often referred to sa the text segment,this is the area in which the executable instructions reside.

Initialized data:

Statically allocated and global data that are initialized with nonzero values live in the data segment.

Zero-initialized data:

Global and statically allocated data that are initialized to zero by default are kept in what is colloquially called the SS area of the process.

Heap:

The heap is where dynamic memory(obtained by malloc() and friends)comes from.

Stack:

The stack segment is where local variables are allocated.
文章评论

共有 0 条评论