[PATCH] D20030: [AArch64] Add option to disable speculation of triangle whose tail is the only latch block

Renato Golin via llvm-commits llvm-commits at lists.llvm.org
Tue May 24 11:10:57 PDT 2016


rengolin added a comment.

In http://reviews.llvm.org/D20030#437974, @bmakam wrote:

> The performance depends on the cost of the cbz here. On Kryo we see 3% gain with this patch whereas on A57 we see 10% regression. This branch seems to be mostly not taken and so when we place the cbz out of the critical path as show below (...)
>  the performance on A57 improves by 4%. I am not sure but it seems like the cost of cbz on A57 is higher than on Kryo.


This is interesting... I wasn't expecting that much of a difference, but sub-arch issues can cause massive changes.

Now, about the CBZ, it may be it, or it may be a class of instructions that are faster on Kryo, or it could be a red herring.

Regardless, I don't think we should limit this optimization with a FeatureFastCBZ flag, because that would be extrapolating without data. I really think that enabling this on all A64 will bring more problems than solve, but limiting on a flag or for Kryo only would be weird.

Since this doesn't seem to have a big impact, even for Kryo, I'm reluctant...

I'd welcome Tim's and James' point of view on this.

cheers,
--renato


http://reviews.llvm.org/D20030





More information about the llvm-commits mailing list