Lines Matching defs:AtomicCounterTest

57 class AtomicCounterTest : public TestCase
109 AtomicCounterTest (Context& context, const char* name, const char* description, const TestSpec& spec);
110 ~AtomicCounterTest (void);
132 AtomicCounterTest& operator= (const AtomicCounterTest&);
133 AtomicCounterTest (const AtomicCounterTest&);
136 int AtomicCounterTest::getOperationCount (void) const
154 AtomicCounterTest::AtomicCounterTest (Context& context, const char* name, const char* description, const TestSpec& spec)
160 AtomicCounterTest::~AtomicCounterTest (void)
164 void AtomicCounterTest::init (void)
168 void AtomicCounterTest::deinit (void)
172 string AtomicCounterTest::generateShaderSource (const TestSpec& spec)
524 bool AtomicCounterTest::checkAndLogCounterValues (TestLog& log, const vector<deUint32>& counters) const
557 void AtomicCounterTest::splitBuffer (const vector<deUint32>& buffer, vector<deUint32>& increments, vector<deUint32>& decrements, vector<deUint32>& preGets, vector<deUint32>& postGets, vector<deUint32>& gets) const
633 void AtomicCounterTest::getCountersValues (vector<deUint32>& counterValues, const vector<deUint32>& values, int ndx, int counterCount)
643 bool AtomicCounterTest::checkRange (TestLog& log, const vector<deUint32>& values, const vector<deUint32>& min, const vector<deUint32>& max)
669 bool AtomicCounterTest::checkUniquenessAndLinearity (TestLog& log, const vector<deUint32>& values)
712 bool AtomicCounterTest::checkPath (const vector<deUint32>& increments, const vector<deUint32>& decrements, int initialValue, const TestSpec& spec)
806 bool AtomicCounterTest::checkAndLogCallValues (TestLog& log, const vector<deUint32>& increments, const vector<deUint32>& decrements, const vector<deUint32>& preGets, const vector<deUint32>& postGets, const vector<deUint32>& gets) const
915 TestCase::IterateResult AtomicCounterTest::iterate (void)
1050 string specToTestName (const AtomicCounterTest::TestSpec& spec)
1061 string specToTestDescription (const AtomicCounterTest::TestSpec& spec)
1069 if ((spec.operations & AtomicCounterTest::OPERATION_GET) != 0)
1075 if ((spec.operations & AtomicCounterTest::OPERATION_INC) != 0)
1084 if ((spec.operations & AtomicCounterTest::OPERATION_DEC) != 0)
1103 string operationToName (const AtomicCounterTest::Operation& operations, bool useBranch)
1108 if ((operations & AtomicCounterTest::OPERATION_GET) != 0)
1114 if ((operations & AtomicCounterTest::OPERATION_INC) != 0)
1123 if ((operations & AtomicCounterTest::OPERATION_DEC) != 0)
1138 string operationToDescription (const AtomicCounterTest::Operation& operations, bool useBranch)
1146 if ((operations & AtomicCounterTest::OPERATION_GET) != 0)
1152 if ((operations & AtomicCounterTest::OPERATION_INC) != 0)
1161 if ((operations & AtomicCounterTest::OPERATION_DEC) != 0)
1179 string layoutTypesToName (const AtomicCounterTest::BindingType& bindingType, const AtomicCounterTest::OffsetType& offsetType)
1185 case AtomicCounterTest::BINDINGTYPE_BASIC:
1189 case AtomicCounterTest::BINDINGTYPE_INVALID:
1197 if (bindingType != AtomicCounterTest::BINDINGTYPE_BASIC && offsetType != AtomicCounterTest::OFFSETTYPE_NONE)
1202 case AtomicCounterTest::OFFSETTYPE_BASIC:
1206 case AtomicCounterTest::OFFSETTYPE_REVERSE:
1210 case AtomicCounterTest::OFFSETTYPE_INVALID:
1214 case AtomicCounterTest::OFFSETTYPE_FIRST_AUTO:
1218 case AtomicCounterTest::OFFSETTYPE_DEFAULT_AUTO:
1222 case AtomicCounterTest::OFFSETTYPE_RESET_DEFAULT:
1226 case AtomicCounterTest::OFFSETTYPE_NONE:
1237 string layoutTypesToDesc (const AtomicCounterTest::BindingType& bindingType, const AtomicCounterTest::OffsetType& offsetType)
1243 case AtomicCounterTest::BINDINGTYPE_BASIC:
1247 case AtomicCounterTest::BINDINGTYPE_INVALID:
1251 case AtomicCounterTest::BINDINGTYPE_INVALID_DEFAULT:
1261 case AtomicCounterTest::OFFSETTYPE_NONE:
1265 case AtomicCounterTest::OFFSETTYPE_BASIC:
1269 case AtomicCounterTest::OFFSETTYPE_REVERSE:
1273 case AtomicCounterTest::OFFSETTYPE_INVALID:
1277 case AtomicCounterTest::OFFSETTYPE_FIRST_AUTO:
1281 case AtomicCounterTest::OFFSETTYPE_DEFAULT_AUTO:
1285 case AtomicCounterTest::OFFSETTYPE_RESET_DEFAULT:
1318 const AtomicCounterTest::Operation operations[] =
1320 AtomicCounterTest::OPERATION_GET,
1321 AtomicCounterTest::OPERATION_INC,
1322 AtomicCounterTest::OPERATION_DEC,
1324 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_INC|AtomicCounterTest::OPERATION_GET),
1325 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_DEC|AtomicCounterTest::OPERATION_GET),
1327 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_INC|AtomicCounterTest::OPERATION_DEC),
1328 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_INC|AtomicCounterTest::OPERATION_DEC|AtomicCounterTest::OPERATION_GET)
1333 const AtomicCounterTest::Operation operation = operations[operationNdx];
1359 AtomicCounterTest::TestSpec spec;
1366 spec.bindingType = AtomicCounterTest::BINDINGTYPE_BASIC;
1367 spec.offsetType = AtomicCounterTest::OFFSETTYPE_NONE;
1369 operationGroup->addChild(new AtomicCounterTest(m_context, specToTestName(spec).c_str(), specToTestDescription(spec).c_str(), spec));
1386 const AtomicCounterTest::Operation operations[] =
1388 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_INC|AtomicCounterTest::OPERATION_GET),
1389 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_DEC|AtomicCounterTest::OPERATION_GET),
1390 (AtomicCounterTest::Operation)(AtomicCounterTest::OPERATION_INC|AtomicCounterTest::OPERATION_DEC)
1393 const AtomicCounterTest::OffsetType offsetTypes[] =
1395 AtomicCounterTest::OFFSETTYPE_REVERSE,
1396 AtomicCounterTest::OFFSETTYPE_FIRST_AUTO,
1397 AtomicCounterTest::OFFSETTYPE_DEFAULT_AUTO,
1398 AtomicCounterTest::OFFSETTYPE_RESET_DEFAULT
1403 const AtomicCounterTest::OffsetType offsetType = offsetTypes[offsetTypeNdx];
1405 TestCaseGroup* layoutQualifierGroup = new TestCaseGroup(m_context, layoutTypesToName(AtomicCounterTest::BINDINGTYPE_BASIC, offsetType).c_str(), layoutTypesToDesc(AtomicCounterTest::BINDINGTYPE_BASIC, offsetType).c_str());
1409 const AtomicCounterTest::Operation operation = operations[operationNdx];
1417 if (offsetType == AtomicCounterTest::OFFSETTYPE_FIRST_AUTO && counterCount < 3)
1420 if (offsetType == AtomicCounterTest::OFFSETTYPE_DEFAULT_AUTO && counterCount < 2)
1423 if (offsetType == AtomicCounterTest::OFFSETTYPE_RESET_DEFAULT && counterCount < 2)
1426 if (offsetType == AtomicCounterTest::OFFSETTYPE_REVERSE && counterCount < 2)
1437 AtomicCounterTest::TestSpec spec;
1444 spec.bindingType = AtomicCounterTest::BINDINGTYPE_BASIC;
1447 operationGroup->addChild(new AtomicCounterTest(m_context, specToTestName(spec).c_str(), specToTestDescription(spec).c_str(), spec));
1460 AtomicCounterTest::TestSpec spec;
1463 spec.operations = AtomicCounterTest::OPERATION_INC;
1467 spec.bindingType = AtomicCounterTest::BINDINGTYPE_INVALID;
1468 spec.offsetType = AtomicCounterTest::OFFSETTYPE_NONE;
1470 invalidGroup->addChild(new AtomicCounterTest(m_context, "invalid_binding", "Test layout qualifiers with invalid binding.", spec));
1474 AtomicCounterTest::TestSpec spec;
1477 spec.operations = AtomicCounterTest::OPERATION_INC;
1481 spec.bindingType = AtomicCounterTest::BINDINGTYPE_INVALID_DEFAULT;
1482 spec.offsetType = AtomicCounterTest::OFFSETTYPE_NONE;
1484 invalidGroup->addChild(new AtomicCounterTest(m_context, "invalid_default_binding", "Test layout qualifiers with invalid default binding.", spec));
1488 AtomicCounterTest::TestSpec spec;
1491 spec.operations = AtomicCounterTest::OPERATION_INC;
1495 spec.bindingType = AtomicCounterTest::BINDINGTYPE_BASIC;
1496 spec.offsetType = AtomicCounterTest::OFFSETTYPE_INVALID;
1498 invalidGroup->addChild(new AtomicCounterTest(m_context, "invalid_offset_align", "Test layout qualifiers with invalid alignment offset.", spec));
1502 AtomicCounterTest::TestSpec spec;
1505 spec.operations = AtomicCounterTest::OPERATION_INC;
1509 spec.bindingType = AtomicCounterTest::BINDINGTYPE_BASIC;
1510 spec.offsetType = AtomicCounterTest::OFFSETTYPE_INVALID_OVERLAPPING;
1512 invalidGroup->addChild(new AtomicCounterTest(m_context, "invalid_offset_overlap", "Test layout qualifiers with invalid overlapping offset.", spec));
1516 AtomicCounterTest::TestSpec spec;
1519 spec.operations = AtomicCounterTest::OPERATION_INC;
1523 spec.bindingType = AtomicCounterTest::BINDINGTYPE_BASIC;
1524 spec.offsetType = AtomicCounterTest::OFFSETTYPE_INVALID_DEFAULT;
1526 invalidGroup->addChild(new AtomicCounterTest(m_context, "invalid_default_offset", "Test layout qualifiers with invalid default offset.", spec));