MLIR  20.0.0git
Public Member Functions | List of all members
mlir::sparse_tensor::ir_detail::VarSet Class Referencefinal

Efficient representation of a set of Var. More...

#include "Dialect/SparseTensor/IR/Detail/Var.h"

Public Member Functions

 VarSet (Ranks const &ranks)
 
unsigned getRank (VarKind vk) const
 
unsigned getSymRank () const
 
unsigned getDimRank () const
 
unsigned getLvlRank () const
 
Ranks getRanks () const
 
bool contains (Var var) const
 For the contains method: if variables occurring in the method parameter are OOB for the VarSet, then these methods will always return false. More...
 
void add (Var var)
 For the add methods: OOB parameters cause undefined behavior. More...
 
void add (VarSet const &vars)
 
void add (DimLvlExpr expr)
 

Detailed Description

Efficient representation of a set of Var.

Definition at line 242 of file Var.h.

Constructor & Destructor Documentation

◆ VarSet()

VarSet::VarSet ( Ranks const &  ranks)
explicit

Member Function Documentation

◆ add() [1/3]

void VarSet::add ( DimLvlExpr  expr)

◆ add() [2/3]

void VarSet::add ( Var  var)

For the add methods: OOB parameters cause undefined behavior.

Currently the add methods will raise an assertion error.

Definition at line 87 of file Var.cpp.

References mlir::sparse_tensor::ir_detail::Var::getKind(), and mlir::sparse_tensor::ir_detail::Var::getNum().

Referenced by add(), and mlir::sparse_tensor::ir_detail::DimLvlMap::DimLvlMap().

◆ add() [3/3]

void VarSet::add ( VarSet const &  vars)

Definition at line 92 of file Var.cpp.

References everyVarKind.

◆ contains()

bool VarSet::contains ( Var  var) const

For the contains method: if variables occurring in the method parameter are OOB for the VarSet, then these methods will always return false.

Definition at line 77 of file Var.cpp.

References mlir::sparse_tensor::ir_detail::Var::getKind(), and mlir::sparse_tensor::ir_detail::Var::getNum().

Referenced by mlir::sparse_tensor::ir_detail::DimLvlMap::DimLvlMap().

◆ getDimRank()

unsigned mlir::sparse_tensor::ir_detail::VarSet::getDimRank ( ) const
inline

Definition at line 250 of file Var.h.

References mlir::sparse_tensor::ir_detail::Dimension, and getRank().

Referenced by getRanks().

◆ getLvlRank()

unsigned mlir::sparse_tensor::ir_detail::VarSet::getLvlRank ( ) const
inline

Definition at line 251 of file Var.h.

References getRank(), and mlir::sparse_tensor::ir_detail::Level.

Referenced by getRanks().

◆ getRank()

unsigned mlir::sparse_tensor::ir_detail::VarSet::getRank ( VarKind  vk) const
inline

Definition at line 248 of file Var.h.

Referenced by getDimRank(), getLvlRank(), and getSymRank().

◆ getRanks()

Ranks mlir::sparse_tensor::ir_detail::VarSet::getRanks ( ) const
inline

Definition at line 252 of file Var.h.

References getDimRank(), getLvlRank(), and getSymRank().

Referenced by VarSet().

◆ getSymRank()

unsigned mlir::sparse_tensor::ir_detail::VarSet::getSymRank ( ) const
inline

Definition at line 249 of file Var.h.

References getRank(), and mlir::sparse_tensor::ir_detail::Symbol.

Referenced by getRanks().


The documentation for this class was generated from the following files: