From cec48dd7b88ca414e95ec99afb608873947f54ef Mon Sep 17 00:00:00 2001 From: foreman Date: Wed, 23 Jul 2014 12:54:37 -0400 Subject: [PATCH] P4 to Git Change 1058368 by gandryey@gera-dev-w7 on 2014/07/23 12:46:38 ECR #304775 - Attempt to fix BUG#10085 - Align the scratch buffer size to 16 bytes. Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuscsi.cpp#24 edit --- rocclr/runtime/device/gpu/gpuscsi.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rocclr/runtime/device/gpu/gpuscsi.cpp b/rocclr/runtime/device/gpu/gpuscsi.cpp index f7b4300ab1..57824b65a3 100644 --- a/rocclr/runtime/device/gpu/gpuscsi.cpp +++ b/rocclr/runtime/device/gpu/gpuscsi.cpp @@ -186,7 +186,7 @@ HSAILKernel::aqlCreateHWInfo(const void* shader, size_t shaderSize) assert((akc->workitem_private_segment_byte_size & 3) == 0 && "Scratch must be DWORD aligned"); workGroupInfo_.scratchRegs_ = - akc->workitem_private_segment_byte_size / sizeof(uint); + amd::alignUp(akc->workitem_private_segment_byte_size, 16) / sizeof(uint); workGroupInfo_.availableSGPRs_ = dev().gslCtx()->getNumSGPRsAvailable(); workGroupInfo_.availableVGPRs_ = dev().gslCtx()->getNumVGPRsAvailable(); workGroupInfo_.preferredSizeMultiple_ = dev().getAttribs().wavefrontSize;