Wednesday, 29 February 2012

Writing a CIL disassembler

The F#.NET Journal just published an article about graphics:

"The .NET Framework provides powerful reflection capabilities oriented towards compiling run-time generated code to CIL from .NET languages such as F#. In essence, the System.Reflection.Emit namespace provides a programmatic CIL assembler. Relatively little support is provided for the inverse problem of disassembling bytecode back to CIL instructions although this can be very useful for instrumenting assemblies with new code to record code coverage, capture unit tests and measure performance characteristics and so forth. This article walks through the design and implementation of a tiny CIL disassembler that applies the reflection API to itself in order to obtain the required mappings from bytecodes to CIL instructions..."

To read this article and more, subscribe to The F#.NET Journal today!

No comments: