评估软件最低要求

发布于 2024-07-26 06:20:58 字数 70 浏览 3 评论 0原文

有没有办法评估软件的最低要求? 我的意思是,我怎样才能发现我的应用程序需要的最小 RAM 量?

谢谢!

Is there a way to evaluate the minimum requirements of a software? I mean, how can I discover, for example, the minimum amount of RAM that my application will need?

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

喜爱纠缠 2024-08-02 06:20:59

分析器在这里不会为您提供帮助。 也不会估计数据结构的大小。

探查器当然可以告诉您代码在哪里花费了最多的 CPU 时间,但它不会告诉您是否未达到性能目标 - 例如,您的用户对任何给定系统上的应用程序的性能是否满意或不满意。

简单地计算数据结构的大小以及一次可以分配的数据结构根本无法让您准确了解一段时间内的内存使用情况。 原因是内存使用量由许多其他因素决定,包括应用程序执行的 I/O 量、应用程序使用的操作系统服务,以及最重要的应用程序使用内存的时间性质。

了解最低要求的最有效方法是

  • 确保您拥有使用对用户重要的指标衡量性能的有效方法。 最好的指标是响应时间。 根据您的应用程序,吞吐量或每秒操作数等速率可能适用。 您的测量可能是经验性的(例如,尝试一下),但效果最差。 这最好通过某种仪器来完成。 在 Windows 上,选择是 [ETW][1]。 其他操作系统有其他合适的机制。
  • 采用某种自动化方法来运行您的应用程序。 这将使您能够进行重复且可靠的测量。
  • 使用不同的内存大小来衡量您的应用程序,看看性能在哪里开始受到影响。 这还可能会暴露性能错误,从而导致应用程序无法正常运行。 如果您可以访问各种性能级别的平台,也请使用这些平台。 您没有指出您的应用程序的用途,但在具有 1GB 内存的上网本上进行测试对于许多(不是全部)客户端应用程序来说非常有用。

您可以对 CPU 和其他组件(例如磁盘、网络或 GPU)执行相同的操作。

另请注意,这里没有简单的答案 - 有效地制定最低要求才是真正的工作。 如果您的应用程序对某个平台方面的参与性敏感,则尤其如此。

还有其他因素 - 例如,您的应用程序可能在一种配置中运行良好,直到用户打开另一个可能占用内存或占用 CPU 的应用程序。 用户很少只打开一个应用程序。

这意味着,除了指定最低要求之外,您还必须有效地设置用户期望 - 即解释您的应用程序何时表现良好,何时表现不佳,以及影响性能的因素是什么。

[1]:http://msdn.microsoft.com/en-us/ Library/ms751538.aspx强文本

A profiler will not help you here. Neither will estimating the size of data structures.

A profiler can certainly tell you where your code is spending the most CPU time, but it will not tell you if you are missing performance targets - e.g. if your users will be happy, or unhappy with the performance of your application on any given system.

Simply computing the size of data structures, and how many may be allocated at any one time will not at all give you an accurate picture of memory usage over time. The reason is that memory usage is determined by many other factors including how much I/O your application does, what OS services your application uses, and most importantly the temporal nature of how your application uses memory.

The most effective way to understand minimum requirements is to

  • Make sure you have an effective way of measuring performance using metrics that are important to your user. the best metric is response time. Depending on your app, a rate such as throughput or operations per second may be applicable. Your measurements could be empirical (e.g. just try it) but that is least effective. This is best done with some kind of instrumentation. On windows, the choice is [ETW][1]. Other operating systems have other suitable mechanisms.
  • Have some kind of automated method of exercising your application. This will let you make repeated and reliable measurements.
  • Measure your application using various memory sizes and see where performance begins to suffer. This may also expose performance bugs that prevent your application from performing well. If you have access to platforms of various performance levels, use those as well. You didn't indicate what your app does, but testing on a netbook with 1GB of memory is great for many (not all) client applications.

You can do the same with the CPU and other components such as disk, networking or the GPU.

Also note that there is no simple answer here - doing an effective job at setting minimum requirements is real work. This is especially true if your application is participatory sensitive to one platform aspect or another.

There are other factors as well - for example, your app may run fine in one configuration until the user opens another application that may be memory hungry or a CPU pig. Users rarely only have one application open.

This means that in addition to specifying minimum requirements you must do an effective job in setting user expectations - that is explaining when your application will perform well, and when it won't, and what the factors are that impact performance.

[1]: http://msdn.microsoft.com/en-us/library/ms751538.aspxstrong text

靑春怀旧 2024-08-02 06:20:59

理想情况下,您可以根据目标受众确定软件的最低要求,然后在开发过程中根据该配置测试您的软件,以确保它提供令人满意的体验。

您可以查看运行您的软件的系统,了解您的应用程序消耗了多少内存,并使用它来指导消耗了多少内存。 CPU 有点复杂 - 您可以尝试对 CPU 要求进行建模,但准确地做到这一点可能具有挑战性。

但最终,您需要在目标基础系统上测试您的应用程序。

Ideally, you'd decide on the minimum requirements of a piece of software based on your target audience, and then test your software during development on that configuration to ensure it delivers a satisfactory experience.

You can look at a system running your software and see how much memory is being consumed by your application, and use that to guide how much memory is being consumed. CPU is a little bit more complex - you could try to model your CPU requirements, but doing this accurately can be challenging.

But ultimately, you need to test your app on the base system you are targeting.

雪花飘飘的天空 2024-08-02 06:20:59

给定应用程序使用的数据结构,估计它们在正常使用中将占用多少空间。 使用该估计,设置许多机器(虚拟或物理)以在不同场景(即不同的目标操作系统、不同的虚拟内存设置等)下测试估计。

然后衡量应用程序在不同场景下的性能。 您的最低设置将是性能最差但仍可接受的机器。

Given the data structures used by the application, estimate how much space they will take up in normal use. Using that estimation, set up a number of machines (virtual or physical) to test the estimate in different scenarios (i.e. different target operating systems, different virtual memory settings, etc).

Then measure the performance of the application in the different scenarios. Your minimum settings will be the machine that performs the least adequately while still being acceptable.

安静被遗忘 2024-08-02 06:20:59

您可以在对软件进行压力测试时尝试使用性能分析器。

You could try using a performance profiler on your software while stress testing it.

苹果你个爱泡泡 2024-08-02 06:20:59

您可以使用虚拟化在虚拟机中重复运行具有不同 RAM 量的代表性测试套件……当性能由于交换而低于可接受的水平时,您就发现了内存需求。

You could use virtualization to repeatedly run a representative test suite with different amounts of RAM in the virtual machine...when the performance falls below acceptable levels due to swapping, you've found the memory requirement.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文