.Net Interview Questions and Answers

Search:

C# and .NET interview questions around JIT and NGEN

By : Shiv Prasad Koirala | Apr 18th, 2014 | Views : 3486 | Comments : 0 Bookmark and Share

What is JIT  ( Just in time)?


IL code is a half compiled code during runtime this half compiled code is compiled in to full machine language. This compilation is done by JIT.


What are different types of JIT ?


Normal-JIT (Default): - This the methods needed during runtime and caches them.


Econo-JIT: - This compiles the methods needed during runtime but there is no caching.


Pre-JIT: - This compiles the complete source code into native code during build itself. No compilation happens during runtime , there is no activity from JIT during runtime. We can implement Pre-jit by using ngen.exe.


Explain NGEN.EXE ?


Ngen stores full compiled.NET native code in to cache. In other words rather than dynamically compiling the code on run time a full image of native compiled code is stored in cache while installing the application. This leads to better performance as the assembly loads and execute faster.


In order to install full compiled native code in cache we can execute the below command line from your visual studio command prompt.


ngen.exe install <assemblyname>


Below is a nice youtube video created by www.questpond.com which explains the same in more detail


 
Rate this Article :
1 Star
2 Stars
3 Stars
4 Stars
5 Stars
1 1 1 2 1
 
 
 
 

.NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala

In this article we will explain .NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala.... Read More

What is the difference between Stored Procedures and Function (SQL Server interview question with answers)?

In this article we will explain what is the difference between Stored Procedures and Function.For more articles and videos visit us on www.questpond.com... Read More

Explain MVC application life cycle?

In this article we will explain MVC application life cycle.For more articles and videos visit us on www.questpond.com... Read More

C# Design pattern interview questions with answers: - How Singleton is different from Static class?

In this article we will explain How Singleton is different from Static class.... Read More

WCF interview questions and answers: - What is the difference between Service endpoint and Client endpoint?

In this article we will explain What is the difference between Service endpoint and Client endpoint.... Read More

.NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala

In this article we will explain .NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala.... Read More

What is the difference between Stored Procedures and Function (SQL Server interview question with answers)?

In this article we will explain what is the difference between Stored Procedures and Function.For more articles and videos visit us on www.questpond.com... Read More

Explain MVC application life cycle?

In this article we will explain MVC application life cycle.For more articles and videos visit us on www.questpond.com... Read More

C# Design pattern interview questions with answers: - How Singleton is different from Static class?

In this article we will explain How Singleton is different from Static class.... Read More

WCF interview questions and answers: - What is the difference between Service endpoint and Client endpoint?

In this article we will explain What is the difference between Service endpoint and Client endpoint.... Read More

Article Categories

Learn in Hindi