Quote:
Originally Posted by rahul_scss
Can somebody please tell me what exactly the rules of this packaging format are???
If you visualize the memory as rows and columns then if you need to allocate some memory in different rows[for different variables] then you have to allocate n no of cols of bytes for each variable and n is choosen as maximum size.

e.g.
Variable 1 mem [8 bytes] | | | | | | | |
Variable 2 mem [4 bytes] | | | |

Instead of 4 bytes it allocates 8 to keep the packaging format in good shape for second variable memory.

If you go about by sequential memory segment then also allocating each variable memory of n [choosen as maximum] is easier and so it allocates 8 + 8 bytes instead of 8 + 4 bytes.

Last edited by shabbir; 17Oct2005 at 14:54..