The kernel checks if input array `buf0` is monotonically increasing. If any element in the array `buf0` is greater than the next element, it breaks out of the loop and alters the output value, which the host side checks against. When the input array is of type `char`, the kernel will break out of the loop prematurely. However with other types such as int or float this kernel runs fine.
I can repro the bug on AMD RX500/Vega series. Running on Windows 10 + Adrenalin 18.2.2 18.12.2/19.1.1.
I don't see this exact kernel causing an issue with Intel/Nvidia/Qualcomm OpenCL driver compilers.
Thank you for reporting it. We will check and get back to you.
It seems that the "size" argument of clEnqueueReadBuffer was not correct. Can you please modify the code (in "main.cpp" file ) as shown below and share your observation?
Still, the error persists after the read buffer size is corrected.
After modifying the read buffer size, I didn't observe any issue on my test setup (Hawaii XT/Carrizo + Adrenalin 19.1.1). At this moment, I don't have a RX500/Vega series card to verify it myself. I'll ask the concerned team to reproduce it.
Please share the clinfo output.
The problem with this bug is that older drivers (Adrenalin 18.5.2 & 18.9.1) I tried did not have this strange behavior. I do not observer the same behavior on my other machine with HD6000 series on Crimson driver, though. So please do check running on at least Vega series.
Platform Vendor:                     Advanced Micro Devices, Inc.
Vendor:                          Advanced Micro Devices, Inc.
Thank you for providing the above useful information and sharing the clinfo output.
I've already reported it to the concerned team. Once I've any update, I'll get back to you.
dipak Any update? It's been a while now. Can you confirm that it's reproducible on your side?
I already opened a ticket against the issue. As per our issue tracking system, currently the ticket is under investigation. I'll try to get an update about it and share with you.
By the way, did you try the latest Adrenalin 19.3.1? If you see any different observation, please let us know.
Nope. Tried Adrenalin 19.3.2 and this issue still persists.
By the way, I asked the team for an update but haven't got any reply still now. Once I've any update, I'll get back to you. Thank you for your patience.
It's good to hear that the issue has been resolved. Thank you for the confirmation.