@@ -5857,6 +5857,42 @@ pi_result hip_piGetDeviceAndHostTimer(pi_device Device, uint64_t *DeviceTime,
5857
5857
return PI_SUCCESS;
5858
5858
}
5859
5859
5860
+ pi_result hip_piextEnablePeerAccess (pi_device command_device,
5861
+ pi_device peer_device) {
5862
+
5863
+ std::ignore = command_device;
5864
+ std::ignore = peer_device;
5865
+
5866
+ setErrorMessage (" piextEnablePeerAccess not "
5867
+ " implemented in hip backend" ,
5868
+ PI_ERROR_PLUGIN_SPECIFIC_ERROR);
5869
+ return PI_ERROR_PLUGIN_SPECIFIC_ERROR;
5870
+ }
5871
+
5872
+ pi_result hip_piextDisablePeerAccess (pi_device command_device,
5873
+ pi_device peer_device) {
5874
+
5875
+ std::ignore = command_device;
5876
+ std::ignore = peer_device;
5877
+
5878
+ setErrorMessage (" piextDisablePeerAccess not "
5879
+ " implemented in hip backend" ,
5880
+ PI_ERROR_PLUGIN_SPECIFIC_ERROR);
5881
+ return PI_ERROR_PLUGIN_SPECIFIC_ERROR;
5882
+ }
5883
+
5884
+ pi_result hip_piextPeerAccessGetInfo (pi_device command_device,
5885
+ pi_device peer_device, pi_peer_attr attr,
5886
+ size_t param_value_size, void *param_value,
5887
+ size_t *param_value_size_ret) {
5888
+ std::ignore = command_device;
5889
+ std::ignore = peer_device;
5890
+ std::ignore = attr;
5891
+ // Zero return value indicates that all of the queries currently return false.
5892
+ return getInfo (param_value_size, param_value, param_value_size_ret,
5893
+ pi_int32{0 });
5894
+ }
5895
+
5860
5896
const char SupportedVersion[] = _PI_HIP_PLUGIN_VERSION_STRING;
5861
5897
5862
5898
pi_result piPluginInit (pi_plugin *PluginInit) {
@@ -6028,6 +6064,11 @@ pi_result piPluginInit(pi_plugin *PluginInit) {
6028
6064
_PI_CL (piGetDeviceAndHostTimer, hip_piGetDeviceAndHostTimer)
6029
6065
_PI_CL (piPluginGetBackendOption, hip_piPluginGetBackendOption)
6030
6066
6067
+ // Peer to Peer
6068
+ _PI_CL (piextEnablePeerAccess, hip_piextEnablePeerAccess)
6069
+ _PI_CL (piextDisablePeerAccess, hip_piextDisablePeerAccess)
6070
+ _PI_CL (piextPeerAccessGetInfo, hip_piextPeerAccessGetInfo)
6071
+
6031
6072
#undef _PI_CL
6032
6073
6033
6074
return PI_SUCCESS;
0 commit comments