Skip to content

Commit 479afa8

Browse files
committed
Skip sub-test that triggers llvm bug
1 parent 2470267 commit 479afa8

1 file changed

Lines changed: 24 additions & 14 deletions

File tree

test/correctness/transpose_idioms.cpp

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -181,21 +181,31 @@ int main(int argc, char **argv) {
181181
// vector predicate on one of the two vectors, to be sure the simplifier
182182
// is transforming the predicate correctly. We can't predicate both,
183183
// because the vectorizer can't handle it and generates a scalar tail.
184-
{
185-
Func f{"f"}, g{"g"};
186-
f(x, y) = x + 100 * y;
187-
g(x, y) = f(y, x);
188-
f.compute_root();
189-
190-
g
191-
.never_partition(x, y)
192-
.split(x, x, xi, 13, TailStrategy::Predicate)
193-
.split(y, y, yi, 11, TailStrategy::ShiftInwards)
194-
.reorder(xi, yi, x, y)
195-
.vectorize(xi)
196-
.vectorize(yi);
197184

198-
check(g);
185+
{
186+
// LLVM 22/23 have a codegen bug for some x86 versions here, so skip with AVX512
187+
// See: https://github.com/llvm/llvm-project/issues/191304
188+
if (Internal::get_llvm_version() >= 220 &&
189+
Internal::get_llvm_version() < 240 &&
190+
get_jit_target_from_environment().has_feature(Target::AVX512)) {
191+
printf("Skipping one subtest for LLVM %d with AVX-512 due to known backend bugs.\n",
192+
Internal::get_llvm_version());
193+
} else {
194+
Func f{"f"}, g{"g"};
195+
f(x, y) = x + 100 * y;
196+
g(x, y) = f(y, x);
197+
f.compute_root();
198+
199+
g
200+
.never_partition(x, y)
201+
.split(x, x, xi, 13, TailStrategy::Predicate)
202+
.split(y, y, yi, 11, TailStrategy::ShiftInwards)
203+
.reorder(xi, yi, x, y)
204+
.vectorize(xi)
205+
.vectorize(yi);
206+
207+
check(g);
208+
}
199209
}
200210
{
201211
Func f{"f"}, g{"g"};

0 commit comments

Comments
 (0)