[Mlir-commits] [mlir] [mlir][DataLayout] Add a default memory space entry to the data layout. (PR #127416)
Rolf Morel
llvmlistbot at llvm.org
Mon Mar 10 13:56:42 PDT 2025
================
@@ -344,6 +327,27 @@ combineOneSpec(DataLayoutSpecInterface spec,
return failure();
}
+ // Try overwriting the old entries with the new ones.
+ for (auto &kvp : newEntriesForType) {
+ if (!entriesForType.count(kvp.first)) {
+ entriesForType[kvp.first] = std::move(kvp.second);
+ continue;
+ }
+
+ Type typeSample = cast<Type>(kvp.second.front().getKey());
+ assert(&typeSample.getDialect() !=
+ typeSample.getContext()->getLoadedDialect<BuiltinDialect>() &&
+ "unexpected data layout entry for built-in type");
+
+ auto interface = cast<DataLayoutTypeInterface>(typeSample);
+ // TODO: Revisit this method and call once issue #130321 gets resolved.
----------------
rolfmorel wrote:
nit: could we include the full URL? I am just looking to lower the barrier regarding someone coming across this and actually fixing this.
https://github.com/llvm/llvm-project/pull/127416
More information about the Mlir-commits
mailing list