[llvm] [NFC][AArch64] Tests for guarding unrolling with scalable vec ins/ext (PR #81132)

Graham Hunter via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 8 05:54:41 PST 2024


================
@@ -0,0 +1,87 @@
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 3
+; RUN: opt -passes=loop-unroll,simplifycfg -S -mtriple aarch64 -mattr=+sve -aarch64-sve-vector-bits-min=128 %s | FileCheck %s -check-prefix=UNROLL-128
----------------
huntergr-arm wrote:

I'm not sure about this runline. I used it to make sure `<8 x float>` was not a legal type, but if 128b is the actual size of the vectors at runtime then we won't really be able to insert that much data. Should this be ignored, or be rejected by the verifier if we know that it may be a invalid operation?

I think I can write another test for a negative case, e.g. one with non-power-of-2 integers that would require promotion rather than being directly legal.

This work might need to be extended in future to cover cases where we would legalize both sides in the same way, but it's a start for now.

https://github.com/llvm/llvm-project/pull/81132


More information about the llvm-commits mailing list