From 1aa0656d3411d6a4233855df20d6dc262f02d461 Mon Sep 17 00:00:00 2001 From: Ben Sander Date: Thu, 27 Jul 2017 11:11:54 -0500 Subject: [PATCH] Set HIP_SYNC_NULL_STREAM=0. Optimizes null stream synchronization so it uses GPU-side dependency resolution. Requires HCC __hcc_workweek__ > 17300. [ROCm/clr commit: cd4271113475253238ddd4c961872455fd4cce38] --- projects/clr/hipamd/src/hip_hcc.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/projects/clr/hipamd/src/hip_hcc.cpp b/projects/clr/hipamd/src/hip_hcc.cpp index 9d431df2dd..26799a9b11 100644 --- a/projects/clr/hipamd/src/hip_hcc.cpp +++ b/projects/clr/hipamd/src/hip_hcc.cpp @@ -86,13 +86,18 @@ int HIP_FORCE_SYNC_COPY = 0; int HIP_EVENT_SYS_RELEASE=1; int HIP_COHERENT_HOST_ALLOC = 0; -// TODO - set to 0 once we resolve stability. -// USE_ HIP_SYNC_HOST_ALLOC int HIP_SYNC_HOST_ALLOC = 1; + +#if (__hcc_workweek__ >= 17300) +// Make sure we have required bug fix in HCC +// Perform resolution on the GPU: // Chicken bit to sync on host to implement null stream. // If 0, null stream synchronization is performed on the GPU +int HIP_SYNC_NULL_STREAM = 0; +#else int HIP_SYNC_NULL_STREAM = 1; +#endif // HIP needs to change some behavior based on HCC_OPT_FLUSH : #if (__hcc_workweek__ >= 17296)