int _tmain(int argc, _TCHAR* argv[]) { srand((unsigned) time(NULL)); int test[MAX_ARR_NUM] = {0,}; testCountingSort(test, MAX_ARR_NUM); testRadixSort(test, MAX_ARR_NUM); return 0; }
void test_sorts() { testHeapSort(); testQuickSort(); // testInsertSort(); testCountingSort(); testRadixSort(); }
int main() { cout << "Testing getInfixExpression function: " << endl; testGetInfixExpression(); cout << endl; cout << "Testing radixSort function: " << endl; testRadixSort(); cout << endl; cout << "\nfinished" << endl; cin.ignore(); return 0; }
int main(int argc, char* argv[]) #endif { // libCL requires a root path to find the .cl files oclInit("../"); // find the first available platform oclContext* lContext = oclContext::create( oclContext::VENDOR_NVIDIA, CL_DEVICE_TYPE_GPU); if (!lContext) { lContext = oclContext::create( oclContext::VENDOR_AMD, CL_DEVICE_TYPE_GPU); if (!lContext) { lContext = oclContext::create( oclContext::VENDOR_INTEL, CL_DEVICE_TYPE_CPU); if (!lContext) { lContext = oclContext::create( oclContext::VENDOR_AMD, CL_DEVICE_TYPE_CPU); } } } if (!lContext) { Log(ERR) << "no OpenCL capable platform detected"; return -1; } else { Log(INFO) << "\n*\n*\n*" << "Running LibCL 1.0 using vendor platform: " << lContext->getName() << "\n*\n*"; } Log(INFO) << "\n\n"; // run tests Log(INFO) << "****** calling radix sort ..."; testRadixSort(*lContext); Log(INFO) << "****** done\n"; Log(INFO) << "****** calling fluid test 0 ..."; testFluid3D0(*lContext); Log(INFO) << "****** done\n"; Log(INFO) << "****** calling fluid test 1 ..."; testFluid3D1(*lContext); Log(INFO) << "****** done\n"; #ifdef WIN32 // ignore test to avoid crash Log(INFO) << "****** calling BVH construction ..."; testBvhTrimesh(*lContext); Log(INFO) << "****** done\n"; #endif Log(INFO) << "****** compiling all ..."; testCompile(*lContext); Log(INFO) << "****** done\n"; return 0; }