.NET 2.0 应用程序(“任何 CPU")在 64 位操作系统/处理器上运行缓慢 [英] .NET 2.0 application ('Any CPU') running slow on 64-bit OS/processoer

查看:30
本文介绍了.NET 2.0 应用程序(“任何 CPU")在 64 位操作系统/处理器上运行缓慢的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的 Windows 应用程序是在 .NET 2.0 框架上开发的,并且是使用Any"构建的CPU',开发环境为 32 位操作系统 + Visual Studio 2005.

My Windows application is deveoped on .NET 2.0 Framework and is build using 'Any CPU', development enviroment is 32-bit OS + Visual Studio 2005.

现在我正在 64 位处理器 + 64 位操作系统上部署此应用程序,但它运行缓慢.

Now I am deploying this application on 64-bit processoer + 64-bit OS it is running slow.

但如果我使用 x86(32 位)构建,它在 64 位处理器 + 64 位操作系统上运行良好,没有任何问题.

But if I build using x86 (32 bit), it is working fine without any issue on a 64-bit processor + 64-bit OS.

我有第三方组件,如 DevExpress、Janus、txtext、ComponentOne Zip

I have third-party components like DevExpress, Janus, txtext, ComponentOne Zip, etc.

为什么运行缓慢?

推荐答案

64 位并不总是运行得更快.
简短的回答是 64 位应用程序消耗更多内存(如果您有一个 64 位指针数组,它将比具有 32 位指针的相同大小的数组大)更多的内存意味着垃圾收集会更加努力.
阅读 此处此处 了解更多详情.

64 bit will not always run faster.
The short answer is that 64 bit application consumes more memory (if you have an array of 64 bit pointers it will be larger than array of the same size with 32 bit pointers) More memory means that the garbage collection will work harder.
Read here and here for more details.

在任何情况下,您都必须分析应用程序并查看瓶颈在哪里.
(也许查看 GC 是一个不错的起点)

In any case you'll have to profile the application and see where's the bottle neck.
(maybe looking at the GC is a good place to start)

这篇关于.NET 2.0 应用程序(“任何 CPU")在 64 位操作系统/处理器上运行缓慢的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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