在优化霓虹灯code有些疑惑 [英] Some doubts in optimizing the neon code

查看:336
本文介绍了在优化霓虹灯code有些疑惑的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我写汇编一些霓虹灯code和瞄准最大的优化。虽然数字似乎令人满意,我是有兴趣了解进一步优化它的可能性。然后,我遇到了一个在线工具,它有助于计算每个指令的周期。

I wrote some neon code in assembly and was aiming for maximum optimization. Though the numbers seem satisfactory, I was interested in understanding the possibilities of optimizing it further. Then I came across an online tool which helps in counting the cycles of each instruction.

下面那张链接到我的code: http://pulsar.webshaker.net / CCC /采样115d4c29

Here goes the link to my code: http://pulsar.webshaker.net/ccc/sample-115d4c29

这清楚地标明我关注的领域,但我不能清楚地了解这些语句包含开销的原因。

It clearly marked the areas of my concern, but I could not clearly understand the reason for those statements to contain the overheads.

在code段被分成7段在评论区域,使其更容易为参考。

The code segment is divided into 7 sections in the 'comment' area to make it easier for referring.

在此先感谢。 :)

推荐答案

你可以试试这个链接

http://pulsar.webshaker.net/ccc/beta-sample-115d4c29

这使用周期计数器的beta版本0.9。
的主要区别在于,NEON模拟器不使用2 distincts管道了。
由于皮质A9,不能在一个周期内执行2 NEON指令

this use the beta version 0.9 of the cycle counter. The main difference is that NEON simulator do not use 2 distincts pipelines anymore. Due to Cortex A9 that can't execute 2 NEON instructions in one cycle.

我开始UDPATE循环计数器的某些部分。

I Started to udpate some part of the cycle counter.

结果是:

-The周期的信息是的Cortex A9更准确。

-The cycle information are more accurate for Cortex A9.

-The结果更容易阅读,因为大部分的NEON延迟信息是由于未配对的指令。

-The result is easier to read because most of NEON latency information are due to unpaired instructions.

橙色平均潜伏期由于等待管道

Orange color mean latency due to waiting for pipeline

红色的意思是,由于登记冲突延迟。

Red color mean latency due to register conflict.

寄存器邻近指定的数字是不松动循环的数目。这是指令的最大数量,你可以此指令前放置。

The number spécified near the register is not the number of loosed cycles. This is the max number of instructions you could place before this instruction.

我希望有所帮助!

这篇关于在优化霓虹灯code有些疑惑的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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