forked from oneapi-src/unified-runtime
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SYCL][CUDA] Implement sycl_ext_oneapi_peer_access extension (#8303)
This implements the current extension doc from intel/llvm#6104 in the CUDA backend only. Fixes intel/llvm#7543. Fixes intel/llvm#6749. --------- Signed-off-by: JackAKirk <jack.kirk@codeplay.com> Co-authored-by: Nicolas Miller <nicolas.miller@codeplay.com> Co-authored-by: JackAKirk <chezjakirk@gmail.com> Co-authored-by: Steffen Larsen <steffen.larsen@intel.com>
- Loading branch information
1 parent
e32f6a9
commit 0d05bd0
Showing
2 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
//===----------- usm_p2p.cpp - L0 Adapter ----------------------------===// | ||
// | ||
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | ||
// See https://llvm.org/LICENSE.txt for license information. | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===-----------------------------------------------------------------===// | ||
|
||
#include "ur_level_zero.hpp" | ||
|
||
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PEnablePeerAccessExp( | ||
ur_device_handle_t commandDevice, ur_device_handle_t peerDevice) { | ||
|
||
std::ignore = commandDevice; | ||
std::ignore = peerDevice; | ||
|
||
urPrint("[UR][L0] %s function not implemented!\n", __FUNCTION__); | ||
return UR_RESULT_ERROR_UNSUPPORTED_FEATURE; | ||
} | ||
|
||
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PDisablePeerAccessExp( | ||
ur_device_handle_t commandDevice, ur_device_handle_t peerDevice) { | ||
|
||
std::ignore = commandDevice; | ||
std::ignore = peerDevice; | ||
|
||
urPrint("[UR][L0] %s function not implemented!\n", __FUNCTION__); | ||
return UR_RESULT_ERROR_UNSUPPORTED_FEATURE; | ||
} | ||
|
||
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PPeerAccessGetInfoExp( | ||
ur_device_handle_t commandDevice, ur_device_handle_t peerDevice, | ||
ur_exp_peer_info_t propName, size_t propSize, void *pPropValue, | ||
size_t *pPropSizeRet) { | ||
|
||
std::ignore = commandDevice; | ||
std::ignore = peerDevice; | ||
std::ignore = propName; | ||
|
||
UrReturnHelper ReturnValue(propSize, pPropValue, pPropSizeRet); | ||
// Zero return value indicates that all of the queries currently return false. | ||
return ReturnValue(uint32_t{0}); | ||
} |