This is an archive of the discontinued LLVM Phabricator instance.

[AArch64] Sets the preferred function alignment for Cortex-A53/A55
ClosedPublic

Authored by stelios-arm on Apr 30 2021, 7:57 AM.

Details

Summary

Setting the preferred function alignment to 16 for Cortex A53/A55 improves performance in a wide range of benchmarks. This brings it in line with the
Cortex-A53/A55 tuning that is used in GCC (gcc/config/aarch64/aarch64.c).

Diff Detail

Event Timeline

stelios-arm created this revision.Apr 30 2021, 7:57 AM
stelios-arm requested review of this revision.Apr 30 2021, 7:57 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 30 2021, 7:57 AM
SjoerdMeijer added a comment.EditedApr 30 2021, 9:40 AM

Just for completeness, I checked that GCC indeed sets it 16, here:

https://github.com/gcc-mirror/gcc/blob/71834be5b68e0c9839f0647e1bbf1eec4e4bbf49/gcc/config/aarch64/aarch64.c#L1277

Are we not adding tests for these kind of things?

The test that needs updating is in CodeGen/AArch64/preferred-function-alignment.ll

Modified the Cortex-A53 test and added one for Cortex-A55.

dmgreen accepted this revision.May 2 2021, 12:20 PM

Sounds good to me.

This revision is now accepted and ready to land.May 2 2021, 12:20 PM