有什么用IL文件从.NET产生的(使用MSIL assembler- ilasm.exe)? [英] What is the use of IL file generated from .NET (using MSIL assembler- ilasm.exe)?

查看:111
本文介绍了有什么用IL文件从.NET产生的(使用MSIL assembler- ilasm.exe)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

用的是什么,从.NET产生IL文件(使用MSIL assembler- ilasm.exe)?

What is the use of IL file generated from .NET (using MSIL assembler- ilasm.exe)?

我从 http://msdn.microsoft.com/en-阅读美国/库/ 496e4ekx.aspx 但我不知道使用IL文件从.NET产生的(使用MSIL assembler- ilasm.exe)。 任何一个可以解释我?

I read it from http://msdn.microsoft.com/en-us/library/496e4ekx.aspx but i am not sure about the use of IL file generated from .NET (using MSIL assembler- ilasm.exe). Can any one explain me?

推荐答案

您可能要直接使用IL在那些(诚然罕见的)情况下,当如C#高级语言不提供precision或者功能需要。

You might want to use IL directly in those (admittedly rare) situations when a higher level language like C# doesn't provide the precision or features you need.

例如,有在 System.Dynamic 一些功能,从动态语言如IronPython的不能很容易地在C#中使用使用。直接去IL可以帮助那些你需要混合的语言,也许是一个第三方库的情况。

For instance, there are some features in System.Dynamic that are used from the dynamic languages such as IronPython that can't easily be used in C#. Going straight to IL can help in those situations where you need to mix languages, perhaps for a third-party library.

在另一方面,的拆卸的对IL可以是非常有用的,你可以找到code是什么,编译器为你的C#程序产生。这是无价的微优化的性能问题,例如。

On the other hand, disassembling to IL can be very useful as you can find exactly what the code is that the compiler generated for your C# program. This is invaluable for micro-optimising performance issues, for example.

这篇关于有什么用IL文件从.NET产生的(使用MSIL assembler- ilasm.exe)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆