OpenASIP
2.0
|
#include <MachineValidatorResults.hh>
Public Types | |
typedef std::pair< MachineValidator::ErrorCode, std::string > | Error |
Typedef for an error (error code + error message). More... | |
Public Member Functions | |
MachineValidatorResults () | |
virtual | ~MachineValidatorResults () |
int | errorCount () const |
Error | error (int index) const |
void | addError (MachineValidator::ErrorCode code, const std::string &errorMsg) |
Private Types | |
typedef std::vector< Error > | ErrorTable |
Typedef for vector of errors. More... | |
Private Attributes | |
ErrorTable | errors_ |
Contains the errors. More... | |
This class bundles up the results of MachineValidator.
Definition at line 45 of file MachineValidatorResults.hh.
typedef std::pair<MachineValidator::ErrorCode, std::string> MachineValidatorResults::Error |
Typedef for an error (error code + error message).
Definition at line 48 of file MachineValidatorResults.hh.
|
private |
Typedef for vector of errors.
Definition at line 62 of file MachineValidatorResults.hh.
MachineValidatorResults::MachineValidatorResults | ( | ) |
|
virtual |
void MachineValidatorResults::addError | ( | MachineValidator::ErrorCode | code, |
const std::string & | errorMsg | ||
) |
Adds an error to the results.
code | The error code. |
errorMsg | The error message. |
Definition at line 85 of file MachineValidatorResults.cc.
References error(), and errors_.
Referenced by MachineValidator::checkFUConnections(), MachineValidator::checkGCUExists(), MachineValidator::checkGCUHasAddressSpace(), MachineValidator::checkIMemAddrWidth(), MachineValidator::checkJumpAndCallOperandBindings(), FUValidator::checkOperandBindings(), FUValidator::checkOperations(), MachineValidator::checkProgramCounterPort(), MachineValidator::checkRAPortHasSameWidthAsPCPort(), and MachineValidator::checkReturnAddressPort().
MachineValidatorResults::Error MachineValidatorResults::error | ( | int | index | ) | const |
Returns an error by the given index.
index | The index. |
OutOfRange | If the given index is negative or not smaller than the number of errors. |
Definition at line 70 of file MachineValidatorResults.cc.
References __func__, errorCount(), and errors_.
Referenced by addError(), HDB::HDBManager::addFUArchitecture(), LLVMBackend::compile(), ProgrammabilityValidator::ProgrammabilityValidator(), and ProGe::ProcessorGenerator::validateMachine().
int MachineValidatorResults::errorCount | ( | ) | const |
Returns the number of errors.
Definition at line 56 of file MachineValidatorResults.cc.
References errors_.
Referenced by HDB::HDBManager::addFUArchitecture(), LLVMBackend::compile(), error(), ProgrammabilityValidator::ProgrammabilityValidator(), and ProGe::ProcessorGenerator::validateMachine().
|
private |
Contains the errors.
Definition at line 65 of file MachineValidatorResults.hh.
Referenced by addError(), error(), and errorCount().