[Mlir-commits] [mlir] be4ced6 - [MLIR] NFC. Make affine analysis utils method const correct

Uday Bondhugula llvmlistbot at llvm.org
Sun May 14 04:57:32 PDT 2023


Author: Uday Bondhugula
Date: 2023-05-14T17:26:59+05:30
New Revision: be4ced691f547a6f891f783a437fe94308bd5070

URL: https://github.com/llvm/llvm-project/commit/be4ced691f547a6f891f783a437fe94308bd5070
DIFF: https://github.com/llvm/llvm-project/commit/be4ced691f547a6f891f783a437fe94308bd5070.diff

LOG: [MLIR] NFC. Make affine analysis utils method const correct

Make isSliceValid const correct. NFC.

Added: 
    

Modified: 
    mlir/include/mlir/Dialect/Affine/Analysis/Utils.h
    mlir/lib/Dialect/Affine/Analysis/Utils.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir/Dialect/Affine/Analysis/Utils.h b/mlir/include/mlir/Dialect/Affine/Analysis/Utils.h
index f86ae7a14de67..518fd5cfcbba8 100644
--- a/mlir/include/mlir/Dialect/Affine/Analysis/Utils.h
+++ b/mlir/include/mlir/Dialect/Affine/Analysis/Utils.h
@@ -312,7 +312,7 @@ struct ComputationSliceState {
   /// return false as it implies that the effective fusion results in at least
   /// one iteration of the slice that was not originally in the source's domain.
   /// If the validity cannot be determined, returns std::nullopt.
-  std::optional<bool> isSliceValid();
+  std::optional<bool> isSliceValid() const;
 
   void dump() const;
 

diff  --git a/mlir/lib/Dialect/Affine/Analysis/Utils.cpp b/mlir/lib/Dialect/Affine/Analysis/Utils.cpp
index 4433d94eb1454..f0caa2eb36d2f 100644
--- a/mlir/lib/Dialect/Affine/Analysis/Utils.cpp
+++ b/mlir/lib/Dialect/Affine/Analysis/Utils.cpp
@@ -687,7 +687,7 @@ std::optional<bool> ComputationSliceState::isSliceMaximalFastCheck() const {
 /// Returns true if it is deterministically verified that the original iteration
 /// space of the slice is contained within the new iteration space that is
 /// created after fusing 'this' slice into its destination.
-std::optional<bool> ComputationSliceState::isSliceValid() {
+std::optional<bool> ComputationSliceState::isSliceValid() const {
   // Fast check to determine if the slice is valid. If the following conditions
   // are verified to be true, slice is declared valid by the fast check:
   // 1. Each slice loop is a single iteration loop bound in terms of a single


        


More information about the Mlir-commits mailing list