MLIR  20.0.0git
Classes | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
mlir::quant::detail::UniformQuantizedPerAxisTypeStorage Struct Reference

#include "Dialect/Quant/IR/TypeDetail.h"

+ Inheritance diagram for mlir::quant::detail::UniformQuantizedPerAxisTypeStorage:

Classes

struct  KeyTy
 

Public Member Functions

 UniformQuantizedPerAxisTypeStorage (const KeyTy &key, ArrayRef< double > scales, ArrayRef< int64_t > zeroPoints)
 
bool operator== (const KeyTy &key) const
 
ArrayRef< double > getScales () const
 
ArrayRef< int64_t > getZeroPoints () const
 
- Public Member Functions inherited from mlir::quant::detail::QuantizedTypeStorage
 QuantizedTypeStorage (unsigned flags, Type storageType, Type expressedType, int64_t storageTypeMin, int64_t storageTypeMax)
 
- Public Member Functions inherited from mlir::TypeStorage
const AbstractTypegetAbstractType ()
 Return the abstract type descriptor for this type. More...
 

Static Public Member Functions

static UniformQuantizedPerAxisTypeStorageconstruct (TypeStorageAllocator &allocator, const KeyTy &key)
 Construction. More...
 
static unsigned hashKey (const KeyTy &key)
 

Public Attributes

const double * scaleElements
 
const int64_t * zeroPointElements
 
unsigned quantParamsSize
 
int32_t quantizedDimension
 
- Public Attributes inherited from mlir::quant::detail::QuantizedTypeStorage
unsigned flags
 Flags corresponding to the bitmapped enum QuantizationFlags::FlagValue. More...
 
Type storageType
 
Type expressedType
 
int64_t storageTypeMin
 
int64_t storageTypeMax
 

Additional Inherited Members

- Protected Member Functions inherited from mlir::TypeStorage
 TypeStorage ()
 This constructor is used by derived classes as part of the TypeUniquer. More...
 
- Protected Member Functions inherited from mlir::StorageUniquer::BaseStorage
 BaseStorage ()=default
 

Detailed Description

Definition at line 160 of file TypeDetail.h.

Constructor & Destructor Documentation

◆ UniformQuantizedPerAxisTypeStorage()

mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::UniformQuantizedPerAxisTypeStorage ( const KeyTy key,
ArrayRef< double >  scales,
ArrayRef< int64_t >  zeroPoints 
)
inline

Definition at line 219 of file TypeDetail.h.

Referenced by construct().

Member Function Documentation

◆ construct()

static UniformQuantizedPerAxisTypeStorage* mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::construct ( TypeStorageAllocator allocator,
const KeyTy key 
)
inlinestatic

◆ getScales()

ArrayRef<double> mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::getScales ( ) const
inline

Definition at line 242 of file TypeDetail.h.

References quantParamsSize, and scaleElements.

◆ getZeroPoints()

ArrayRef<int64_t> mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::getZeroPoints ( ) const
inline

Definition at line 246 of file TypeDetail.h.

References quantParamsSize, and zeroPointElements.

◆ hashKey()

static unsigned mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::hashKey ( const KeyTy key)
inlinestatic

◆ operator==()

bool mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::operator== ( const KeyTy key) const
inline

Member Data Documentation

◆ quantizedDimension

int32_t mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::quantizedDimension

Definition at line 253 of file TypeDetail.h.

◆ quantParamsSize

unsigned mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::quantParamsSize

Definition at line 252 of file TypeDetail.h.

Referenced by getScales(), and getZeroPoints().

◆ scaleElements

const double* mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::scaleElements

Definition at line 250 of file TypeDetail.h.

Referenced by getScales().

◆ zeroPointElements

const int64_t* mlir::quant::detail::UniformQuantizedPerAxisTypeStorage::zeroPointElements

Definition at line 251 of file TypeDetail.h.

Referenced by getZeroPoints().


The documentation for this struct was generated from the following file: