This is an archive of the discontinued LLVM Phabricator instance.

[NFC][AArch64][LV] Reorganise tests for using SLEEF symbols in LV.
Needs ReviewPublic

Authored by jolanta.jensen on Aug 15 2023, 5:14 AM.

Details

Summary

The tests introduced by https://reviews.llvm.org/D134719 and later
modified in https://reviews.llvm.org/D146839 are not testing LV in
isolation. This patch:

  1. Assures that all tests test LV in isolation.
  2. Adds LV tests using llvm intrinsics that have libm mappings.

llrint, llround and lrint are not included as currently
IR verifier pass does not allow to use vector types with them.

Diff Detail

Unit TestsFailed

Event Timeline

jolanta.jensen created this revision.Aug 15 2023, 5:14 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 15 2023, 5:14 AM
jolanta.jensen requested review of this revision.Aug 15 2023, 5:14 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 15 2023, 5:14 AM

please apply my comments to sleef-intrinsic-calls-aarch64.ll also to the sleef-calls-aarch64.ll

llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll
2

this is not true, however I realised that these tests can be generated when you use a --filter regexp option, for example --filter "(ceil)|(copysign)|(cos)|....", and I think that would be my preferred form to generate check lines, as it will be easy to regenerate them.

3

this comment is redundant, please remove it.
In such tests we should always only use the min required nr of passes.

4

please also use "-force-vector-interleave=1" to disable interleaving and reduce the number of generated checks, same applies to the other run line

14

this attribute is never defined, so it is not used, please remove its all occurrences.

Addressing review comments.

llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll
2

Using --filter and regexp and the check lines are truly auto-generated now.

3

Done.

4

Fixed.

14

Done.

jolanta.jensen added inline comments.Aug 16 2023, 1:36 AM
llvm/test/Transforms/LoopVectorize/AArch64/sleef-calls-aarch64.ll
2–3

Not a bug but --check-prefix would be nicer as there is only one argument.

697–700

May be worth a comment why it looks this way.

Addressing my own comments.

jolanta.jensen added inline comments.Aug 16 2023, 9:55 AM
llvm/test/Transforms/LoopVectorize/AArch64/sleef-calls-aarch64.ll
2–3

Fixed.

697–700

Fixed. Comment on line 658.