| Dot Net have an important component that is CLR. | | | | Both of these files located in a PE File(Portable |
| No my point of view its not component, I think it | | | | Executable File). When we execute the P.E file the |
| provides runtime environment infrastructure to | | | | class loader loads the MSIL code and metadata from |
| application. Lets take some overview of it. | | | | P.E file to runtime memory. Now works for code |
| First of all we need some source code that needed | | | | manager is covers in existence it call the entry point |
| by CLS. It must be in CLS - complaint languages. Now | | | | method. This is any of these three. |
| the next step that comes is, CLS compiles the | | | | . Main |
| source code generate the Intermediate code (MSIL) | | | | . WinMain |
| and Meta Data. | | | | . DLLMain |
| The MSIL (Microsoft Intermediate Language) contains | | | | Entry point is first method that is to be executed |
| some instructions that relates to C.P.U. Just like how | | | | first. When entry point is execution code manages |
| to load, store, initialize and call methods on objects. In | | | | helps object to places him in memory and controls |
| MSIL instructions are also there just like perform | | | | the execution in the program. Now garbage collector |
| arithmetic and logical operations, memory directly | | | | performs periodic checks on the heap to identity the |
| access, flow of execution, handle exception. Because | | | | object, type checker performs types checking. Type |
| before execution MSIL we need CPU specific | | | | checker raise error if any occur. CLR controls the |
| instructions. And to execute the code, the runtime | | | | code at runtime. Now security engine performs |
| requires information about the code that is in | | | | restriction application. Now Managing Multithreading , |
| metadata. | | | | Com Marshels performs there roles. Now JIT |
| The Meta Data contains the types and references to | | | | compiles perform there role and convert all thing to |
| other type which is helpful for our applications. | | | | native code. |