[Mlir-commits] [mlir] 0e1429a - [mlir][sparse] fix build error.

Peiming Liu llvmlistbot at llvm.org
Thu May 4 10:30:19 PDT 2023


Author: Peiming Liu
Date: 2023-05-04T17:30:13Z
New Revision: 0e1429add57f4c33da9dbc2bc5c9de7654f3b32d

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

LOG: [mlir][sparse] fix build error.

Reviewed By: aartbik, vzakhari

Differential Revision: https://reviews.llvm.org/D149874

Added: 
    

Modified: 
    mlir/lib/Dialect/SparseTensor/Transforms/CodegenEnv.h
    mlir/lib/Dialect/SparseTensor/Transforms/LoopEmitter.h

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/SparseTensor/Transforms/CodegenEnv.h b/mlir/lib/Dialect/SparseTensor/Transforms/CodegenEnv.h
index bf8bd722a50a..d9ef20220cae 100644
--- a/mlir/lib/Dialect/SparseTensor/Transforms/CodegenEnv.h
+++ b/mlir/lib/Dialect/SparseTensor/Transforms/CodegenEnv.h
@@ -89,7 +89,7 @@ class CodegenEnv {
   // LoopEmitter delegates.
   //
 
-  constexpr TensorLevel makeTensorLevel(TensorId t, Level l) const {
+  TensorLevel makeTensorLevel(TensorId t, Level l) const {
     // Make sure LoopEmitter, GenericOp, and Merger agree on the number of
     // tensors. Merger has one more synthetic tensor for loop invariants.
     assert(loopEmitter.getNumTensors() == linalgOp->getNumOperands() &&

diff  --git a/mlir/lib/Dialect/SparseTensor/Transforms/LoopEmitter.h b/mlir/lib/Dialect/SparseTensor/Transforms/LoopEmitter.h
index fe4354de3bb4..67a3f3d038a1 100644
--- a/mlir/lib/Dialect/SparseTensor/Transforms/LoopEmitter.h
+++ b/mlir/lib/Dialect/SparseTensor/Transforms/LoopEmitter.h
@@ -195,7 +195,7 @@ class LoopEmitter {
   unsigned getNumTensors() const { return tensors.size(); }
 
   /// Compresses a TensorId and Level into a TensorLevel.
-  constexpr TensorLevel makeTensorLevel(TensorId t, Level l) const {
+  TensorLevel makeTensorLevel(TensorId t, Level l) const {
     return l * getNumTensors() + t;
   }
 


        


More information about the Mlir-commits mailing list