问题描述
我最近被要求生产的MIPS因为我们开发了一种算法(每秒百万指令)。该算法是由一组C样式功能曝光。我们有锻炼code在戴尔Axim测试不同的输入下的性能。
I have been asked recently to produced the MIPS (million of instructions per second) for an algorithm we have developed. The algorithm is exposed by a set of C-style functions. We have exercise the code on a Dell Axim to benchmark the performance under different input.
这个问题来自我们的硬件供应商,但我大多是HL软件开发人员,所以我不知道如何响应请求。也许有人有类似HW / SW背景可以帮助...
This question came from our hardware vendor, but I am mostly a HL software developer so I am not sure how to respond to the request. Maybe someone with similar HW/SW background can help...
-
由于我们的算法是不实时,我不认为我们需要把它作为量化MIPS。是否有可能只是引用的汇编指令总数是多少?
Since our algorithm is not real time, I don't think we need to quantify it as MIPS. Is it possible to simply quote the total number of assembly instructions?
如果1是真实的,你是怎么做到这一点(即如何衡量的汇编指令数)无论是在一般或专门为ARM / XScale的?
If 1 is true, how do you do this (ie. how to measure the number of assembly instructions) either in general or specifically for ARM/XScale?
2能否将一个WM设备或通过在VS2005提供的设备仿真器进行的?
Can 2 be performed on a WM device or via the Device Emulator provided in VS2005?
3可以实现自动化?
非常感谢你的帮助。
查尔斯
Thanks a lot for your help.Charles
感谢您的帮助。我认为美国洛特撞钉。而作为后续行动,我现在有更多的问题。
Thanks for all your help. I think S.Lott hit the nail. And as a follow up, I now have more questions.
5如何去测量MIPS任何建议?我听到有人建议运行我们的算法,并作比较的Dhrystone /油石基准计算管理信息系统。
5 Any suggestion on how to go about measuring MIPS? I heard some one suggest running our algorithm and comparing it against Dhrystone/Whetstone benchmark to calculate MIS.
6由于算法不需要实时运行,是MIPS真的有用的措施? (如阶乘(N))有什么其他的方法来量的处理要求是什么? (我已经测得的运行时性能,但它不是一个满意的答复。)
6 Since the algorithm does not need to be run in real time, is MIPS really a useful measure? (eg. factorial(N)) What are other ways to quantity the processing requirements? (I have already measured the runtime performance but it was not a satisfactory answer.)
7最后,我假设MIPS是一个粗略估计,将被DEP。对编译器,优化设置等?
7 Finally, I assume MIPS is a crude estimate and would be dep. on compiler, optimization settings, etc?
推荐答案
我敢打赌,你的硬件供应商是问你有多少MIPS需要。
I'll bet that your hardware vendor is asking how many MIPS you need.
如你需要一个1000 MIPS处理器或2000 MIPS处理器?
As in "Do you need a 1,000 MIPS processor or a 2,000 MIPS processor?"
它得到管理层翻译成有多少MIPS?
Which gets translated by management into "How many MIPS?"
硬件提供了MIPS。软件占用MIPS。
Hardware offers MIPS. Software consumes MIPS.
您有两个自由度。
-
该处理器的MIPS固有的产品。
The processor's inherent MIPS offering.
的秒数在此期间,你消耗很多MIPS。
The number of seconds during which you consume that many MIPS.
如果处理器没有足够的MIPS,你的算法将是慢
If the processor doesn't have enough MIPS, your algorithm will be "slow".
如果处理器有足够的MIPS,您算法将快速。
if the processor has enough MIPS, your algorithm will be "fast".
我把快,因为你需要有一个性能要求,确定足够快,以满足性能要求,或在引号慢,太慢以满足性能要求。
I put "fast" and "slow" in quotes because you need to have a performance requirement to determine "fast enough to meet the performance requirement" or "too slow to meet the performance requirement."
在2,000 MIPS处理器,你可能需要一个可接受的2秒。但在一个1000 MIPS处理器此爆炸到不可接受的4秒。
On a 2,000 MIPS processor, you might take an acceptable 2 seconds. But on a 1,000 MIPS processor this explodes to an unacceptable 4 seconds.
多少MIPS你需要什么?
How many MIPS do you need?
-
获取你的处理器正式MIPS。见http://en.wikipedia.org/wiki/Instructions_per_second
这是一些数据运行你的算法。
Run your algorithm on some data.
测量准确的运行时间。平均一堆样品,以减少不确定性。
Measure the exact run time. Average a bunch of samples to reduce uncertainty.
报告。在750 MIPS处理器3秒钟的时间 - 好 - 在750 MIPS 3秒。 MIPS是一种速率。时间就是时间。距离率*时代的产物。在750 MIPS 3秒钟的时间750 * 3百万指令。
Report. 3 seconds on a 750 MIPS processor is -- well -- 3 seconds at 750 MIPS. MIPS is a rate. Time is time. Distance is the product of rate * time. 3 seconds at 750 MIPS is 750*3 million instructions.
记住率(每秒的说明)*时间(以秒为单位)为您提供的说明。
Remember Rate (in Instructions per second) * Time (in seconds) gives you Instructions.
不要说这是3 * 750 MIPS。它不是;这是2250百万条指令。
Don't say that it's 3*750 MIPS. It isn't; it's 2250 Million Instructions.
这篇关于如何计算MIPS针对ARM处理器的算法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!