struct TileInfo

Declaration

struct TileInfo { /* full declaration omitted */ };

Description

A helper struct to create IR loop nests for tiling in IR of the following form: for ColumnLoop.Index = 0..NumColumns for RowLoop.Index = 0..NumRows for KLoop.Index = 0..NumInner

Declared at: llvm/include/llvm/Transforms/Utils/MatrixUtils.h:31

Member Variables

public unsigned int NumRows
Number of rows of the matrix.
public unsigned int NumColumns
Number of columns of the matrix.
public unsigned int NumInner
Number of columns of the first matrix of a multiply / number of rows of the second matrix of a multiply.
public unsigned int TileSize = -1
Number of rows/columns in a tile.
public llvm::TileInfo::MatrixLoop RowLoop
The loop iterating on the rows.
public llvm::TileInfo::MatrixLoop ColumnLoop
The loop iterating on the columns.
public llvm::TileInfo::MatrixLoop KLoop
The loop iterating on k (inner dimension).

Method Overview

  • private static llvm::BasicBlock * CreateLoop(llvm::BasicBlock * Preheader, llvm::BasicBlock * Exit, llvm::Value * Bound, llvm::Value * Step, llvm::StringRef Name, llvm::IRBuilderBase & B, llvm::DomTreeUpdater & DTU, llvm::Loop * L, llvm::LoopInfo & LI)
  • public llvm::BasicBlock * CreateTiledLoops(llvm::BasicBlock * Start, llvm::BasicBlock * End, llvm::IRBuilderBase & B, llvm::DomTreeUpdater & DTU, llvm::LoopInfo & LI)
  • public TileInfo(unsigned int NumRows, unsigned int NumColumns, unsigned int NumInner, unsigned int TileSize)

Methods

static llvm::BasicBlock* CreateLoop(
    llvm::BasicBlock* Preheader,
    llvm::BasicBlock* Exit,
    llvm::Value* Bound,
    llvm::Value* Step,
    llvm::StringRef Name,
    llvm::IRBuilderBase& B,
    llvm::DomTreeUpdater& DTU,
    llvm::Loop* L,
    llvm::LoopInfo& LI)

Description

Creates a new loop with header, body and latch blocks that iterates from [0, Bound). Updates \p Preheader to branch to the new header and uses \p Exit as exit block. Adds the new loop blocks to \Land applies dominator tree updates to \p DTU.

Declared at: llvm/include/llvm/Transforms/Utils/MatrixUtils.h:82

Parameters

llvm::BasicBlock* Preheader
llvm::BasicBlock* Exit
llvm::Value* Bound
llvm::Value* Step
llvm::StringRef Name
llvm::IRBuilderBase& B
llvm::DomTreeUpdater& DTU
llvm::Loop* L
llvm::LoopInfo& LI

llvm::BasicBlock* CreateTiledLoops(
    llvm::BasicBlock* Start,
    llvm::BasicBlock* End,
    llvm::IRBuilderBase& B,
    llvm::DomTreeUpdater& DTU,
    llvm::LoopInfo& LI)

Description

Creates an IR loop nests for tiling of the form below. Returns the block for the inner loop body and sets {Column,Row,Inner}LoopHeader/Latch fields. for ColumnLoop.Index = 0..NumColumns for RowLoop.Index = 0..NumRows for InnerLoop.Index = 0..NumInner

Declared at: llvm/include/llvm/Transforms/Utils/MatrixUtils.h:73

Parameters

llvm::BasicBlock* Start
llvm::BasicBlock* End
llvm::IRBuilderBase& B
llvm::DomTreeUpdater& DTU
llvm::LoopInfo& LI

TileInfo(unsigned int NumRows,
         unsigned int NumColumns,
         unsigned int NumInner,
         unsigned int TileSize)

Declared at: llvm/include/llvm/Transforms/Utils/MatrixUtils.h:61

Parameters

unsigned int NumRows
unsigned int NumColumns
unsigned int NumInner
unsigned int TileSize