Compile C # code under the .net platform

Recently rush project suddenly thought of a problem, and that is the code in C # .Net platform is how from the source code to the machine can recognize the computer (do not blame yourself go to school to study hard, and now have to re-fill it again !!! )

Man of few words said, directly on the findings:

  Knowledge preview:

      1: IL is derived on the Microsoft .NET platform, an intermediate language, various high-level languages ​​(e.g., C #, VB, F #) on the .NET platform compiler will respective code into IL.

      2: CLR was a time can be run by a multi-language programming, CLR core functions: memory management, assembly loading, security, exception handling, thread synchronization and so on. Microsoft may be using a lot belonging to series development language.

   result:

      Core .net framework is its runtime execution environment, become the common language runtime (CLR) or .net runtime. Code is normally run under the control of the CLR is called managed code (managed code). They need to be compiled before the implementation of CLR-written source code. .net compiled in two stages:

           (1) compile the source code for Microsoft Intermediate Language (IL).
           (2) to the CLR IL code is compiled into platform-specific.

      The first compilation is slow (by respective compilers) (a source of IL >> ---- intermediate code), the second compiled quickly (by the CLR) (---- intermediate code by the machine code >> )

 

 

     

     Disclaimer: This article is a blogger original article, if reproduced, please indicate the source.

Guess you like

Origin www.cnblogs.com/gamecc666/p/11324723.html