This builds a compound type for the buffers required for the sparse storage scheme defined by the MLIR sparse tensor types. The use of a tuple allows for a simple 1:1 type conversion. A subsequent pass can expand this tuple into its component with an isolated 1:N type conversion.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp | ||
---|---|---|
74 | That is right. It may be surprising, but the dimension level types are interpreted *after* applying the reordering (see my comment in this posting: https://discourse.llvm.org/t/sparse-tensors-in-mlir/3389/12). So we can construct the basic type without considering the ordering. However, when filling in the sizes *and* when querying the type, reordering needs to be included. I think I will make some top level utilities for this, so we don't make mistakes in the codegen parts that we will add below. |
Good to see it here!