[Mlir-commits] [llvm] [mlir] [MLGO] Do not hardcode 33 eviction feature columns (PR #224598)

Arseniy Obolenskiy llvmlistbot at llvm.org
Wed Sep 30 02:55:34 PDT 2026


================
@@ -812,9 +854,11 @@ MCRegister MLEvictAdvisor::tryFindEvictionCandidate(
        ++FeatureIndex) {
     if (DoNotNormalize.test(FeatureIndex))
       continue;
+    // Skip the columns past ValidPosLimit: never written, so still 0.
     float *Tensor = Runner->getTensor<float>(FeatureIndex);
-    for (size_t Pos = 0; Pos < NumColumns; ++Pos)
-      Tensor[Pos] /= Largest[FeatureIndex];
+    for (size_t P = 0; P < ValidPosLimit; ++P)
----------------
aobolensk wrote:

reworked here

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


More information about the Mlir-commits mailing list