Skip to content
Snippets Groups Projects
Unverified Commit cf3bcb4e authored by fireice-uk's avatar fireice-uk Committed by GitHub
Browse files

Merge pull request #2298 from psychocrypt/fix-vegaWindowsAMDInvalid

OpenCL: fix windows vega and vii
parents b7b15104 a4b8ee4d
No related branches found
No related tags found
No related merge requests found
......@@ -334,6 +334,12 @@ size_t InitOpenCLGpu(cl_context opencl_ctx, GpuContext* ctx, const char* source_
*/
options += " -DOPENCL_DRIVER_MAJOR=" + std::to_string(std::stoi(openCLDriverVer.data()) / 100);
uint32_t isWindowsOs = 0;
#ifdef _WIN32
isWindowsOs = 1;
#endif
options += " -DIS_WINDOWS_OS=" + std::to_string(isWindowsOs);
if(miner_algo == cryptonight_gpu)
options += " -cl-fp32-correctly-rounded-divide-sqrt";
......
......@@ -1366,7 +1366,7 @@ __kernel void Groestl(__global ulong *states, __global uint *BranchBuf, __global
states += 25 * BranchBuf[idx];
ulong State[8] = { 0UL, 0UL, 0UL, 0UL, 0UL, 0UL, 0UL, 0x0001000000000000UL };
#if defined(__clang__) && !defined(__NV_CL_C_VERSION)
#if defined(__clang__) && !defined(__NV_CL_C_VERSION) && (IS_WINDOWS_OS != 1)
// on ROCM we need volatile for AMD RX5xx cards to avoid invalid shares
volatile
#endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment