Dynamic MemRef Cast

This is an interesting point. In the most general form, symbols can be referenced in the same way that the dimensions are, i.e., by providing an index. For the case of strided memrefs, I assume having some helper functions that identify the correct symbols for their meaning should be good enough.

So far this has been modeled only at the LLVM level I think, where we have access to these symbols as we can read them out of the memref descriptor.

I am all for moving ahead with this. We only need to bikeshed a name for the operation. get_symbol, extract_symbol? And the index as an attribute should be fine as this only makes sense in the ranked case.

1 Like