Dot Net Component Clr And Com Decom}

Dot Net Component CLR and Com – Decom

by

Pervej Munjal

Dot Net have an important component that is CLR. No my point of view its not component, I think it provides runtime environment infrastructure to application. Lets take some overview of it.

First of all we need some source code that needed by CLS. It must be in CLS complaint languages. Now the next step that comes is, CLS compiles the source code generate the Intermediate code (MSIL) and Meta Data.

The MSIL (Microsoft Intermediate Language) contains some instructions that relates to C.P.U. Just like how to load, store, initialize and call methods on objects. In MSIL instructions are also there just like perform arithmetic and logical operations, memory directly access, flow of execution, handle exception. Because before execution MSIL we need CPU specific instructions. And to execute the code, the runtime requires information about the code that is in metadata.

[youtube]http://www.youtube.com/watch?v=oJVqGhcryho[/youtube]

The Meta Data contains the types and references to other type which is helpful for our applications.

Both of these files located in a PE File(Portable Executable File). When we execute the P.E file the class loader loads the MSIL code and metadata from P.E file to runtime memory. Now works for code manager is covers in existence it call the entry point method. This is any of these three.

. Main

. WinMain

. DLLMain

Entry point is first method that is to be executed first. When entry point is execution code manages helps object to places him in memory and controls the execution in the program. Now garbage collector performs periodic checks on the heap to identity the object, type checker performs types checking. Type checker raise error if any occur. CLR controls the code at runtime. Now security engine performs restriction application. Now Managing Multithreading , Com Marshels performs there roles. Now JIT compiles perform there role and convert all thing to native code.

Pervej Munjal, writer of this article, is the main source who writes on

dot net questions

and

Com – Decom

at dotnetquestion.info

Article Source:

Dot Net Component CLR and Com – Decom}