Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 6 additions & 16 deletions libdevice/sanitizer_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,14 +143,8 @@ inline uptr MemToShadow_DG2(uptr addr, uint32_t as) {

auto launch_info = (__SYCL_GLOBAL__ const LaunchInfo *)__AsanLaunchInfo;
if (as == ADDRESS_SPACE_GLOBAL) { // global
uptr shadow_ptr;
if (addr & 0xFFFF000000000000ULL) { // Device USM
shadow_ptr = launch_info->GlobalShadowOffset + 0x80000000000ULL +
((addr & 0x7FFFFFFFFFFFULL) >> ASAN_SHADOW_SCALE);
} else { // Host/Shared USM
shadow_ptr =
launch_info->GlobalShadowOffset + (addr >> ASAN_SHADOW_SCALE);
}
uptr shadow_ptr = launch_info->GlobalShadowOffset +
((addr & 0x0000'FFFF'FFFF'FFFFULL) >> ASAN_SHADOW_SCALE);

ASAN_DEBUG(
const auto shadow_offset_end = launch_info->GlobalShadowOffsetEnd;
Expand Down Expand Up @@ -223,14 +217,10 @@ inline uptr MemToShadow_PVC(uptr addr, uint32_t as) {

auto launch_info = (__SYCL_GLOBAL__ const LaunchInfo *)__AsanLaunchInfo;
if (as == ADDRESS_SPACE_GLOBAL) { // global
uptr shadow_ptr;
if (addr & 0xFF00000000000000) { // Device USM
shadow_ptr = launch_info->GlobalShadowOffset + 0x80000000000 +
((addr & 0xFFFFFFFFFFFF) >> ASAN_SHADOW_SCALE);
} else { // Only consider 47bit VA
shadow_ptr = launch_info->GlobalShadowOffset +
((addr & 0x7FFFFFFFFFFF) >> ASAN_SHADOW_SCALE);
}
uptr shadow_ptr = launch_info->GlobalShadowOffset +
(((((addr & 0x8000'0000'0000'0000) >> 16) + addr) &
0xf'ffff'ffff'ffff) >>
ASAN_SHADOW_SCALE);

ASAN_DEBUG(
const auto shadow_offset_end = launch_info->GlobalShadowOffsetEnd;
Expand Down
2 changes: 1 addition & 1 deletion sycl/cmake/modules/FetchUnifiedRuntime.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ if(SYCL_UR_USE_FETCH_CONTENT)
CACHE PATH "Path to external '${name}' adapter source dir" FORCE)
endfunction()

set(UNIFIED_RUNTIME_REPO "https://github.com/oneapi-src/unified-runtime.git")
set(UNIFIED_RUNTIME_REPO "https://github.com/zhaomaosu/unified-runtime.git")
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules/UnifiedRuntimeTag.cmake)

set(UMF_BUILD_EXAMPLES OFF CACHE INTERNAL "EXAMPLES")
Expand Down
14 changes: 7 additions & 7 deletions sycl/cmake/modules/UnifiedRuntimeTag.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# commit f01741af022cfe82afcb026b9aa0be251eb6a497
# Merge: 004d2474 85bb5f62
# Author: Callum Fare <callum@codeplay.com>
# Date: Tue Nov 5 13:39:53 2024 +0000
# Merge pull request #2260 from nrspruit/refactor_l0_default_init
# [L0] Refactor to remove default constructor inits
set(UNIFIED_RUNTIME_TAG f01741af022cfe82afcb026b9aa0be251eb6a497)
# commit fa8cc8ec16c1a2cf0926cc64026edc6a254ff0c2
# Merge: 3d58884b 1984ceb1
# Author: aarongreig <aaron.greig@codeplay.com>
# Date: Thu Oct 31 14:05:55 2024 +0000
# Merge pull request #2228 from nrspruit/copy_engine_refactor
# [L0] Refactor Copy Engine Usage checks for Performance
set(UNIFIED_RUNTIME_TAG simplify-shadow-mapping)
Loading