LLVM  14.0.0git
Public Member Functions | Static Public Member Functions | Friends | List of all members
llvm::TypeSize Class Reference

#include "llvm/Support/TypeSize.h"

Inheritance diagram for llvm::TypeSize:
Inheritance graph
[legend]
Collaboration diagram for llvm::TypeSize:
Collaboration graph
[legend]

Public Member Functions

 TypeSize (const LinearPolySize< TypeSize > &V)
 
 TypeSize (ScalarTy MinVal, bool IsScalable)
 
ScalarTy getFixedSize () const
 
ScalarTy getKnownMinSize () const
 
 operator ScalarTy () const
 
- Public Member Functions inherited from llvm::LinearPolySize< TypeSize >
ScalarTy getKnownMinValue () const
 Returns the minimum value this size can represent. More...
 
bool isScalable () const
 Returns whether the size is scaled by a runtime quantity (vscale). More...
 
bool isKnownEven () const
 A return value of true indicates we know at compile time that the number of elements (vscale * Min) is definitely even. More...
 
bool isKnownMultipleOf (ScalarTy RHS) const
 This function tells the caller whether the element count is known at compile time to be a multiple of the scalar value RHS. More...
 
ScalarTy getFixedValue () const
 
TypeSize divideCoefficientBy (ScalarTy RHS) const
 We do not provide the '/' operator here because division for polynomial types does not work in the same way as for normal integer types. More...
 
TypeSize coefficientNextPowerOf2 () const
 
void print (raw_ostream &OS) const
 Printing function. More...
 
- Public Member Functions inherited from llvm::UnivariateLinearPolyBase< TypeSize >
bool operator== (const UnivariateLinearPolyBase &RHS) const
 
bool operator!= (const UnivariateLinearPolyBase &RHS) const
 
bool isZero () const
 
bool isNonZero () const
 
 operator bool () const
 
ScalarTy getValue () const
 
ScalarTy getValue (unsigned Dim) const
 
TypeSize getWithIncrement (ScalarTy RHS) const
 Add RHS to the value at the univariate dimension. More...
 
TypeSize getWithDecrement (ScalarTy RHS) const
 Subtract RHS from the value at the univariate dimension. More...
 

Static Public Member Functions

static TypeSize Fixed (ScalarTy MinVal)
 
static TypeSize Scalable (ScalarTy MinVal)
 
- Static Public Member Functions inherited from llvm::LinearPolySize< TypeSize >
static TypeSize getFixed (ScalarTy MinVal)
 
static TypeSize getScalable (ScalarTy MinVal)
 
static TypeSize get (ScalarTy MinVal, bool Scalable)
 
static TypeSize getNull ()
 
static bool isKnownLT (const LinearPolySize &LHS, const LinearPolySize &RHS)
 
static bool isKnownGT (const LinearPolySize &LHS, const LinearPolySize &RHS)
 
static bool isKnownLE (const LinearPolySize &LHS, const LinearPolySize &RHS)
 
static bool isKnownGE (const LinearPolySize &LHS, const LinearPolySize &RHS)
 

Friends

TypeSize operator* (const TypeSize &LHS, const int RHS)
 
TypeSize operator* (const TypeSize &LHS, const unsigned RHS)
 
TypeSize operator* (const TypeSize &LHS, const int64_t RHS)
 
TypeSize operator* (const int LHS, const TypeSize &RHS)
 
TypeSize operator* (const unsigned LHS, const TypeSize &RHS)
 
TypeSize operator* (const int64_t LHS, const TypeSize &RHS)
 
TypeSize operator* (const uint64_t LHS, const TypeSize &RHS)
 

Additional Inherited Members

- Public Types inherited from llvm::LinearPolySize< TypeSize >
enum  Dims
 
using ScalarTy = typename UnivariateLinearPolyBase< TypeSize >::ScalarTy
 
- Public Types inherited from llvm::UnivariateLinearPolyBase< TypeSize >
using ScalarTy = typename LinearPolyBaseTypeTraits< TypeSize >::ScalarTy
 
- Static Public Attributes inherited from llvm::UnivariateLinearPolyBase< TypeSize >
static constexpr auto Dimensions
 
- Protected Member Functions inherited from llvm::LinearPolySize< TypeSize >
 LinearPolySize (ScalarTy MinVal, Dims D)
 
 LinearPolySize (const UnivariateLinearPolyBase< TypeSize > &V)
 
- Protected Member Functions inherited from llvm::UnivariateLinearPolyBase< TypeSize >
 UnivariateLinearPolyBase (ScalarTy Val, unsigned UnivariateDim)
 
- Protected Attributes inherited from llvm::UnivariateLinearPolyBase< TypeSize >
ScalarTy Value
 
unsigned UnivariateDim
 

Detailed Description

Definition at line 417 of file TypeSize.h.

Constructor & Destructor Documentation

◆ TypeSize() [1/2]

llvm::TypeSize::TypeSize ( const LinearPolySize< TypeSize > &  V)
inline

Definition at line 419 of file TypeSize.h.

Referenced by Fixed(), and Scalable().

◆ TypeSize() [2/2]

llvm::TypeSize::TypeSize ( ScalarTy  MinVal,
bool  IsScalable 
)
inline

Definition at line 420 of file TypeSize.h.

Member Function Documentation

◆ Fixed()

static TypeSize llvm::TypeSize::Fixed ( ScalarTy  MinVal)
inlinestatic

◆ getFixedSize()

ScalarTy llvm::TypeSize::getFixedSize ( ) const
inline

◆ getKnownMinSize()

ScalarTy llvm::TypeSize::getKnownMinSize ( ) const
inline

◆ operator ScalarTy()

TypeSize::operator TypeSize::ScalarTy ( ) const

◆ Scalable()

static TypeSize llvm::TypeSize::Scalable ( ScalarTy  MinVal)
inlinestatic

Definition at line 424 of file TypeSize.h.

References TypeSize().

Referenced by llvm::AArch64InstrInfo::getMemOpInfo(), and llvm::MVT::getSizeInBits().

Friends And Related Function Documentation

◆ operator* [1/7]

TypeSize operator* ( const int  LHS,
const TypeSize RHS 
)
friend

Definition at line 466 of file TypeSize.h.

◆ operator* [2/7]

TypeSize operator* ( const int64_t  LHS,
const TypeSize RHS 
)
friend

Definition at line 472 of file TypeSize.h.

◆ operator* [3/7]

TypeSize operator* ( const TypeSize LHS,
const int  RHS 
)
friend

Definition at line 457 of file TypeSize.h.

◆ operator* [4/7]

TypeSize operator* ( const TypeSize LHS,
const int64_t  RHS 
)
friend

Definition at line 463 of file TypeSize.h.

◆ operator* [5/7]

TypeSize operator* ( const TypeSize LHS,
const unsigned  RHS 
)
friend

Definition at line 460 of file TypeSize.h.

◆ operator* [6/7]

TypeSize operator* ( const uint64_t  LHS,
const TypeSize RHS 
)
friend

Definition at line 475 of file TypeSize.h.

◆ operator* [7/7]

TypeSize operator* ( const unsigned  LHS,
const TypeSize RHS 
)
friend

Definition at line 469 of file TypeSize.h.


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