[Mlir-commits] [mlir] c990bdf - [mlir] Hotfix - Add inline to avoid multiple symbols on trivial functions
Nicolas Vasilache
llvmlistbot at llvm.org
Tue May 26 13:25:48 PDT 2020
Author: Nicolas Vasilache
Date: 2020-05-26T16:24:56-04:00
New Revision: c990bdf7f8761f047fac85615377835edf015698
URL: https://github.com/llvm/llvm-project/commit/c990bdf7f8761f047fac85615377835edf015698
DIFF: https://github.com/llvm/llvm-project/commit/c990bdf7f8761f047fac85615377835edf015698.diff
LOG: [mlir] Hotfix - Add inline to avoid multiple symbols on trivial functions
Added:
Modified:
mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h
Removed:
################################################################################
diff --git a/mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h b/mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h
index 13db3a2a88d2..168e877e5056 100644
--- a/mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h
+++ b/mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h
@@ -81,21 +81,21 @@ constexpr StringRef getPaddingAttrName() { return "padding"; }
/// Use to encode that a particular iterator type has parallel semantics.
constexpr StringRef getParallelIteratorTypeName() { return "parallel"; }
-bool isParallelIterator(Attribute attr) {
+inline bool isParallelIterator(Attribute attr) {
auto strAttr = attr.dyn_cast_or_null<StringAttr>();
return strAttr && strAttr.getValue() == getParallelIteratorTypeName();
}
/// Use to encode that a particular iterator type has reduction semantics.
constexpr StringRef getReductionIteratorTypeName() { return "reduction"; }
-bool isReductionIterator(Attribute attr) {
+inline bool isReductionIterator(Attribute attr) {
auto strAttr = attr.dyn_cast_or_null<StringAttr>();
return strAttr && strAttr.getValue() == getReductionIteratorTypeName();
}
/// Use to encode that a particular iterator type has window semantics.
constexpr StringRef getWindowIteratorTypeName() { return "window"; }
-bool isWindowIterator(Attribute attr) {
+inline bool isWindowIterator(Attribute attr) {
auto strAttr = attr.dyn_cast_or_null<StringAttr>();
return strAttr && strAttr.getValue() == getWindowIteratorTypeName();
}
More information about the Mlir-commits
mailing list