Framework Questions

What is the .NET Framework?
The .NET Framework is an integral Windows component that supports building and running the applications and Web services. The .NET Framework provides a managed execution environment, simplified development and deployment, and integration with a wide variety of programming languages.The key components of the .NET Framework are the common language runtime (CLR) and the .NET Framework class library
What is CLR (Common Runtime Language)?
The common language runtime is the foundation of the .NET Framework. manages code at execution time, providing core services such as memory management, thread management, and remoting, while also enforcing strict type safety and other forms of code accuracy that promote security and robustness.
· The common language runtime manages memory, thread execution, code execution, code safety verification, compilation, and other system services. These features are intrinsic to the managed code that runs on the common language runtime.
· The runtime enforces code access security.
· The runtime also enforces code robustness by implementing a strict type-and-code-verification infrastructure called the common type system (CTS).
What is NET Framework class library ?
A library of classes, interfaces, and value types that are included in the .NET Framework SDK. This library provides access to system functionality and is designed to be the foundation on which .NET Framework applications, components, and controls are built. See also: class, CLS-compliant, Common Language Specification, interface, value type.
What is CTS?
The common type system defines how types are declared, used, and managed in the runtime, and is also an important part of the runtime's support for cross-language integration. The common type system performs the following functions:
· Establishes a framework that helps enable cross-language integration, type safety, and high performance code execution.
· Provides an object-oriented model that supports the complete implementation of many programming languages.
· Defines rules that languages must follow, which helps ensure that objects written in different languages can interact with each other.
What IS CLS?
To fully interact with other objects regardless of the language they were implemented in, objects must expose to callers only those features that are common to all the languages they must interoperate with. For this reason, the Common Language Specification (CLS), which is a set of basic language features needed by many applications, has been defined. The CLS rules define a subset of the
Common Type System
What is MSIL (Microsoft Intermediate Language)?
When compiling to managed code, the compiler translates source code into Microsoft intermediate language (MSIL), which is a CPU-independent set of instructions that can be efficiently converted to native code.
MSIL includes instructions for loading, storing, initializing, and calling methods on objects, as well as instructions for arithmetic and logical operations, control flow, direct memory access, exception handling, and other operations. Before code can be run, MSIL must be converted to CPU-specific code, usually by a just-in-time (JIT) compiler. Because the common language runtime supplies one or more JIT compilers for each computer architecture it supports, the same set of MSIL can be JIT-compiled and run on any supported architecture.
What is Just-in time Compilation?
Before you can run Microsoft intermediate language (MSIL), it must be compiled against the common language runtime to native code against the common language runtime for the target machine architecture. The .NET Framework provides two ways to perform this conversion:
· A .NET Framework just-in-time (JIT) compiler.
· The .NET Framework Native Image Generator (Ngen.exe).
JIT compilation converts MSIL to native code on demand at application run time, when the contents of an assembly are loaded and executed. Because the common language runtime supplies a JIT compiler for each supported CPU architecture, developers can build a set of MSIL assemblies that can be JIT-compiled and run on different computers with different machine architectures. However, your managed code will run only on a specific operating system if it calls platform-specific native APIs, or a platform-specific class library.
JIT compilation takes into account the fact that some code might never get called during execution. Rather than using time and memory to convert all the MSIL in a portable executable (PE) file to native code, it converts the MSIL as needed during execution and stores the resulting native code in memory so that it is accessible for subsequent calls in the context of that process.

What is TypeSafty in .net?

The ability for languages and classes to exchange information through commonly agreed upon definitions and usage patterns for types.

What is Managed Code?

Compilers and tools expose the runtime's functionality and enable you to write code that benefits from this managed execution environment. Code that you develop with a language compiler that targets the runtime is called managed code; it benefits from features such as cross-language integration, cross-language exception handling, enhanced security, versioning and deployment support, a simplified model for component interaction, and debugging and profiling services.

To enable the runtime to provide services to managed code, language compilers must emit metadata that describes the types, members, and references in your code.

Explain about Types of jit?

prejit,ecno jit,normal jit

pre jit : convert source code to native code in single completion of cycle.Normally this can be done at the time of deployment.

econo jit : coverts the only called methods to native code,however it can be removed when are not required.

normal jit : compliled the called methods to native code.In the the methods can be compiles for the first time.For latter calls it can be displayed using cached items.