21 lines
979 B
Plaintext
Executable File
21 lines
979 B
Plaintext
Executable File
auto myiter = WFR_SELF_GETITERATIONID();
|
|
std::cout << "AtomicActivity1 [" << myiter << "]:" << std::endl
|
|
<< "\tin1: " << sin->in1.getValue() << std::endl
|
|
<< "\tin2: " << sin->in2.getValue() << std::endl;
|
|
#include <sstream>
|
|
if (sin->in2.getValue() <= 0) {
|
|
std::stringstream ss;
|
|
ss << "Test Failure: in2 value [" << sin->in2.getValue() << "] is not greater than zero.";
|
|
throw wfr::exception::wfr_fatal_error(ss.str());
|
|
}
|
|
if (myiter+1 != sin->in1.getValue()) {
|
|
std::stringstream ss;
|
|
ss << "Test Failure: in1 value [" << sin->in1.getValue() << "] is not equal to iterationID+1 [" << myiter+1 << "].";
|
|
throw wfr::exception::wfr_fatal_error(ss.str());
|
|
}
|
|
if (sin->in1.getValue() > sin->in2.getValue()) {
|
|
std::stringstream ss;
|
|
ss << "Test Failure: in1 value [" << sin->in1.getValue() << "] is not less/equal than in2 value [" << sin->in2.getValue() << "].";
|
|
throw wfr::exception::wfr_fatal_error(ss.str());
|
|
}
|
|
sout->out1.setValue(sin->in1.getValue()); |