mirror of https://github.com/llvm/torch-mlir
234fc7fe0c
Prior to this patch, the torch dialect included `AtenTriuOp` for computing the upper triangular part of the input matrix, but there was no code for lowering the op to the linalg dialect. This patch adds code to generate a `linalg.generic` operation that compares indices (computed using `linalg.index`) to choose between zero or the original value (using `arith.select`). The lowering fails if the number of dimensions are less than two. This patch also adds a few end-to-end tests. |
||
---|---|---|
.. | ||
AdjustCallingConventions.cpp | ||
CMakeLists.txt | ||
DecomposeComplexOps.cpp | ||
DropShapeCalculations.cpp | ||
GlobalizeObjectGraph.cpp | ||
InlineGlobalSlots.cpp | ||
MaximizeValueSemantics.cpp | ||
PassDetail.h | ||
Passes.cpp | ||
PrepareForGlobalizeObjectGraph.cpp | ||
ReduceOpVariants.cpp | ||
RefinePublicReturn.cpp | ||
RefineTypes.cpp | ||
ReifyShapeCalculations.cpp | ||
ShapeLibrary.cpp | ||
SimplifyShapeCalculations.cpp |