@@ -34,6 +34,7 @@ from ._backend cimport ( # noqa: E211
34
34
DPCTLPlatform_GetPlatforms,
35
35
DPCTLPlatform_GetVendor,
36
36
DPCTLPlatform_GetVersion,
37
+ DPCTLPlatformMgr_GetInfo,
37
38
DPCTLPlatformMgr_PrintInfo,
38
39
DPCTLPlatformVector_Delete,
39
40
DPCTLPlatformVector_GetAt,
@@ -323,6 +324,7 @@ def lsplatform(verbosity=0):
323
324
cdef DPCTLPlatformVectorRef PVRef = NULL
324
325
cdef size_t v = 0
325
326
cdef size_t size = 0
327
+ cdef const char * info_str = NULL
326
328
cdef DPCTLSyclPlatformRef PRef = NULL
327
329
328
330
if not isinstance (verbosity, int ):
@@ -347,8 +349,11 @@ def lsplatform(verbosity=0):
347
349
if v != 0 :
348
350
print (" Platform " , i, " ::" )
349
351
PRef = DPCTLPlatformVector_GetAt(PVRef, i)
350
- DPCTLPlatformMgr_PrintInfo(PRef, v)
352
+ info_str = DPCTLPlatformMgr_GetInfo(PRef,v)
353
+ py_info = < bytes> info_str
354
+ DPCTLCString_Delete(info_str)
351
355
DPCTLPlatform_Delete(PRef)
356
+ print (py_info.decode(" utf-8" ),end= ' ' )
352
357
DPCTLPlatformVector_Delete(PVRef)
353
358
354
359
0 commit comments