@@ -35,6 +35,29 @@ cl::sycl::queue* backend_sycl::queue = nullptr;
35
35
#endif
36
36
mkl_rng::mt19937* backend_sycl::rng_engine = nullptr ;
37
37
38
+ static void dpnpc_show_mathlib_version ()
39
+ {
40
+ #if 1
41
+ const int len = 256 ;
42
+ std::string mathlib_version_str (len, 0x0 );
43
+
44
+ char * buf = const_cast <char *>(mathlib_version_str.c_str ()); // TODO avoid write into the container
45
+
46
+ mkl_get_version_string (buf, len);
47
+
48
+ std::cout << " Math backend version: " << mathlib_version_str << std::endl;
49
+ #else
50
+ // Failed to load library under Python environment die to unresolved symbol
51
+ MKLVersion version;
52
+
53
+ mkl_get_version(&version);
54
+
55
+ std::cout << "Math backend version: " << version.MajorVersion << "." << version.UpdateVersion << "."
56
+ << version.MinorVersion << std::endl;
57
+ #endif
58
+ }
59
+
60
+ #if not defined(NDEBUG)
38
61
static void show_available_sycl_devices ()
39
62
{
40
63
const std::vector<cl::sycl::device> devices = cl::sycl::device::get_devices ();
@@ -51,6 +74,7 @@ static void show_available_sycl_devices()
51
74
<< " , name=" << it->get_info <cl::sycl::info::device::name>() << std::endl;
52
75
}
53
76
}
77
+ #endif
54
78
55
79
static cl::sycl::device get_default_sycl_device ()
56
80
{
@@ -162,7 +186,10 @@ void backend_sycl::backend_sycl_queue_init(QueueOptions selector)
162
186
#else
163
187
std::cout << " DPCtrl SYCL queue used\n " ;
164
188
#endif
165
- std::cout << " SYCL kernels link time: " << time_kernels_link.count () << " (sec.)\n " << std::endl;
189
+ std::cout << " SYCL kernels link time: " << time_kernels_link.count () << " (sec.)\n " ;
190
+ dpnpc_show_mathlib_version ();
191
+
192
+ std::cout << std::endl;
166
193
}
167
194
168
195
bool backend_sycl::backend_sycl_is_cpu ()
0 commit comments