Previous Topic Next topic Print topic


What is Managed Code?

You may be familiar with COBOL compiling to native code in earlier Micro Focus products.

Native code compiles directly to machine code that is native to a device processor and is directly executed on the machine for which it was compiled. The run-time management services are provided by the operating system, and the code has to call the appropriate services depending on the operating system.

Managed code is code that compiles to Intermediate Language (IL) in .NET or to Java byte code on the Java Virtual Machine (JVM) .

Managed code runs in the Common Language Runtime (for .NET) or the JVM (for Java byte code) which are execution environments that provide various services such as checking the code, memory management, and threading.

When you start an application written in managed code, the runtime-aware compiler provided by the respective environment checks the code (IL and Java byte code) for security risks and language violations and compiles it Just In Time to native executable code. The runtime environment ensures type safety, array bound and index checking, exception handling, and garbage collection.

Previous Topic Next topic Print topic