[llvm] [SLP] Move some of X86 tests to common directory (PR #107587)
Elvina Yakubova via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 9 09:21:28 PDT 2024
https://github.com/ElvinaYakubova updated https://github.com/llvm/llvm-project/pull/107587
>From 04574fa7624117a5b964e85c929c49e1626afc87 Mon Sep 17 00:00:00 2001
From: Elvina Yakubova <eyakubova at nvidia.com>
Date: Fri, 6 Sep 2024 06:06:03 -0700
Subject: [PATCH] [SLP] Move some of X86 tests to common directory
---
.../{X86 => }/ext-int-reduced-not-operand.ll | 9 ++++++---
.../{X86 => }/extended-vectorized-gathered-inst.ll | 3 ++-
.../external-user-instruction-minbitwidth.ll | 3 ++-
.../{X86 => }/extract-many-users-buildvector.ll | 3 ++-
.../{X86 => }/extractelement-insertpoint.ll | 3 ++-
.../{X86 => }/extractlements-gathered-first-node.ll | 3 ++-
.../SLPVectorizer/{X86 => }/extracts-with-undefs.ll | 3 ++-
.../{X86 => }/gather_extract_from_vectorbuild.ll | 3 ++-
.../{X86 => }/gep-with-extractelement-many-users.ll | 3 ++-
.../SLPVectorizer/{X86 => }/insert-crash-index.ll | 3 ++-
.../insert-element-build-vector-const-undef.ll | 3 ++-
.../insert-element-build-vector-inseltpoison.ll | 12 ++++++------
.../{X86 => }/insert-element-build-vector.ll | 12 ++++++------
.../{X86 => }/insert-element-multiple-uses.ll | 3 ++-
.../{X86 => }/insertelement-postpone.ll | 3 ++-
.../{X86 => }/insertelement-uses-vectorized-index.ll | 3 ++-
.../{X86 => }/int-bitcast-minbitwidth.ll | 3 ++-
.../SLPVectorizer/{X86 => }/jumbled_store_crash.ll | 3 ++-
.../minbitwidth-multiuse-with-insertelement.ll | 3 ++-
.../{X86 => }/minbitwidth-node-with-multi-users.ll | 3 ++-
.../{X86 => }/minbitwidth-user-not-min.ll | 3 ++-
.../{X86 => }/multi-node-vectorized-insts.ll | 3 ++-
.../{X86 => }/multi-uses-with-deps-in-first.ll | 4 +++-
.../SLPVectorizer/{X86 => }/one-element-vector.ll | 3 ++-
24 files changed, 61 insertions(+), 36 deletions(-)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/ext-int-reduced-not-operand.ll (71%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/extended-vectorized-gathered-inst.ll (91%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/external-user-instruction-minbitwidth.ll (90%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/extract-many-users-buildvector.ll (94%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/extractelement-insertpoint.ll (84%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/extractlements-gathered-first-node.ll (66%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/extracts-with-undefs.ll (92%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/gather_extract_from_vectorbuild.ll (95%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/gep-with-extractelement-many-users.ll (73%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insert-crash-index.ll (91%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insert-element-build-vector-const-undef.ll (83%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insert-element-build-vector-inseltpoison.ll (96%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insert-element-build-vector.ll (96%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insert-element-multiple-uses.ll (85%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insertelement-postpone.ll (90%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/insertelement-uses-vectorized-index.ll (84%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/int-bitcast-minbitwidth.ll (82%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/jumbled_store_crash.ll (95%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/minbitwidth-multiuse-with-insertelement.ll (84%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/minbitwidth-node-with-multi-users.ll (91%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/minbitwidth-user-not-min.ll (90%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/multi-node-vectorized-insts.ll (94%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/multi-uses-with-deps-in-first.ll (87%)
rename llvm/test/Transforms/SLPVectorizer/{X86 => }/one-element-vector.ll (74%)
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/ext-int-reduced-not-operand.ll b/llvm/test/Transforms/SLPVectorizer/ext-int-reduced-not-operand.ll
similarity index 71%
rename from llvm/test/Transforms/SLPVectorizer/X86/ext-int-reduced-not-operand.ll
rename to llvm/test/Transforms/SLPVectorizer/ext-int-reduced-not-operand.ll
index 2ff6785c0da640..d8021538252c82 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/ext-int-reduced-not-operand.ll
+++ b/llvm/test/Transforms/SLPVectorizer/ext-int-reduced-not-operand.ll
@@ -1,7 +1,10 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999\
-; RUN: -slp-skip-early-profitability-check < %s | FileCheck %s --check-prefixes=FORCED
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s %}
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999\
+; RUN: -slp-skip-early-profitability-check < %s | FileCheck %s --check-prefixes=FORCED %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -slp-threshold=-99999\
+; RUN: -slp-skip-early-profitability-check < %s | FileCheck %s --check-prefixes=FORCED %}
define i64 @wombat() {
; FORCED-LABEL: define i64 @wombat() {
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/extended-vectorized-gathered-inst.ll b/llvm/test/Transforms/SLPVectorizer/extended-vectorized-gathered-inst.ll
similarity index 91%
rename from llvm/test/Transforms/SLPVectorizer/X86/extended-vectorized-gathered-inst.ll
rename to llvm/test/Transforms/SLPVectorizer/extended-vectorized-gathered-inst.ll
index 2d028060f49143..94aa8de5fdb72c 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/extended-vectorized-gathered-inst.ll
+++ b/llvm/test/Transforms/SLPVectorizer/extended-vectorized-gathered-inst.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux < %s | FileCheck %s %}
define void @test(ptr %top) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/external-user-instruction-minbitwidth.ll b/llvm/test/Transforms/SLPVectorizer/external-user-instruction-minbitwidth.ll
similarity index 90%
rename from llvm/test/Transforms/SLPVectorizer/X86/external-user-instruction-minbitwidth.ll
rename to llvm/test/Transforms/SLPVectorizer/external-user-instruction-minbitwidth.ll
index f58379b46dc19e..07dab9f53b1b0f 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/external-user-instruction-minbitwidth.ll
+++ b/llvm/test/Transforms/SLPVectorizer/external-user-instruction-minbitwidth.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
@e = global i8 0
@c = global i16 0
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/extract-many-users-buildvector.ll b/llvm/test/Transforms/SLPVectorizer/extract-many-users-buildvector.ll
similarity index 94%
rename from llvm/test/Transforms/SLPVectorizer/X86/extract-many-users-buildvector.ll
rename to llvm/test/Transforms/SLPVectorizer/extract-many-users-buildvector.ll
index 87b1302e4cecf4..261ec2b3935d7e 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/extract-many-users-buildvector.ll
+++ b/llvm/test/Transforms/SLPVectorizer/extract-many-users-buildvector.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
-; RUN: opt -S -passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define i1 @test(float %0, double %1) {
; CHECK-LABEL: define i1 @test
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/extractelement-insertpoint.ll b/llvm/test/Transforms/SLPVectorizer/extractelement-insertpoint.ll
similarity index 84%
rename from llvm/test/Transforms/SLPVectorizer/X86/extractelement-insertpoint.ll
rename to llvm/test/Transforms/SLPVectorizer/extractelement-insertpoint.ll
index 8c51a907998a4b..94c361caf90fa5 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/extractelement-insertpoint.ll
+++ b/llvm/test/Transforms/SLPVectorizer/extractelement-insertpoint.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer -mtriple=x86_64-grtev4-linux-gnu -o - < %s | FileCheck %s
+; RUN: %if x86_64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=x86_64-grtev4-linux-gnu -o - < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -o - < %s | FileCheck %s %}
define i32 @crash() {
; CHECK-LABEL: @crash(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/extractlements-gathered-first-node.ll b/llvm/test/Transforms/SLPVectorizer/extractlements-gathered-first-node.ll
similarity index 66%
rename from llvm/test/Transforms/SLPVectorizer/X86/extractlements-gathered-first-node.ll
rename to llvm/test/Transforms/SLPVectorizer/extractlements-gathered-first-node.ll
index d5f2cf7fc28c46..9afd47e18b72b4 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/extractlements-gathered-first-node.ll
+++ b/llvm/test/Transforms/SLPVectorizer/extractlements-gathered-first-node.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -slp-threshold=-99999 -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -slp-threshold=-99999 -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -slp-threshold=-99999 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test() {
; CHECK-LABEL: define void @test() {
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/extracts-with-undefs.ll b/llvm/test/Transforms/SLPVectorizer/extracts-with-undefs.ll
similarity index 92%
rename from llvm/test/Transforms/SLPVectorizer/X86/extracts-with-undefs.ll
rename to llvm/test/Transforms/SLPVectorizer/extracts-with-undefs.ll
index b6de2d4fbcb11f..dca34b681032c4 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/extracts-with-undefs.ll
+++ b/llvm/test/Transforms/SLPVectorizer/extracts-with-undefs.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -passes=slp-vectorizer -S -mtriple=x86_64-unknown-linux-gnu | FileCheck %s
+; RUN: %if x86-registered-target %{ opt < %s -passes=slp-vectorizer -S -mtriple=x86_64-unknown-linux-gnu | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt < %s -passes=slp-vectorizer -S -mtriple=aarch64-unknown-linux-gnu | FileCheck %s %}
define void @test() {
; CHECK-LABEL: @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/gather_extract_from_vectorbuild.ll b/llvm/test/Transforms/SLPVectorizer/gather_extract_from_vectorbuild.ll
similarity index 95%
rename from llvm/test/Transforms/SLPVectorizer/X86/gather_extract_from_vectorbuild.ll
rename to llvm/test/Transforms/SLPVectorizer/gather_extract_from_vectorbuild.ll
index dd5c52b99d00e8..c1ec9b8eeadff8 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/gather_extract_from_vectorbuild.ll
+++ b/llvm/test/Transforms/SLPVectorizer/gather_extract_from_vectorbuild.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -passes=slp-vectorizer -S -mtriple=x86_64 < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -passes=slp-vectorizer -S -mtriple=x86_64 < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -passes=slp-vectorizer -S -mtriple=aarch64 < %s | FileCheck %s %}
; Vectorization tree roots at vector build sequence (insertelement),
; SLP crashed on generating vector code for pair {%i4, 0.0} trying to produce
; a shuffle with %ins1 as a source because it was marked deleted
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/gep-with-extractelement-many-users.ll b/llvm/test/Transforms/SLPVectorizer/gep-with-extractelement-many-users.ll
similarity index 73%
rename from llvm/test/Transforms/SLPVectorizer/X86/gep-with-extractelement-many-users.ll
rename to llvm/test/Transforms/SLPVectorizer/gep-with-extractelement-many-users.ll
index cea95c11024976..996ed8791bbb32 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/gep-with-extractelement-many-users.ll
+++ b/llvm/test/Transforms/SLPVectorizer/gep-with-extractelement-many-users.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -slp-threshold=-99999 < %s | FileCheck %s %}
define void @test() {
; CHECK-LABEL: define void @test() {
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insert-crash-index.ll b/llvm/test/Transforms/SLPVectorizer/insert-crash-index.ll
similarity index 91%
rename from llvm/test/Transforms/SLPVectorizer/X86/insert-crash-index.ll
rename to llvm/test/Transforms/SLPVectorizer/insert-crash-index.ll
index 9d7ba5a8b30331..e9341979254074 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insert-crash-index.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insert-crash-index.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
; These all crashing before patch
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-const-undef.ll b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-const-undef.ll
similarity index 83%
rename from llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-const-undef.ll
rename to llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-const-undef.ll
index d9f396677a6a47..48b5145622bdfe 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-const-undef.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-const-undef.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=0 < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define <4 x float> @simple_select(<4 x float> %a, <4 x float> %b, <4 x i32> %c) {
; CHECK-LABEL: @simple_select(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-inseltpoison.ll b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-inseltpoison.ll
similarity index 96%
rename from llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-inseltpoison.ll
rename to llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-inseltpoison.ll
index fd9528aa8df3ab..5f02b0009367c7 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector-inseltpoison.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector-inseltpoison.ll
@@ -1,10 +1,10 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=-10000 < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=0 < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE
-
-target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-n8:16:32:64-S128"
-target triple = "x86_64-apple-macosx10.8.0"
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD %}
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD %}
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE %}
define <4 x float> @simple_select(<4 x float> %a, <4 x float> %b, <4 x i32> %c) #0 {
; CHECK-LABEL: @simple_select(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector.ll b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector.ll
similarity index 96%
rename from llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector.ll
rename to llvm/test/Transforms/SLPVectorizer/insert-element-build-vector.ll
index 18d5b09001762b..63d55f7b1deb58 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-build-vector.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insert-element-build-vector.ll
@@ -1,10 +1,10 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=-10000 < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=0 < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD
-; RUN: opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE
-
-target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-n8:16:32:64-S128"
-target triple = "x86_64-apple-macosx10.8.0"
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD %}
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD %}
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 -mtriple=x86_64-unknown-unknown < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,THRESHOLD %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=0 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,NOTHRESHOLD %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -slp-threshold=-10000 -slp-min-tree-size=0 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,MINTREESIZE %}
define <4 x float> @simple_select(<4 x float> %a, <4 x float> %b, <4 x i32> %c) #0 {
; CHECK-LABEL: @simple_select(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-multiple-uses.ll b/llvm/test/Transforms/SLPVectorizer/insert-element-multiple-uses.ll
similarity index 85%
rename from llvm/test/Transforms/SLPVectorizer/X86/insert-element-multiple-uses.ll
rename to llvm/test/Transforms/SLPVectorizer/insert-element-multiple-uses.ll
index 1b684e9060756e..0059a5feb1e9eb 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insert-element-multiple-uses.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insert-element-multiple-uses.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @main() {
; CHECK-LABEL: @main(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insertelement-postpone.ll b/llvm/test/Transforms/SLPVectorizer/insertelement-postpone.ll
similarity index 90%
rename from llvm/test/Transforms/SLPVectorizer/X86/insertelement-postpone.ll
rename to llvm/test/Transforms/SLPVectorizer/insertelement-postpone.ll
index 3fc6fe9e60611a..1e4b598d9fe923 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insertelement-postpone.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insertelement-postpone.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -passes=slp-vectorizer -mtriple x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S -passes=slp-vectorizer -mtriple x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S -passes=slp-vectorizer -mtriple aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define <4 x double> @test(ptr %p2, double %i1754, double %i1781, double %i1778) {
; CHECK-LABEL: @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/insertelement-uses-vectorized-index.ll b/llvm/test/Transforms/SLPVectorizer/insertelement-uses-vectorized-index.ll
similarity index 84%
rename from llvm/test/Transforms/SLPVectorizer/X86/insertelement-uses-vectorized-index.ll
rename to llvm/test/Transforms/SLPVectorizer/insertelement-uses-vectorized-index.ll
index 78b3f8b1012845..94f973e606436e 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/insertelement-uses-vectorized-index.ll
+++ b/llvm/test/Transforms/SLPVectorizer/insertelement-uses-vectorized-index.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 5
-; RUN: opt -S --passes=slp-vectorizer -slp-threshold=-10 < %s -mtriple=x86_64-pc-windows-msvc19.39.33523 | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -slp-threshold=-10 < %s -mtriple=x86_64-pc-windows-msvc19.39.33523 | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -slp-threshold=-10 < %s -mtriple=aarch64-unknown-linux-gnu | FileCheck %s %}
define void @test(ptr %0) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/int-bitcast-minbitwidth.ll b/llvm/test/Transforms/SLPVectorizer/int-bitcast-minbitwidth.ll
similarity index 82%
rename from llvm/test/Transforms/SLPVectorizer/X86/int-bitcast-minbitwidth.ll
rename to llvm/test/Transforms/SLPVectorizer/int-bitcast-minbitwidth.ll
index 97e505f4319c6b..766deccf1250b8 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/int-bitcast-minbitwidth.ll
+++ b/llvm/test/Transforms/SLPVectorizer/int-bitcast-minbitwidth.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-9 < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -slp-threshold=-9 < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -slp-threshold=-9 < %s | FileCheck %s %}
define void @t(i64 %v) {
; CHECK-LABEL: define void @t(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/jumbled_store_crash.ll b/llvm/test/Transforms/SLPVectorizer/jumbled_store_crash.ll
similarity index 95%
rename from llvm/test/Transforms/SLPVectorizer/X86/jumbled_store_crash.ll
rename to llvm/test/Transforms/SLPVectorizer/jumbled_store_crash.ll
index bb1aac8fb932c9..f53e22d89d5169 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/jumbled_store_crash.ll
+++ b/llvm/test/Transforms/SLPVectorizer/jumbled_store_crash.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -o - -S < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu -o - -S < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu -o - -S < %s | FileCheck %s %}
@b = common dso_local global ptr null, align 8
@e = common dso_local global float 0.000000e+00, align 4
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-multiuse-with-insertelement.ll b/llvm/test/Transforms/SLPVectorizer/minbitwidth-multiuse-with-insertelement.ll
similarity index 84%
rename from llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-multiuse-with-insertelement.ll
rename to llvm/test/Transforms/SLPVectorizer/minbitwidth-multiuse-with-insertelement.ll
index 6051638562b59b..97341d1b490378 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-multiuse-with-insertelement.ll
+++ b/llvm/test/Transforms/SLPVectorizer/minbitwidth-multiuse-with-insertelement.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -passes=slp-vectorizer -S -slp-threshold=-10 -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -passes=slp-vectorizer -S -slp-threshold=-10 -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -passes=slp-vectorizer -S -slp-threshold=-10 -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test(i8 %0) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-node-with-multi-users.ll b/llvm/test/Transforms/SLPVectorizer/minbitwidth-node-with-multi-users.ll
similarity index 91%
rename from llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-node-with-multi-users.ll
rename to llvm/test/Transforms/SLPVectorizer/minbitwidth-node-with-multi-users.ll
index ef07e337246632..a7f86292138907 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-node-with-multi-users.ll
+++ b/llvm/test/Transforms/SLPVectorizer/minbitwidth-node-with-multi-users.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test() {
; CHECK-LABEL: define void @test() {
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-user-not-min.ll b/llvm/test/Transforms/SLPVectorizer/minbitwidth-user-not-min.ll
similarity index 90%
rename from llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-user-not-min.ll
rename to llvm/test/Transforms/SLPVectorizer/minbitwidth-user-not-min.ll
index 50b19d01ad58f1..f07a2128dfeb48 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/minbitwidth-user-not-min.ll
+++ b/llvm/test/Transforms/SLPVectorizer/minbitwidth-user-not-min.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test(ptr %block, ptr noalias %pixels, i1 %b) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/multi-node-vectorized-insts.ll b/llvm/test/Transforms/SLPVectorizer/multi-node-vectorized-insts.ll
similarity index 94%
rename from llvm/test/Transforms/SLPVectorizer/X86/multi-node-vectorized-insts.ll
rename to llvm/test/Transforms/SLPVectorizer/multi-node-vectorized-insts.ll
index 3b54b0a058d0c6..8abc6ef236a3c0 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/multi-node-vectorized-insts.ll
+++ b/llvm/test/Transforms/SLPVectorizer/multi-node-vectorized-insts.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 3
-; RUN: opt -passes=slp-vectorizer -S -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -passes=slp-vectorizer -S -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -passes=slp-vectorizer -S -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test(double %0) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/multi-uses-with-deps-in-first.ll b/llvm/test/Transforms/SLPVectorizer/multi-uses-with-deps-in-first.ll
similarity index 87%
rename from llvm/test/Transforms/SLPVectorizer/X86/multi-uses-with-deps-in-first.ll
rename to llvm/test/Transforms/SLPVectorizer/multi-uses-with-deps-in-first.ll
index 998efaa5c0351c..a8942596a99de5 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/multi-uses-with-deps-in-first.ll
+++ b/llvm/test/Transforms/SLPVectorizer/multi-uses-with-deps-in-first.ll
@@ -1,5 +1,7 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 3
-; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-pc-linux-gnu < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-pc-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
+
define void @test(double %add) {
; CHECK-LABEL: define void @test(
diff --git a/llvm/test/Transforms/SLPVectorizer/X86/one-element-vector.ll b/llvm/test/Transforms/SLPVectorizer/one-element-vector.ll
similarity index 74%
rename from llvm/test/Transforms/SLPVectorizer/X86/one-element-vector.ll
rename to llvm/test/Transforms/SLPVectorizer/one-element-vector.ll
index 5380b82bba2ed3..cab9188832284d 100644
--- a/llvm/test/Transforms/SLPVectorizer/X86/one-element-vector.ll
+++ b/llvm/test/Transforms/SLPVectorizer/one-element-vector.ll
@@ -1,5 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 3
-; RUN: opt -S --passes=slp-vectorizer < %s | FileCheck %s
+; RUN: %if x86-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s %}
+; RUN: %if aarch64-registered-target %{ opt -S --passes=slp-vectorizer -mtriple=aarch64-unknown-linux-gnu < %s | FileCheck %s %}
define void @test() {
; CHECK-LABEL: define void @test() {
More information about the llvm-commits
mailing list