Some name

Initialised and uninitialised data- need some clarifications......

can anybody tell me the diff between initialised data and uninitialiseddata. where bss comes to pic?? Diff between stack, bss and heap?? whichtype of data each contains??

Thanks in advance.........

Sitesh

This communication is the property of Qwest and may contain confidential orprivileged information. Unauthorized use of this communication is strictly prohibited and may be unlawful. If you have received this communication

in error, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments.

"Global and statically allocated data that are initialized to zero by default are kept in what is colloquially called the BSS area of the process. Each process running the same program has its own BSS area. When running, the BSS data are placed in the data segment. In the executable file, they are stored in the BSS section."

The stack is primarily used to store non-static local variables. Depending on the platform, the stack may store function parameters, a function return value and the caller's return address (a place for the program pointer to jump when the current function returns). A function's stack storage is reclaimed when the function returns, because there is no further need to maintain storage for local variables that are going out of scope.

Sitesh - Unless you have a more specific question, all I can say about BSS is:1) BSS is a type of data segment that resides in memory, referred to hereafter as the BSS segment2) The BSS segment is used to store global or static data3) The BSS segment is automatically initialised with all zeroes by the OS prior to running the process4) The only information needed about the BSS segment in the executable binary is its size and relative address