[llvm] ADT/Matrix: two-dimensional Container with View (PR #98893)
Jakub Kuderski via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 15 09:23:22 PDT 2024
kuhar wrote:
> Yes, and that's what I've implemented in MatrixView. The storage class is essentially SmallVector with an additional field for tracking the number of columns. I need to track the number of columns, so that I can reconstruct the View after the underlying storage has been reallocated.
Thanks you for the explanation. If this is the case, I don't think the name `Matrix*` is the most fitting. I'd call it something like 'JaggedArray': https://en.wikipedia.org/wiki/Jagged_array.
> The constructors, drop_back, drop_front, slice, for instance.
What I'm missing is:
* What compile-time computation do we intend to do and why we need it?
* Why does this computation include 2d arrays and, transitively, array ref?
https://github.com/llvm/llvm-project/pull/98893
More information about the llvm-commits
mailing list