Skip to content

Commit 0f83690

Browse files
authored
Revert "[SYCL][UR] Link UR PI against UR Loader" (intel#8781)
Reverts intel#8637 It caused at least 3 known regressions. 1. intel#8637 (comment) 2. \sycl\plugins\unified_runtime\ur\adapters\level_zero\ur_level_zero_common.hpp(10): fatal error C1083: Cannot open include file: 'sycl/detail/pi.h': No such file or directory 3. ld: error: undefined symbol: pthread_rwlock_wrlock (with GCC 7.5)
1 parent 3038a27 commit 0f83690

File tree

3 files changed

+6
-298
lines changed

3 files changed

+6
-298
lines changed

ur_level_zero.cpp

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ ur_result_t _ur_platform_handle_t::initialize() {
286286
return UR_RESULT_SUCCESS;
287287
}
288288

289-
ur_result_t urPlatformGet(
289+
UR_APIEXPORT ur_result_t UR_APICALL urPlatformGet(
290290
uint32_t NumEntries, ///< [in] the number of platforms to be added to
291291
///< phPlatforms. If phPlatforms is not NULL, then
292292
///< NumEntries should be greater than zero, otherwise
@@ -403,7 +403,7 @@ ur_result_t urPlatformGet(
403403
return UR_RESULT_SUCCESS;
404404
}
405405

406-
ur_result_t urPlatformGetInfo(
406+
UR_APIEXPORT ur_result_t UR_APICALL urPlatformGetInfo(
407407
ur_platform_handle_t Platform, ///< [in] handle of the platform
408408
ur_platform_info_t ParamName, ///< [in] type of the info to retrieve
409409
size_t Size, ///< [in] the number of bytes pointed to by pPlatformInfo.
@@ -457,7 +457,7 @@ ur_result_t urPlatformGetInfo(
457457
return UR_RESULT_SUCCESS;
458458
}
459459

460-
ur_result_t urDeviceGet(
460+
UR_APIEXPORT ur_result_t UR_APICALL urDeviceGet(
461461
ur_platform_handle_t Platform, ///< [in] handle of the platform instance
462462
ur_device_type_t DeviceType, ///< [in] the type of the devices.
463463
uint32_t NumEntries, ///< [in] the number of devices to be added to
@@ -534,7 +534,7 @@ ur_result_t urDeviceGet(
534534
return UR_RESULT_SUCCESS;
535535
}
536536

537-
ur_result_t urDeviceGetInfo(
537+
UR_APIEXPORT ur_result_t UR_APICALL urDeviceGetInfo(
538538
ur_device_handle_t Device, ///< [in] handle of the device instance
539539
ur_device_info_t ParamName, ///< [in] type of the info to retrieve
540540
size_t propSize, ///< [in] the number of bytes pointed to by pDeviceInfo.
@@ -1660,7 +1660,7 @@ void ZeUSMImportExtension::doZeUSMRelease(ze_driver_handle_t DriverHandle,
16601660
ZE_CALL_NOCHECK(zexDriverReleaseImportedPointer, (DriverHandle, HostPtr));
16611661
}
16621662

1663-
ur_result_t urDevicePartition(
1663+
UR_APIEXPORT ur_result_t UR_APICALL urDevicePartition(
16641664
ur_device_handle_t Device, ///< [in] handle of the device to partition.
16651665
const ur_device_partition_property_t
16661666
*Properties, ///< [in] null-terminated array of <$_device_partition_t
@@ -1741,9 +1741,3 @@ ur_result_t urDevicePartition(
17411741
}
17421742
return UR_RESULT_SUCCESS;
17431743
}
1744-
1745-
ur_result_t urInit(ur_device_init_flags_t device_flags) {
1746-
return UR_RESULT_SUCCESS;
1747-
}
1748-
1749-
ur_result_t urTearDown(void *pParams) { return UR_RESULT_SUCCESS; }

ur_level_zero_common.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ std::unordered_map<ze_result_t, ur_result_t> Ze2UrErrorMapping = {
3333
{ZE_RESULT_ERROR_INVALID_GROUP_SIZE_DIMENSION,
3434
UR_RESULT_ERROR_INVALID_WORK_GROUP_SIZE},
3535
{ZE_RESULT_ERROR_MODULE_BUILD_FAILURE,
36-
UR_RESULT_ERROR_PROGRAM_BUILD_FAILURE},
36+
UR_RESULT_ERROR_MODULE_BUILD_FAILURE},
3737
{ZE_RESULT_ERROR_OUT_OF_DEVICE_MEMORY,
3838
UR_RESULT_ERROR_OUT_OF_DEVICE_MEMORY},
3939
{ZE_RESULT_ERROR_OUT_OF_HOST_MEMORY, UR_RESULT_ERROR_OUT_OF_HOST_MEMORY}};

ur_loader_interface.cpp

Lines changed: 0 additions & 286 deletions
This file was deleted.

0 commit comments

Comments
 (0)