Common Language Runtime

Why Trust Techopedia

What Does Common Language Runtime Mean?

Common Language Runtime (CLR) is a managed execution environment that is part of Microsoft’s .NET framework. CLR manages the execution of programs written in different supported languages.

Advertisements

CLR transforms source code into a form of bytecode known as Common Intermediate Language (CIL). At run time, CLR handles the execution of the CIL code.

Techopedia Explains Common Language Runtime

Developers write code in a supported .NET language, such as C# or VB.Net. The .NET compiler then converts it into CIL code. During run time, the CLR converts the CIL code into something that can be understood by the operating system. Alternately, the CIL code can be transformed into native code by using the native image generator (NGEN).

The language compilers store metadata that describes the members, types and references in the compiled code. The CLR uses the metadata to lay out instances in memory, locate and load classes, enforce security, set runtime context boundaries, and generate native code.

CLR allows for the easy use of different supported languages to achieve a common goal. This makes it flexible for developers to choose their own programming language, provided it is supported by the .NET framework. With CLR, .NET can manage the execution of all supported languages by transforming them to bytecode and then into the native code for the chosen platform.

Using NGEN makes later runs faster because CLR will not have to transform the bytecode into native code each time. Although other implementations of CLI can run on platforms other than Windows, Microsoft’s CLI implementation is only meant to run on the Windows platform.

Advertisements

Related Terms

Margaret Rouse
Technology Specialist
Margaret Rouse
Technology Specialist

Margaret is an award-winning writer and educator known for her ability to explain complex technical topics to a non-technical business audience. Over the past twenty years, her IT definitions have been published by Que in an encyclopedia of technology terms and cited in articles in the New York Times, Time Magazine, USA Today, ZDNet, PC Magazine, and Discovery Magazine. She joined Techopedia in 2011. Margaret’s idea of ​​a fun day is to help IT and business professionals to learn to speak each other’s highly specialized languages.