144 if (inputSocket == &socket || outputSocket == &socket ||
145 firstUnconnected == &socket || secondUnconnected == &socket) {
176 if (parentRf != NULL) {
177 for (
int i = 0; i < parentRf->
portCount(); i++) {
213 if (&source == &destination) {
221 }
else if (destination.
canWrite(source)) {
233 bool adjacent =
false;
235 if (source.
nextBus() == &destination) {
252 if (source.
nextBus() != &destination &&
259 if (destination.
nextBus() != &source &&
314 if (name.length() == 0) {
318 for (
unsigned int i = 0; i < name.length(); i++) {
319 char character = name[i];
321 if (!isalpha(character)) {
325 if (!isalpha(character) && !isdigit(character) &&
326 character !=
'_' && character !=
':') {
523 if (&bus1 == &bus2) {
527 const Bus* bus = &bus1;
560 for (
int i = 0; i < socket.
portCount(); i++) {
#define assert(condition)
TTAMachine::Machine * machine
the architecture definition of the estimated processor
TTAMachine::Port * sameDirSocketConnection(TTAMachine::Socket::Direction direction) const
TTAMachine::Port * sameDirOutputSocketConn_
If the reason for failure when tried to set socket direction to output was that the socket is connect...
const TTAMachine::Machine * machine_
The machine on which the tests are carried out.
bool wrongSocketDirection_
Indicates if the reason for failure when trying to connect a socket to a port was that the direction ...
const TTAMachine::Bus * branchedBus_
If the reason for failure when trying to bridge two busses is that a branch in the bus chain would be...
bool legalPortConnections(const TTAMachine::Socket &socket, TTAMachine::Socket::Direction direction)
bool illegalRegistration_
Indicates if the reason for last test failure was illegal registration.
bool illegalRegistration() const
bool wrongSocketDirection() const
bool maxConnections() const
TTAMachine::Bus * branchedBus() const
virtual bool canConnect(const TTAMachine::Socket &socket, const TTAMachine::Segment &segment)
bool noConnections() const
TTAMachine::Port * forbiddenSocketDirection(TTAMachine::Socket::Direction direction) const
virtual bool canBridge(const TTAMachine::Bus &source, const TTAMachine::Bus &destination)
bool maxConnections_
Indicates if the reason for failure when trying to connect a socket to a port was that this connectio...
bool noConnections_
Indicates if the reason for failure when tried to set socket direction was that the socket has no seg...
static bool isValidComponentName(const std::string &name)
bool registerFilePortAlreadyConnected() const
MachineTester(const TTAMachine::Machine &machine)
bool connectionExists() const
TTAMachine::Port * sameDirInputSocketConn_
If the reason for failure when tried to set socket direction to input was that the socket is connecte...
bool unknownSocketDirection() const
TTAMachine::Port * forbiddenInputSocketDir_
If the reason for failure when tried to set socket direction to input was the socket is connected to ...
virtual bool canSetDirection(const TTAMachine::Socket &socket, TTAMachine::Socket::Direction direction)
bool loop_
Indicates if the reason for failure when trying to bridge two busses is that a loop in the bus chain ...
bool connectionExists_
Indicates if the reason for the last test failure is that the tested connection already exists.
bool unknownDir_
Indicates if tried to set the socket direction to Socket::UNKNOWN.
bool rfPortAlreadyConnected_
Indicates if the reason for failure is that a port of register file is already connected to a particu...
static bool areInSameChain(const TTAMachine::Bus &bus1, const TTAMachine::Bus &bus2)
virtual RFPort * port(const std::string &name) const
virtual Bus * previousBus() const
virtual bool canWrite(const Bus &bus) const
virtual bool hasPreviousBus() const
virtual bool hasNextBus() const
virtual Bus * nextBus() const
virtual Machine * machine() const
virtual Socket * outputSocket() const
virtual int socketCount() const
virtual Socket * unconnectedSocket(int index) const
virtual bool isConnectedTo(const Socket &socket) const
Unit * parentUnit() const
virtual Socket * inputSocket() const
@ OUTPUT
Data goes from port to bus.
@ INPUT
Data goes from bus to port.
@ UNKNOWN
Unknown direction.
bool isConnectedTo(const Bus &bus) const
Direction direction() const
Port * port(int index) const
virtual int portCount() const