性能:编译在VS,在Mono运行在Windows和Linux性能、VS、Mono、Windows

2023-09-05 23:41:42 作者:疯疯癫癫旳矜持范

我有以下问题:

是否有可能用VS.NET编译C#项目,并在单声道运行呢? 是否有与方法1相关(VS与单编译器编译)任何性能优势? 那么在Linux上运行的输出的.exe / .dll?什么是相关的性能特点?

感谢

解决方案

是的,你可以做到这一点。它应该工作,除非code使用未在单实现了一些框架内容。

这并不是说我知道。

不知道的#3,#1的区别是什么。如果你指的是使用单声道到Windows上编译,然后将其移植到Linux,它仍然应该工作一样。这两种编译器本质上产生相同的IL code。

I have the following questions:

Is it possible to compile a C# project using VS.NET, and run it on mono? Are there any performance benefits associated with approach 1 (vs compiling with the mono compiler)? What about running the output .exe/.dll on linux? And what are the associated performance characteristics?

Thanks

解决方案 Mono 2.10.8 发布,跨平台的 .NET 运行环境

Yes, you can do that. It should work unless the code uses some framework elements that are not implemented on mono.

Not that I am aware of.

Not sure what the difference between #3 and #1 is. If you are referring to using mono to compile on Windows, then porting it to linux, it should still work the same. Both compilers generate essentially the same IL code.