[PATCH] D157968: [NFC][AArch64][LV] Reorganise tests for using SLEEF symbols in LV.

Jolanta Jensen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 15 10:08:50 PDT 2023


jolanta.jensen added inline comments.


================
Comment at: llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll:1
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
+; Do NOT use -O3. It will lower exp2 to ldexp, and the test will fail.
----------------
mgabka wrote:
> 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.
Using --filter and regexp and the check lines are truly auto-generated now.


================
Comment at: llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll:2
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
+; Do NOT use -O3. It will lower exp2 to ldexp, and the test will fail.
+; RUN: opt -vector-library=sleefgnuabi -passes=inject-tli-mappings,loop-vectorize -S < %s | FileCheck %s --check-prefixes=CHECK,NEON
----------------
mgabka wrote:
> this comment is redundant, please remove it.
> In such tests we should always only use the min required nr of passes.
Done.


================
Comment at: llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll:3
+; Do NOT use -O3. It will lower exp2 to ldexp, and the test will fail.
+; RUN: opt -vector-library=sleefgnuabi -passes=inject-tli-mappings,loop-vectorize -S < %s | FileCheck %s --check-prefixes=CHECK,NEON
+; RUN: opt -mattr=+sve -vector-library=sleefgnuabi -passes=inject-tli-mappings,loop-vectorize -S < %s | FileCheck %s --check-prefixes=CHECK,SVE
----------------
mgabka wrote:
> please also use "-force-vector-interleave=1" to disable interleaving and reduce the number of generated checks, same applies to the other run line
Fixed.


================
Comment at: llvm/test/Transforms/LoopVectorize/AArch64/sleef-intrinsic-calls-aarch64.ll:13
+
+declare double @llvm.ceil.f64(double) #0
+declare float @llvm.ceil.f32(float) #0
----------------
mgabka wrote:
> this attribute is never defined, so it is not used, please remove its all occurrences.
Done.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D157968/new/

https://reviews.llvm.org/D157968



More information about the llvm-commits mailing list