MLIR  20.0.0git
Classes | Namespaces | Macros | Functions
SPIRVAttributes.cpp File Reference
#include "mlir/Dialect/SPIRV/IR/SPIRVAttributes.h"
#include "mlir/Dialect/SPIRV/IR/SPIRVDialect.h"
#include "mlir/Dialect/SPIRV/IR/SPIRVTypes.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/DialectImplementation.h"
#include "llvm/ADT/TypeSwitch.h"
#include "mlir/Dialect/SPIRV/IR/SPIRVAttrUtils.inc"
#include "mlir/Dialect/SPIRV/IR/SPIRVAttributes.cpp.inc"

Go to the source code of this file.

Classes

struct  mlir::spirv::detail::InterfaceVarABIAttributeStorage
 
struct  mlir::spirv::detail::VerCapExtAttributeStorage
 
struct  mlir::spirv::detail::TargetEnvAttributeStorage
 

Namespaces

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

Macros

#define GET_ATTRDEF_CLASSES
 
#define GET_ATTRDEF_LIST
 

Functions

static ParseResult parseKeywordList (DialectAsmParser &parser, function_ref< LogicalResult(SMLoc, StringRef)> processKeyword)
 Parses a comma-separated list of keywords, invokes processKeyword on each of the parsed keyword, and returns failure if any error occurs. More...
 
static Attribute parseInterfaceVarABIAttr (DialectAsmParser &parser)
 Parses a spirv::InterfaceVarABIAttr. More...
 
static Attribute parseVerCapExtAttr (DialectAsmParser &parser)
 
static Attribute parseTargetEnvAttr (DialectAsmParser &parser)
 Parses a spirv::TargetEnvAttr. More...
 
static void print (spirv::VerCapExtAttr triple, DialectAsmPrinter &printer)
 
static void print (spirv::TargetEnvAttr targetEnv, DialectAsmPrinter &printer)
 
static void print (spirv::InterfaceVarABIAttr interfaceVarABIAttr, DialectAsmPrinter &printer)
 

Macro Definition Documentation

◆ GET_ATTRDEF_CLASSES

#define GET_ATTRDEF_CLASSES

Definition at line 348 of file SPIRVAttributes.cpp.

◆ GET_ATTRDEF_LIST

#define GET_ATTRDEF_LIST

Function Documentation

◆ parseInterfaceVarABIAttr()

static Attribute parseInterfaceVarABIAttr ( DialectAsmParser parser)
static

◆ parseKeywordList()

static ParseResult parseKeywordList ( DialectAsmParser parser,
function_ref< LogicalResult(SMLoc, StringRef)>  processKeyword 
)
static

Parses a comma-separated list of keywords, invokes processKeyword on each of the parsed keyword, and returns failure if any error occurs.

Definition at line 358 of file SPIRVAttributes.cpp.

References mlir::AsmParser::parseCommaSeparatedList(), mlir::AsmParser::parseLSquare(), mlir::AsmParser::parseOptionalRSquare(), and mlir::AsmParser::parseRSquare().

Referenced by parseVerCapExtAttr().

◆ parseTargetEnvAttr()

static Attribute parseTargetEnvAttr ( DialectAsmParser parser)
static

◆ parseVerCapExtAttr()

static Attribute parseVerCapExtAttr ( DialectAsmParser parser)
static

◆ print() [1/3]

static void print ( spirv::InterfaceVarABIAttr  interfaceVarABIAttr,
DialectAsmPrinter printer 
)
static

◆ print() [2/3]

static void print ( spirv::TargetEnvAttr  targetEnv,
DialectAsmPrinter printer 
)
static

◆ print() [3/3]

static void print ( spirv::VerCapExtAttr  triple,
DialectAsmPrinter printer 
)
static