When a .NET application is first loaded, the JIT (Just-in-Time) compiler takes the MSIL (Microsoft Intermediate Language) code that is contained within the assembly and compiles that code into a native image. That native image is then stored in the native image cache to be used for subsequent application executions so that the JIT step can be skipped.
When you use the Microsoft CLR Native Image Generator tool (NGen.exe), it will manually perform the initial native image generation so that the application will load faster the first time it is executed. When you run the Ngen tool against a .NET application, you get output that looks something like this:
Microsoft (R) CLR Native Image Generator - Version 2.0.50727.42 Copyright (C) Microsoft Corporation 1998-2002. All rights reserved. Installing assembly C:\Documents and Settings\Kevin\My Documents\Writing\SAMS\C# 2005 Unleashed\16\Code\ProfileDemo\ProfileDemo\bin\Debug\profiledemo.exe Compiling 1 assembly: Compiling assembly C:\Documents and Settings\Kevin\My Documents\Writing\SAMS \C# 2005 Unleashed\16\Code\ProfileDemo\ProfileDemo\bin\Debug\profiledemo.exe ... ProfileDemo, Version=220.127.116.11, Culture=neutral, PublicKeyToken=null <debug>
Application developers often include execution of Ngen.exe upon initial installation to generate the native image and place it in the native image cache so that the application will start more quickly.