MLIR  20.0.0git
Classes | Namespaces | Macros | Typedefs | Functions
CRunnerUtils.h File Reference
#include <array>
#include <cassert>
#include <cstdint>
#include <initializer_list>
#include <vector>

Go to the source code of this file.

Classes

struct  mlir::detail::Vector1D< T, Dim, true >
 
struct  mlir::detail::Vector1D< T, Dim, false >
 
struct  Vector< T, Dim, Dims >
 
struct  Vector< T, Dim >
 
struct  StridedMemRefType< T, N >
 StridedMemRef descriptor type with static rank. More...
 
struct  StridedMemRefType< T, 1 >
 StridedMemRef descriptor type specialized for rank 1. More...
 
struct  StridedMemRefType< T, 0 >
 StridedMemRef descriptor type specialized for rank 0. More...
 
class  StridedMemrefIterator< T, Rank >
 Iterate over all elements in a strided memref. More...
 
class  StridedMemrefIterator< T, 0 >
 Iterate over all elements in a 0-ranked strided memref. More...
 
struct  UnrankedMemRefType< T >
 
class  DynamicMemRefType< T >
 
class  DynamicMemRefIterator< T >
 Iterate over all elements in a dynamic memref. More...
 

Namespaces

 mlir
 Include the generated interface declarations.
 
 mlir::detail
 AttrTypeReplacer.
 

Macros

#define MLIR_CRUNNERUTILS_EXPORT   __attribute__((visibility("default")))
 
#define MLIR_CRUNNERUTILS_DEFINE_FUNCTIONS
 

Typedefs

template<int D1, typename T >
using Vector1D = Vector< T, D1 >
 
template<int D1, int D2, typename T >
using Vector2D = Vector< T, D1, D2 >
 
template<int D1, int D2, int D3, typename T >
using Vector3D = Vector< T, D1, D2, D3 >
 
template<int D1, int D2, int D3, int D4, typename T >
using Vector4D = Vector< T, D1, D2, D3, D4 >
 

Functions

constexpr bool mlir::detail::isPowerOf2 (int n)
 
constexpr unsigned mlir::detail::nextPowerOf2 (int n)
 
template<int N>
void dropFront (int64_t arr[N], int64_t *res)
 
MLIR_CRUNNERUTILS_EXPORT void memrefCopy (int64_t elemSize, ::UnrankedMemRefType< char > *src, ::UnrankedMemRefType< char > *dst)
 
MLIR_CRUNNERUTILS_EXPORT void printI64 (int64_t i)
 
MLIR_CRUNNERUTILS_EXPORT void printU64 (uint64_t u)
 
MLIR_CRUNNERUTILS_EXPORT void printF32 (float f)
 
MLIR_CRUNNERUTILS_EXPORT void printF64 (double d)
 
MLIR_CRUNNERUTILS_EXPORT void printString (char const *s)
 
MLIR_CRUNNERUTILS_EXPORT void printOpen ()
 
MLIR_CRUNNERUTILS_EXPORT void printClose ()
 
MLIR_CRUNNERUTILS_EXPORT void printComma ()
 
MLIR_CRUNNERUTILS_EXPORT void printNewline ()
 
MLIR_CRUNNERUTILS_EXPORT void printFlops (double flops)
 
MLIR_CRUNNERUTILS_EXPORT double rtclock ()
 
MLIR_CRUNNERUTILS_EXPORT void * rtsrand (uint64_t s)
 
MLIR_CRUNNERUTILS_EXPORT uint64_t rtrand (void *g, uint64_t m)
 
MLIR_CRUNNERUTILS_EXPORT void rtdrand (void *g)
 
MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_shuffle (StridedMemRefType< uint64_t, 1 > *mref, void *g)
 
MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortI64 (uint64_t n, StridedMemRefType< int64_t, 1 > *vref)
 
MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortF64 (uint64_t n, StridedMemRefType< double, 1 > *vref)
 
MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortF32 (uint64_t n, StridedMemRefType< float, 1 > *vref)
 

Macro Definition Documentation

◆ MLIR_CRUNNERUTILS_DEFINE_FUNCTIONS

#define MLIR_CRUNNERUTILS_DEFINE_FUNCTIONS

Definition at line 32 of file CRunnerUtils.h.

◆ MLIR_CRUNNERUTILS_EXPORT

#define MLIR_CRUNNERUTILS_EXPORT   __attribute__((visibility("default")))

Definition at line 31 of file CRunnerUtils.h.

Typedef Documentation

◆ Vector1D

template<int D1, typename T >
using Vector1D = Vector<T, D1>

Definition at line 109 of file CRunnerUtils.h.

◆ Vector2D

template<int D1, int D2, typename T >
using Vector2D = Vector<T, D1, D2>

Definition at line 111 of file CRunnerUtils.h.

◆ Vector3D

template<int D1, int D2, int D3, typename T >
using Vector3D = Vector<T, D1, D2, D3>

Definition at line 113 of file CRunnerUtils.h.

◆ Vector4D

template<int D1, int D2, int D3, int D4, typename T >
using Vector4D = Vector<T, D1, D2, D3, D4>

Definition at line 115 of file CRunnerUtils.h.

Function Documentation

◆ _mlir_ciface_shuffle()

MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_shuffle ( StridedMemRefType< uint64_t, 1 > *  mref,
void *  g 
)

◆ _mlir_ciface_stdSortF32()

MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortF32 ( uint64_t  n,
StridedMemRefType< float, 1 > *  vref 
)

◆ _mlir_ciface_stdSortF64()

MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortF64 ( uint64_t  n,
StridedMemRefType< double, 1 > *  vref 
)

◆ _mlir_ciface_stdSortI64()

MLIR_CRUNNERUTILS_EXPORT void _mlir_ciface_stdSortI64 ( uint64_t  n,
StridedMemRefType< int64_t, 1 > *  vref 
)

◆ dropFront()

template<int N>
void dropFront ( int64_t  arr[N],
int64_t *  res 
)

Definition at line 118 of file CRunnerUtils.h.

Referenced by mlir::getI64SubArray().

◆ memrefCopy()

MLIR_CRUNNERUTILS_EXPORT void memrefCopy ( int64_t  elemSize,
::UnrankedMemRefType< char > *  src,
::UnrankedMemRefType< char > *  dst 
)

◆ printClose()

MLIR_CRUNNERUTILS_EXPORT void printClose ( )

◆ printComma()

MLIR_CRUNNERUTILS_EXPORT void printComma ( )

◆ printF32()

MLIR_CRUNNERUTILS_EXPORT void printF32 ( float  f)

◆ printF64()

MLIR_CRUNNERUTILS_EXPORT void printF64 ( double  d)

◆ printFlops()

MLIR_CRUNNERUTILS_EXPORT void printFlops ( double  flops)

◆ printI64()

MLIR_CRUNNERUTILS_EXPORT void printI64 ( int64_t  i)

◆ printNewline()

MLIR_CRUNNERUTILS_EXPORT void printNewline ( )

◆ printOpen()

MLIR_CRUNNERUTILS_EXPORT void printOpen ( )

◆ printString()

MLIR_CRUNNERUTILS_EXPORT void printString ( char const *  s)

◆ printU64()

MLIR_CRUNNERUTILS_EXPORT void printU64 ( uint64_t  u)

◆ rtclock()

MLIR_CRUNNERUTILS_EXPORT double rtclock ( )

◆ rtdrand()

MLIR_CRUNNERUTILS_EXPORT void rtdrand ( void *  g)

◆ rtrand()

MLIR_CRUNNERUTILS_EXPORT uint64_t rtrand ( void *  g,
uint64_t  m 
)

◆ rtsrand()

MLIR_CRUNNERUTILS_EXPORT void* rtsrand ( uint64_t  s)