Skip to content
Commit 8affb783 authored by Nicolas Vasilache's avatar Nicolas Vasilache Committed by Mehdi Amini
Browse files

Linalg portion of the tutorial - part 2

    The second part of the Linalg tutorial introduces:
    1. the TensorContractionBase type from which all tensor contractions derive;
    2. a basic set of operations DotOp, MatvecOp and MatmulOp;
    3. a helper function `createFullyComposedView` that walks the producers of a SliceOp up until the root ViewOp and returns a single ViewOp;
    4. programmatic examples to test MLIR construction involving these types.

    This CL also refactors file organization so that:
    1. clients only need to include Ops.h and Types.h while keeping independent small files separate for the purpose of the tutorial;
    2. each step of the tutorial has its own linalgxxx include directory and each include explicitly states in which part of the tutorial a particular concept was introduced.

    Lastly the following cleanups are applied:
    1. ValueOrSliceOp is removed in favor of simpler helper function.
    2. methods that walk back the chain of ops are removed from the core ops and added to a separate Analysis.
    3. various additional cleanups.

--

PiperOrigin-RevId: 241555769
parent 0be63691
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment