@@ -298,7 +298,7 @@ cdef class SyclDevice(_SyclDevice):
298
298
if ret == - 1 :
299
299
raise SyclDeviceCreationError(
300
300
" Could not create a SyclDevice with the selector string "
301
- " '{selector_string}'" .format(selector_string = arg)
301
+ " '{selector_string}'" .format(selector_string = arg)
302
302
)
303
303
elif isinstance (arg, _SyclDevice):
304
304
ret = self ._init_from__SyclDevice(arg)
@@ -544,7 +544,7 @@ cdef class SyclDevice(_SyclDevice):
544
544
@property
545
545
def has_aspect_usm_device_allocations (self ):
546
546
""" Returns True if this device supports explicit USM allocations,
547
- False otherwise (refer Siction 4.8 of SYCL 2020 specs).
547
+ False otherwise (refer Section 4.8 of SYCL 2020 specs).
548
548
549
549
Returns:
550
550
bool: Indicates that the device supports explicit USM allocations.
@@ -555,11 +555,11 @@ cdef class SyclDevice(_SyclDevice):
555
555
@property
556
556
def has_aspect_usm_host_allocations (self ):
557
557
""" Returns True if this device can access USM-host memory,
558
- False otherwise (refer Siction 4.8 of SYCL 2020 specs).
558
+ False otherwise (refer Section 4.8 of SYCL 2020 specs).
559
559
560
560
Returns:
561
561
bool: Indicates that the device can access USM memory
562
- allocated via ``usm::alloc::host ``.
562
+ allocated using ``sycl::malloc_host ``.
563
563
"""
564
564
cdef _aspect_type AT = _aspect_type._usm_host_allocations
565
565
return DPCTLDevice_HasAspect(self ._device_ref, AT)
@@ -571,7 +571,7 @@ cdef class SyclDevice(_SyclDevice):
571
571
572
572
Returns:
573
573
bool: Indicates that the device supports USM memory
574
- allocated via ``usm::alloc::shared ``.
574
+ allocated using ``sycl::malloc_shared ``.
575
575
"""
576
576
cdef _aspect_type AT = _aspect_type._usm_shared_allocations
577
577
return DPCTLDevice_HasAspect(self ._device_ref, AT)
@@ -582,8 +582,8 @@ cdef class SyclDevice(_SyclDevice):
582
582
allocated as restricted USM, False otherwise.
583
583
584
584
Returns:
585
- bool: Indicates that the device supports USM memory allocated via
586
- ``usm::alloc::shared `` as restricted USM.
585
+ bool: Indicates that the device supports USM memory allocated using
586
+ ``sycl::malloc_shared `` as restricted USM.
587
587
588
588
.. deprecated:: 0.14
589
589
"""
@@ -597,8 +597,8 @@ cdef class SyclDevice(_SyclDevice):
597
597
False otherwise.
598
598
599
599
Returns:
600
- bool: Indicates that system allocator may be used instead of SYCL
601
- ``usm::alloc::shared ``.
600
+ bool: Indicates that system allocator may be used instead of
601
+ ``sycl::malloc_shared ``.
602
602
"""
603
603
cdef _aspect_type AT = _aspect_type._usm_system_allocations
604
604
return DPCTLDevice_HasAspect(self ._device_ref, AT)
@@ -607,7 +607,10 @@ cdef class SyclDevice(_SyclDevice):
607
607
def has_aspect_usm_atomic_host_allocations (self ):
608
608
""" Returns True if this device supports USM-host allocations and
609
609
the host and this device may concurrently access and atomically
610
- modify host allocations, False otherwise
610
+ modify host allocations, False otherwise.
611
+
612
+ Returns:
613
+ bool: Indicates if the device supports USM atomic host allocations.
611
614
"""
612
615
cdef _aspect_type AT = _aspect_type._usm_atomic_host_allocations
613
616
return DPCTLDevice_HasAspect(self ._device_ref, AT)
@@ -991,7 +994,11 @@ cdef class SyclDevice(_SyclDevice):
991
994
992
995
@property
993
996
def __name__ (self ):
994
- " Name of the class `dpctl.SyclDevice`"
997
+ """ Returns the name of the class :class:`dpctl.SyclDevice`
998
+
999
+ Returns:
1000
+ str: Name of the class as a string.
1001
+ """
995
1002
return " SyclDevice"
996
1003
997
1004
def __repr__ (self ):
@@ -1009,9 +1016,8 @@ cdef class SyclDevice(_SyclDevice):
1009
1016
)
1010
1017
1011
1018
def __hash__ (self ):
1012
- """
1013
- Returns a hash value by hashing the underlying ``sycl::device`` object.
1014
-
1019
+ """ Returns a hash value by hashing the underlying ``sycl::device``
1020
+ object.
1015
1021
"""
1016
1022
return DPCTLDevice_Hash(self ._device_ref)
1017
1023
0 commit comments