MLIR  19.0.0git
Functions
LoopAnnotationImporter.cpp File Reference
#include "LoopAnnotationImporter.h"
#include "llvm/IR/Constants.h"

Go to the source code of this file.

Functions

static bool isEmptyOrNull (const Attribute attr)
 
template<typename T >
static bool isEmptyOrNull (const SmallVectorImpl< T > &vec)
 
template<typename T , typename... P>
static T createIfNonNull (MLIRContext *ctx, const P &...args)
 Helper function that only creates and attribute of type T if all argument conversion were successfull and at least one of them holds a non-null value. More...
 

Function Documentation

◆ createIfNonNull()

template<typename T , typename... P>
static T createIfNonNull ( MLIRContext ctx,
const P &...  args 
)
static

Helper function that only creates and attribute of type T if all argument conversion were successfull and at least one of them holds a non-null value.

Definition at line 275 of file LoopAnnotationImporter.cpp.

References mlir::failed(), mlir::get(), and isEmptyOrNull().

◆ isEmptyOrNull() [1/2]

static bool isEmptyOrNull ( const Attribute  attr)
static

Definition at line 265 of file LoopAnnotationImporter.cpp.

Referenced by createIfNonNull().

◆ isEmptyOrNull() [2/2]

template<typename T >
static bool isEmptyOrNull ( const SmallVectorImpl< T > &  vec)
static

Definition at line 268 of file LoopAnnotationImporter.cpp.