ocl: dump device info in tests
This commit is contained in:
@@ -564,12 +564,23 @@ CV_EXPORTS void cvTsConvert( const CvMat* src, CvMat* dst );
|
||||
CV_EXPORTS void cvTsGEMM( const CvMat* a, const CvMat* b, double alpha,
|
||||
const CvMat* c, double beta, CvMat* d, int flags );
|
||||
|
||||
#define CV_TEST_MAIN(resourcesubdir) \
|
||||
#ifndef __CV_TEST_EXEC_ARGS
|
||||
#if defined(_MSC_VER) && (_MSC_VER <= 1400)
|
||||
#define __CV_TEST_EXEC_ARGS(...) \
|
||||
while (++argc >= (--argc,-1)) {__VA_ARGS__; break;} /*this ugly construction is needed for VS 2005*/
|
||||
#else
|
||||
#define __CV_TEST_EXEC_ARGS(...) \
|
||||
__VA_ARGS__;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define CV_TEST_MAIN(resourcesubdir, ...) \
|
||||
int main(int argc, char **argv) \
|
||||
{ \
|
||||
cvtest::TS::ptr()->init(resourcesubdir); \
|
||||
::testing::InitGoogleTest(&argc, argv); \
|
||||
cvtest::printVersionInfo();\
|
||||
cvtest::printVersionInfo(); \
|
||||
__CV_TEST_EXEC_ARGS(__VA_ARGS__) \
|
||||
return RUN_ALL_TESTS(); \
|
||||
}
|
||||
|
||||
|
@@ -477,23 +477,25 @@ CV_EXPORTS void PrintTo(const Size& sz, ::std::ostream* os);
|
||||
INSTANTIATE_TEST_CASE_P(/*none*/, fixture##_##name, params);\
|
||||
void fixture##_##name::PerfTestBody()
|
||||
|
||||
#ifndef __CV_TEST_EXEC_ARGS
|
||||
#if defined(_MSC_VER) && (_MSC_VER <= 1400)
|
||||
#define CV_PERF_TEST_MAIN_INTERNALS_ARGS(...) \
|
||||
#define __CV_TEST_EXEC_ARGS(...) \
|
||||
while (++argc >= (--argc,-1)) {__VA_ARGS__; break;} /*this ugly construction is needed for VS 2005*/
|
||||
#else
|
||||
#define CV_PERF_TEST_MAIN_INTERNALS_ARGS(...) \
|
||||
#define __CV_TEST_EXEC_ARGS(...) \
|
||||
__VA_ARGS__;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define CV_PERF_TEST_MAIN_INTERNALS(modulename, impls, ...) \
|
||||
CV_PERF_TEST_MAIN_INTERNALS_ARGS(__VA_ARGS__) \
|
||||
::perf::Regression::Init(#modulename);\
|
||||
::perf::TestBase::Init(std::vector<std::string>(impls, impls + sizeof impls / sizeof *impls),\
|
||||
argc, argv);\
|
||||
::testing::InitGoogleTest(&argc, argv);\
|
||||
cvtest::printVersionInfo();\
|
||||
::testing::Test::RecordProperty("cv_module_name", #modulename);\
|
||||
::perf::TestBase::RecordRunParameters();\
|
||||
::perf::Regression::Init(#modulename); \
|
||||
::perf::TestBase::Init(std::vector<std::string>(impls, impls + sizeof impls / sizeof *impls), \
|
||||
argc, argv); \
|
||||
::testing::InitGoogleTest(&argc, argv); \
|
||||
cvtest::printVersionInfo(); \
|
||||
::testing::Test::RecordProperty("cv_module_name", #modulename); \
|
||||
::perf::TestBase::RecordRunParameters(); \
|
||||
__CV_TEST_EXEC_ARGS(__VA_ARGS__) \
|
||||
return RUN_ALL_TESTS();
|
||||
|
||||
// impls must be an array, not a pointer; "plain" should always be one of the implementations
|
||||
|
Reference in New Issue
Block a user