[Mlir-commits] [mlir] 1c93f09 - Remove declaration of constexpr member kDynamicSize in MemRefType

Mehdi Amini llvmlistbot at llvm.org
Sun Jul 26 21:50:21 PDT 2020


Author: Mehdi Amini
Date: 2020-07-27T04:50:08Z
New Revision: 1c93f09bf34c2f7a9e6b1753cc2edb41609cd544

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

LOG: Remove declaration of constexpr member kDynamicSize in MemRefType

This member is already publicly declared on the base class. The
redundant declaration is mangled differently though and in some
unoptimized build it requires a definition to also exist. However we
have a definition for the base ShapedType class, removing the
declaration here will redirect every use to the base class member
instead.

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

Added: 
    

Modified: 
    mlir/include/mlir/IR/StandardTypes.h

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir/IR/StandardTypes.h b/mlir/include/mlir/IR/StandardTypes.h
index 5380668b5901..1ac24359cbb6 100644
--- a/mlir/include/mlir/IR/StandardTypes.h
+++ b/mlir/include/mlir/IR/StandardTypes.h
@@ -564,7 +564,6 @@ class MemRefType : public Type::TypeBase<MemRefType, BaseMemRefType,
   // TODO: merge these two special values in a single one used everywhere.
   // Unfortunately, uses of `-1` have crept deep into the codebase now and are
   // hard to track.
-  static constexpr int64_t kDynamicSize = -1;
   static int64_t getDynamicStrideOrOffset() {
     return ShapedType::kDynamicStrideOrOffset;
   }


        


More information about the Mlir-commits mailing list