diff options
| author | Cullen Rhodes <cullen.rhodes@arm.com> | 2024-07-04 08:57:02 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-04 08:57:02 +0100 |
| commit | 67b302c52f79db2ab5c46e5e8c600f1c2af57a83 (patch) | |
| tree | 2a6e90d72ae7533bcb072bbd13d12447f4fc054b /lldb/test/API/python_api/thread/TestThreadAPI.py | |
| parent | 927def49728371d746476e79a6570cd93a4d335c (diff) | |
[mlir][vector] Add vector.step operation (#96776)
This patch adds a new vector.step operation to the Vector dialect. It
produces a linear sequence of index values from 0 to N, where N is the
number of elements in the result vector, and can be used to create
vectors of indices.
It supports both fixed-width and scalable vectors. For fixed the
canonical representation is `arith.constant dense<[0, .., N]>`. A
scalable step cannot be represented as a constant and is lowered to the
`llvm.experimental.stepvector` intrinsic [1].
This op enables scalable vectorization of linalg.index ops, see #96778. It can
also be used in the SparseVectorizer in-place of lower-level stepvector
intrinsic, see [2] (patch to follow).
[1] https://llvm.org/docs/LangRef.html#llvm-experimental-stepvector-intrinsic
[2] https://github.com/llvm/llvm-project/blob/acf675b63f9426e61aac2155e29280f7d21f9421/mlir/lib/Dialect/SparseTensor/Transforms/SparseVectorization.cpp#L385-L388
Diffstat (limited to 'lldb/test/API/python_api/thread/TestThreadAPI.py')
0 files changed, 0 insertions, 0 deletions
