MLIR 22.0.0git
Traits.cpp File Reference
#include "mlir/Dialect/Traits.h"
#include "mlir/IR/BuiltinTypes.h"
#include "mlir/IR/TypeUtilities.h"
#include <optional>

Go to the source code of this file.

Functions

static ArrayRef< int64_tgetShape (Type type)
 Returns the shape of the given type.
template<typename iterator_range>
static std::tuple< bool, boolhasTensorOrVectorType (iterator_range types)
 Returns a tuple corresponding to whether range has tensor or vector type.
static bool isCompatibleInferredReturnShape (ArrayRef< int64_t > inferred, ArrayRef< int64_t > existing)
static std::string getShapeString (ArrayRef< int64_t > shape)

Function Documentation

◆ getShape()

◆ getShapeString()

std::string getShapeString ( ArrayRef< int64_t > shape)
static

Definition at line 209 of file Traits.cpp.

Referenced by mlir::OpTrait::impl::verifyCompatibleOperandBroadcast().

◆ hasTensorOrVectorType()

template<typename iterator_range>
std::tuple< bool, bool > hasTensorOrVectorType ( iterator_range types)
static

Returns a tuple corresponding to whether range has tensor or vector type.

Definition at line 189 of file Traits.cpp.

Referenced by mlir::OpTrait::impl::verifyCompatibleOperandBroadcast().

◆ isCompatibleInferredReturnShape()

bool isCompatibleInferredReturnShape ( ArrayRef< int64_t > inferred,
ArrayRef< int64_t > existing )
static

Definition at line 194 of file Traits.cpp.

Referenced by mlir::OpTrait::impl::verifyCompatibleOperandBroadcast().