dpctl.SyclDevice.can_access_peer¶
- SyclDevice.can_access_peer(peer, value='access_supported')¶
Returns
Trueif this device (self) can enable peer access to USM device memory onpeer,Falseotherwise.If peer access is supported, it may be enabled by calling
enable_peer_access().For details, see DPC++ peer access SYCL extension.
- Parameters:
peer (
dpctl.SyclDevice) – Thedpctl.SyclDeviceinstance to check for peer access by this device.value (str, optional) –
Specifies the kind of peer access being queried.
The supported values are
"access_supported"Returns
Trueif it is possible for this device to enable peer access to USM device memory onpeer.
"atomics_supported"Returns
Trueif it is possible for this device to concurrently access and atomically modify USM device memory onpeerwhen enabled. Atomics must havememory_scope::systemwhen modifying memory on a peer device.
If
Falseis returned, these operations result in undefined behavior.Default:
"access_supported"
- Returns:
Trueif the kind of peer access specified byvalueis supported between this device andpeer, otherwiseFalse.- Return type:
- Raises:
TypeError – If
peeris notdpctl.SyclDevice.