Saturday, January 7, 2012

Discuss memory layout for C programs

Ideally you should discuss all the different areas that are used

1 comment:

  1. Atleast one code section, one or more data section(s), BSS, read only text (optional), debug info section (conditional), few more based on ABI.

    Sample code,

    char *s = "This is a string";

    where will be the string literal "This is a string" stored? Answer in case of server, desktop and embedded systems.