Computer Tricks

[Computer tricks][bleft]

Coding Tips

[Computer tricks][twocolumns]

.NET Memory Allocation Concepts


    The flexibility and excellent range of tools available in .NET software development framework is one of the main reasons for its existence as prominent software development platform. This blog talks about the primary concepts of .NET platform that every .NET developer should be aware of.

Variable Declaration and Memory Allocation 

Whenever a variable is declared in .NET program, a substantial amount of memory is allocated in the RAM (Random Access Memory). Each variable is comprised of three attributes: name, data type and the value stored in it. 

Various Memory Allocation Techniques 

The following are the different types of memory allocation
  • Stack Memory Allocation

  • Heap Memory Allocation 


Stack Memory Allocation 

          In stack memory allocation, a small amount of memory is allocated in the stack and the data is stored at the top of the stack. It follows LIFO (Last In First Out) technique in storing and retrieving the value. 

Heap Memory Allocation 

          Heap memory allocation is usually followed while creating an object of a class. the object created is stored in a memory location called 'heap'. Heap is an dynamic memory allocation technique which allocates and de-allocates the memory of an object during run time.



Post A Comment
  • Blogger Comment using Blogger
  • Facebook Comment using Facebook
  • Disqus Comment using Disqus

No comments :


Software

[Software][threecolumns]

Internet

[Internet][list]

grids

health