GPUOcelot
|
#include <PTXParser.h>
Classes | |
class | FunctionPrototype |
class | OperandWrapper |
Public Types | |
enum | Error { Success, SyntaxError, MalformedVersion, InvalidDataType, InvalidVecType, InitializerSizeMismatch, InvalidInstruction, DuplicateDeclaration, NoDeclaration, InvalidOpcode, DuplicateLabel, NoPrototype, PrototypeMismatch, NoLabel, InvalidArray, NotPredicate, NotSupported, NotVersion2_1, Invalid } |
typedef std::unordered_map < std::string, unsigned int > | StringMap |
typedef std::vector< std::string > | StringList |
typedef std::unordered_set < std::string > | StringSet |
typedef std::vector< StringSet > | StringSetStack |
typedef std::vector< unsigned int > | UintStack |
typedef std::vector< unsigned int > | DimensionVector |
typedef std::vector< double > | DoubleVector |
typedef std::unordered_map < std::string, OperandWrapper > | OperandMap |
typedef std::vector < ir::PTXOperand > | OperandVector |
typedef std::unordered_map < std::string, FunctionPrototype > | PrototypeMap |
Public Member Functions | |
void | addSpecialRegisters () |
void | maxnreg (unsigned int regs) |
void | maxntid (unsigned int tidx, unsigned int tidy=1024, unsigned int tidz=1024) |
void | ctapersm (int target, unsigned int ctas) |
void | maxnctapersm (unsigned int ctas) |
void | maxnctapersm () |
void | minnctapersm (unsigned int ctas) |
void | minnctapersm () |
void | preprocessor (int token) |
void | version (double version, YYLTYPE &location) |
void | addressSize (unsigned int size) |
void | identifierList (const std::string &identifier) |
void | identifierList2 (const std::string &identifier) |
void | decimalListSingle (long long int value) |
void | decimalListSingle2 (long long int value) |
void | symbolListSingle (const std::string &identifier) |
void | symbolListSingle2 (const std::string &identifier) |
void | floatList (double value) |
void | floatList1 (double value) |
void | singleList (float value) |
void | singleList1 (float value) |
void | targetElement (int token) |
void | target () |
void | noAddressSpace () |
void | addressSpace (int token) |
void | dataType (int token) |
void | statementVectorType (int token) |
void | instructionVectorType (int token) |
void | attribute (bool visible, bool external) |
void | shiftAmount (bool shift) |
void | vectorIndex (int token) |
void | arrayDimensionSet (long long int value, YYLTYPE &location, bool add) |
void | arrayDimensionSet () |
void | arrayDimensions () |
void | assignment () |
void | registerDeclaration (const std::string &name, YYLTYPE &location, unsigned int regs=0) |
void | registerSeperator (YYLTYPE &location) |
void | fileDeclaration (unsigned int id, const std::string &name) |
void | initializableDeclaration (const std::string &name, YYLTYPE &one, YYLTYPE &two) |
void | textureDeclaration (int token, const std::string &name, YYLTYPE &location) |
void | surfaceDeclaration (int token, const std::string &name, YYLTYPE &location) |
void | samplerDeclaration (int token, const std::string &name, YYLTYPE &location) |
void | argumentDeclaration (const std::string &name, YYLTYPE &location) |
void | openBrace (YYLTYPE &location) |
void | closeBrace (YYLTYPE &location) |
void | returnArgumentListBegin (YYLTYPE &location) |
void | returnArgumentListEnd (YYLTYPE &location) |
void | argumentListBegin (YYLTYPE &location) |
void | argumentListEnd (YYLTYPE &location) |
void | functionBegin (YYLTYPE &location) |
void | functionName (const std::string &name, YYLTYPE &location) |
void | functionDeclaration (YYLTYPE &location, bool body) |
void | entry (const std::string &name, YYLTYPE &location) |
void | entryDeclaration (YYLTYPE &location) |
void | entryStatement (YYLTYPE &location) |
void | metadata (const std::string &comment) |
void | locationAddress (int token) |
void | uninitializableDeclaration (const std::string &name) |
void | location (long long int one, long long int two, long long int three) |
void | label (const std::string &string) |
void | pragma (const std::string &string) |
void | labelOperand (const std::string &string) |
void | nonLabelOperand (const std::string &string, YYLTYPE &location, bool invert) |
void | constantOperand (long long int value) |
void | constantOperand (unsigned long long int value) |
void | constantOperand (float value) |
void | constantOperand (double value) |
void | indexedOperand (const std::string &name, YYLTYPE &location, long long int value) |
void | addressableOperand (const std::string &name, long long int value, YYLTYPE &location, bool invert) |
void | arrayOperand (YYLTYPE &location) |
void | returnOperand () |
void | guard (const std::string &name, YYLTYPE &one, bool invert) |
void | guard () |
void | statementEnd (YYLTYPE &location) |
void | tail (bool condition) |
void | uni (bool condition) |
void | carry (bool condition) |
void | modifier (int token) |
void | atomic (int token) |
void | volatileFlag (bool condition) |
void | reduction (int token) |
void | comparison (int token) |
void | boolean (int token) |
void | geometry (int token) |
void | vote (int token) |
void | level (int token) |
void | permute (int token) |
void | floatingPointMode (int token) |
void | defaultPermute () |
void | full () |
void | instruction () |
void | instruction (const std::string &opcode, int dataType) |
void | instruction (const std::string &opcode) |
void | tex (int dataType) |
void | tld4 (int dataType) |
void | callPrototypeName (const std::string &identifier) |
void | call (const std::string &identifier, YYLTYPE &location) |
void | carryIn () |
void | relaxedConvert (int token, YYLTYPE &location) |
void | cvtaTo () |
void | convert (int token, YYLTYPE &location) |
void | convertC (int token, YYLTYPE &location) |
void | convertD (int token, YYLTYPE &location) |
void | barrierOperation (int token, YYLTYPE &location) |
void | cacheOperation (int token) |
void | clampOperation (int token) |
void | formatMode (int token) |
void | surfaceQuery (int token) |
void | colorComponent (int token) |
void | returnType (int token) |
void | argumentType (int token) |
void | callPrototype (const std::string &name, const std::string &identifier, YYLTYPE &location) |
void | callTargets (const std::string &name, YYLTYPE &location) |
Public Attributes | |
ir::Module::StatementVector | statements |
StringMap | labels |
std::string | fileName |
std::string | sectionType |
std::string | sectionName |
StringList | identifiers |
OperandMap | operands |
StringSetStack | localOperands |
PrototypeMap | prototypes |
StringSetStack | localPrototypes |
bool | inEntry |
bool | inArgumentList |
bool | inReturnList |
unsigned int | returnOperands |
unsigned int | alignment |
ir::PTXOperand | operand |
OperandVector | operandVector |
ir::PTXStatement | statement |
FunctionPrototype | prototype |
ir::PTXStatement::Directive | directive |
std::string | comment |
typedef std::vector< unsigned int > parser::PTXParser::State::DimensionVector |
typedef std::vector< double > parser::PTXParser::State::DoubleVector |
typedef std::unordered_map< std::string, OperandWrapper > parser::PTXParser::State::OperandMap |
typedef std::vector< ir::PTXOperand > parser::PTXParser::State::OperandVector |
typedef std::unordered_map< std::string, FunctionPrototype > parser::PTXParser::State::PrototypeMap |
typedef std::vector< std::string > parser::PTXParser::State::StringList |
typedef std::unordered_map< std::string, unsigned int > parser::PTXParser::State::StringMap |
typedef std::unordered_set< std::string > parser::PTXParser::State::StringSet |
typedef std::vector< StringSet > parser::PTXParser::State::StringSetStack |
typedef std::vector< unsigned int > parser::PTXParser::State::UintStack |
void parser::PTXParser::State::addressableOperand | ( | const std::string & | name, |
long long int | value, | ||
YYLTYPE & | location, | ||
bool | invert | ||
) |
void parser::PTXParser::State::addressSize | ( | unsigned int | size | ) |
void parser::PTXParser::State::addressSpace | ( | int | token | ) |
void parser::PTXParser::State::addSpecialRegisters | ( | ) |
void parser::PTXParser::State::argumentDeclaration | ( | const std::string & | name, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::argumentListBegin | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::argumentListEnd | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::argumentType | ( | int | token | ) |
void parser::PTXParser::State::arrayDimensions | ( | ) |
void parser::PTXParser::State::arrayDimensionSet | ( | long long int | value, |
YYLTYPE & | location, | ||
bool | add | ||
) |
void parser::PTXParser::State::arrayDimensionSet | ( | ) |
void parser::PTXParser::State::arrayOperand | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::assignment | ( | ) |
void parser::PTXParser::State::atomic | ( | int | token | ) |
void parser::PTXParser::State::attribute | ( | bool | visible, |
bool | external | ||
) |
void parser::PTXParser::State::barrierOperation | ( | int | token, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::boolean | ( | int | token | ) |
void parser::PTXParser::State::cacheOperation | ( | int | token | ) |
void parser::PTXParser::State::call | ( | const std::string & | identifier, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::callPrototype | ( | const std::string & | name, |
const std::string & | identifier, | ||
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::callPrototypeName | ( | const std::string & | identifier | ) |
void parser::PTXParser::State::callTargets | ( | const std::string & | name, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::carry | ( | bool | condition | ) |
void parser::PTXParser::State::carryIn | ( | ) |
void parser::PTXParser::State::clampOperation | ( | int | token | ) |
void parser::PTXParser::State::closeBrace | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::colorComponent | ( | int | token | ) |
void parser::PTXParser::State::comparison | ( | int | token | ) |
void parser::PTXParser::State::constantOperand | ( | long long int | value | ) |
void parser::PTXParser::State::constantOperand | ( | unsigned long long int | value | ) |
void parser::PTXParser::State::constantOperand | ( | float | value | ) |
void parser::PTXParser::State::constantOperand | ( | double | value | ) |
void parser::PTXParser::State::convert | ( | int | token, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::convertC | ( | int | token, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::convertD | ( | int | token, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::ctapersm | ( | int | target, |
unsigned int | ctas | ||
) |
void parser::PTXParser::State::cvtaTo | ( | ) |
void parser::PTXParser::State::dataType | ( | int | token | ) |
void parser::PTXParser::State::decimalListSingle | ( | long long int | value | ) |
void parser::PTXParser::State::decimalListSingle2 | ( | long long int | value | ) |
void parser::PTXParser::State::defaultPermute | ( | ) |
void parser::PTXParser::State::entry | ( | const std::string & | name, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::entryDeclaration | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::entryStatement | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::fileDeclaration | ( | unsigned int | id, |
const std::string & | name | ||
) |
void parser::PTXParser::State::floatingPointMode | ( | int | token | ) |
void parser::PTXParser::State::floatList | ( | double | value | ) |
void parser::PTXParser::State::floatList1 | ( | double | value | ) |
void parser::PTXParser::State::formatMode | ( | int | token | ) |
void parser::PTXParser::State::full | ( | ) |
void parser::PTXParser::State::functionBegin | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::functionDeclaration | ( | YYLTYPE & | location, |
bool | body | ||
) |
void parser::PTXParser::State::functionName | ( | const std::string & | name, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::geometry | ( | int | token | ) |
void parser::PTXParser::State::guard | ( | const std::string & | name, |
YYLTYPE & | one, | ||
bool | invert | ||
) |
void parser::PTXParser::State::guard | ( | ) |
void parser::PTXParser::State::identifierList | ( | const std::string & | identifier | ) |
void parser::PTXParser::State::identifierList2 | ( | const std::string & | identifier | ) |
void parser::PTXParser::State::indexedOperand | ( | const std::string & | name, |
YYLTYPE & | location, | ||
long long int | value | ||
) |
void parser::PTXParser::State::initializableDeclaration | ( | const std::string & | name, |
YYLTYPE & | one, | ||
YYLTYPE & | two | ||
) |
void parser::PTXParser::State::instruction | ( | const std::string & | opcode, |
int | dataType | ||
) |
void parser::PTXParser::State::instruction | ( | const std::string & | opcode | ) |
void parser::PTXParser::State::instruction | ( | ) |
void parser::PTXParser::State::instructionVectorType | ( | int | token | ) |
void parser::PTXParser::State::label | ( | const std::string & | string | ) |
void parser::PTXParser::State::labelOperand | ( | const std::string & | string | ) |
void parser::PTXParser::State::level | ( | int | token | ) |
void parser::PTXParser::State::location | ( | long long int | one, |
long long int | two, | ||
long long int | three | ||
) |
void parser::PTXParser::State::locationAddress | ( | int | token | ) |
void parser::PTXParser::State::maxnctapersm | ( | ) |
void parser::PTXParser::State::maxnctapersm | ( | unsigned int | ctas | ) |
void parser::PTXParser::State::maxnreg | ( | unsigned int | regs | ) |
void parser::PTXParser::State::maxntid | ( | unsigned int | tidx, |
unsigned int | tidy = 1024 , |
||
unsigned int | tidz = 1024 |
||
) |
void parser::PTXParser::State::metadata | ( | const std::string & | comment | ) |
void parser::PTXParser::State::minnctapersm | ( | ) |
void parser::PTXParser::State::minnctapersm | ( | unsigned int | ctas | ) |
void parser::PTXParser::State::modifier | ( | int | token | ) |
void parser::PTXParser::State::noAddressSpace | ( | ) |
void parser::PTXParser::State::nonLabelOperand | ( | const std::string & | string, |
YYLTYPE & | location, | ||
bool | invert | ||
) |
void parser::PTXParser::State::openBrace | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::permute | ( | int | token | ) |
void parser::PTXParser::State::pragma | ( | const std::string & | string | ) |
void parser::PTXParser::State::preprocessor | ( | int | token | ) |
void parser::PTXParser::State::reduction | ( | int | token | ) |
void parser::PTXParser::State::registerDeclaration | ( | const std::string & | name, |
YYLTYPE & | location, | ||
unsigned int | regs = 0 |
||
) |
void parser::PTXParser::State::registerSeperator | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::relaxedConvert | ( | int | token, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::returnArgumentListBegin | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::returnArgumentListEnd | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::returnOperand | ( | ) |
void parser::PTXParser::State::returnType | ( | int | token | ) |
void parser::PTXParser::State::samplerDeclaration | ( | int | token, |
const std::string & | name, | ||
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::shiftAmount | ( | bool | shift | ) |
void parser::PTXParser::State::singleList | ( | float | value | ) |
void parser::PTXParser::State::singleList1 | ( | float | value | ) |
void parser::PTXParser::State::statementEnd | ( | YYLTYPE & | location | ) |
void parser::PTXParser::State::statementVectorType | ( | int | token | ) |
void parser::PTXParser::State::surfaceDeclaration | ( | int | token, |
const std::string & | name, | ||
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::surfaceQuery | ( | int | token | ) |
void parser::PTXParser::State::symbolListSingle | ( | const std::string & | identifier | ) |
void parser::PTXParser::State::symbolListSingle2 | ( | const std::string & | identifier | ) |
void parser::PTXParser::State::tail | ( | bool | condition | ) |
void parser::PTXParser::State::target | ( | ) |
void parser::PTXParser::State::targetElement | ( | int | token | ) |
void parser::PTXParser::State::tex | ( | int | dataType | ) |
void parser::PTXParser::State::textureDeclaration | ( | int | token, |
const std::string & | name, | ||
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::tld4 | ( | int | dataType | ) |
void parser::PTXParser::State::uni | ( | bool | condition | ) |
void parser::PTXParser::State::uninitializableDeclaration | ( | const std::string & | name | ) |
void parser::PTXParser::State::vectorIndex | ( | int | token | ) |
void parser::PTXParser::State::version | ( | double | version, |
YYLTYPE & | location | ||
) |
void parser::PTXParser::State::volatileFlag | ( | bool | condition | ) |
void parser::PTXParser::State::vote | ( | int | token | ) |
unsigned int parser::PTXParser::State::alignment |
std::string parser::PTXParser::State::comment |
std::string parser::PTXParser::State::fileName |
unsigned int parser::PTXParser::State::returnOperands |
std::string parser::PTXParser::State::sectionName |
std::string parser::PTXParser::State::sectionType |