cancel
Showing results for 
Search instead for 
Did you mean: 

OpenCL

ymhsieh0226
Adept I

Sorting through Boost::Compute gives erroneous result

Hello,

I'm trying to use a W8100 with OpenCL to do data-sorting through Boost.Compute.  The machine we use has three OpenCL implementations, and only AMD w8100 gives incorrect result.  The code we use is posted at:

https://pastebin.com/JJ8QBivL

And the results are the following:

--------------------------------------------

33:Hawaii:OpenCL 1.2 AMD-APP (2639.3)

Before:

33 36 27 -35 43 -15 36 42 -1 -29 12 -23 40 9 13 -24 -10 -24 22 -14 -39 18 17 -21 32 -20 12 -27 17 -15 -21 -48 -28

After :

-48 -39 -35 -29 -28 -27 -24 -24 -23 -21 -21 -20 -15 -14 -10 -1 -10 -1 9 12 12 13 17 17 18 22 27 32 36 36 40 42 43

33:Intel(R) HD Graphics Skylake Desktop GT2:OpenCL 2.0 beignet 1.4 (git-591d3873)

Before:

33 36 27 -35 43 -15 36 42 -1 -29 12 -23 40 9 13 -24 -10 -24 22 -14 -39 18 17 -21 32 -20 12 -27 17 -15 -21 -48 -28

After :

-48 -39 -35 -29 -28 -27 -24 -24 -23 -21 -21 -20 -15 -15 -14 -10 -1 9 12 12 13 17 17 18 22 27 32 33 36 36 40 42 43

33:Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz:OpenCL 2.0 (Build 37)

Before:

33 36 27 -35 43 -15 36 42 -1 -29 12 -23 40 9 13 -24 -10 -24 22 -14 -39 18 17 -21 32 -20 12 -27 17 -15 -21 -48 -28

After :

-48 -39 -35 -29 -28 -27 -24 -24 -23 -21 -21 -20 -15 -15 -14 -10 -1 9 12 12 13 17 17 18 22 27 32 33 36 36 40 42 43

--------------------------------------------

Does any one has similar experience and or know where the problem is? 

Thanks,

Yo-Ming

0 Likes
6 Replies
dipak
Staff

Thank you for reporting this. We will investigate the problem. Please provide more details about your setup such as OS, driver version, SDK etc.

Please note: If the installed driver is not the latest one, please check with the latest driver and share your observation.

0 Likes

OS: Gentoo Linux

Kernel: Linux-4.17.13
Driver version: amdgpu-pro-18.20-621984 patched to avoid undefined function vga_switcheroo_set_dynamic_switch in 4.17 linux kernel

SDK; GitHub - boostorg/compute: A C++ GPU Computing Library for OpenCL

0 Likes

Thanks. We will check and get back to you.

Sorry for this delayed reply.

I also observed an erroneous result when I ran the above code on Hawaii (same as W8100 ) with latest Windows driver (18.30). Though the same code seems producing expected result on Carrizo.

Checking the example code, it looks like "compute::sort()" function is not working as expected.

From our side, it is very difficult to debug the library code and investigate the issue. I would suggest you to contact with the Boost Compute library team and check if it is possible to identify/isolate the relevant code that's causing the issue. If we get the repro, we will investigate the issue at our side.

0 Likes

If you were referring to repo as the repository of Boost::Compute, here is the Github link:

GitHub - boostorg/compute: A C++ GPU Computing Library for OpenCL

0 Likes

As I already said, it would be very difficult for us to debug a third-party library to investigate the issue. Even if I open a ticket, I don't think engineering team will accept it. We need a minimal test-case (host+ related kernel code) for that. Please check with the Boost Compute library team if they can help in this regard.

Thanks.

0 Likes