[llvm] [LV] Fix missing REQUIRES: asserts in test (PR #151737)

Ramkumar Ramachandra via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 1 10:32:42 PDT 2025


https://github.com/artagnon updated https://github.com/llvm/llvm-project/pull/151737

>From 696f4084dfd07afa41df34c6be16a0b822b58748 Mon Sep 17 00:00:00 2001
From: Ramkumar Ramachandra <ramkumar.ramachandra at codasip.com>
Date: Fri, 1 Aug 2025 18:23:45 +0100
Subject: [PATCH] [LV] Fix missing REQURIES: asserts in test

e7200c7 ([LV] Pre-commit test for #151664) forgot to require asserts in
the test, and stripped a CHECK line in error. Fix this.
---
 .../AArch64/pr151664-cost-hoisted-vector-scalable.ll         | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/llvm/test/Transforms/LoopVectorize/AArch64/pr151664-cost-hoisted-vector-scalable.ll b/llvm/test/Transforms/LoopVectorize/AArch64/pr151664-cost-hoisted-vector-scalable.ll
index bdff766110238..8495deea31e8b 100644
--- a/llvm/test/Transforms/LoopVectorize/AArch64/pr151664-cost-hoisted-vector-scalable.ll
+++ b/llvm/test/Transforms/LoopVectorize/AArch64/pr151664-cost-hoisted-vector-scalable.ll
@@ -1,12 +1,13 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --check-globals none --filter-out-after "^scalar.ph" --version 5
+; REQUIRES: asserts
 ; RUN: opt -passes=loop-vectorize -mtriple=aarch64 -mattr=+sve -S \
 ; RUN:   -debug-only=loop-vectorize %s 2>&1 | FileCheck %s
 
 ; FIXME: Hoisted vector code should be costed with scalable cost.
 ; In this example, `<vscale x 4 x float> @llvm.minimumnum` has an invalid cost,
-; and hence should not be produced by LoopVectorize. Unfortunately, what is
-; actually costed is `<4 x float> @llvm.minimumnum`.
+; and hence should not be produced by LoopVectorize.
 
+; CHECK: LV: Found an estimated cost of Invalid for VF vscale x 4 For instruction:   %res = tail call float @llvm.minimumnum.f32(float %arg, float 0.000000e+00)
 define void @cost_hoisted_vector_code(ptr %p, float %arg) {
 ; CHECK-LABEL: define void @cost_hoisted_vector_code(
 ; CHECK-SAME: ptr [[P:%.*]], float [[ARG:%.*]]) #[[ATTR0:[0-9]+]] {



More information about the llvm-commits mailing list