Ethminer: OpenCL 1.2 AMD-APP not supported

Created on 3 Aug 2017  Â·  34Comments  Â·  Source: ethereum-mining/ethminer

Hello I'm trying to get this running on my AMD R9 280X. Installing the old catalyst driver is a bit of a hassle so I want to avoid that.

I'm running the open-source amdgpu driver with proprietary amdgpu-pro support for opencl:

ethminer-git git:(master) ✗ sudo ethminer -M -G
ℹ 01:07:35|ethminer Found suitable OpenCL device [ Tahiti ] with 3041964032 bytes of GPU memory
Benchmarking on platform: CL
Preparing DAG for block #0
cl 01:07:35|cl-0 No work. Pause.
cl 01:07:35|cl-0 Set work. Header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000
cl 01:07:35|cl-0 Initialising miner with seed #00000000…
Warming up...
cl 01:07:36|cl-0 Platform: AMD Accelerated Parallel Processing
cl 01:07:36|cl-0 Device: Tahiti / OpenCL 1.2 AMD-APP (2442.7)
✘ 01:07:36|cl-0 clCreateCommandQueue ( -6 )
✘ 01:07:36|cl-0 OpenCL Error: clEnqueueWriteBuffer -36
Trial 1... 0
Trial 2... 0
Trial 3... 0
Trial 4... 0
Trial 5... 0

Any idea why this fails?

Most helpful comment

GCN1.0 and earlier do not like the new drivers, use 13.12 (best) or 14.xx at newest or they don't work correctly. There is no workaround, driver is bug city.

I run Ubuntu 14, downgraded kernel 3.2, and fglrx 13 and everything OpenCL works flawlessly at twice the speeds of any newer driver. May as well have made them deprecated after catalyst 13 as they don't work. This also means you probably can't run RX on the same rig as old ass cards, due to drivers. Same sort of deal as how you can't run CUDA 2.x platform (GTX5xx or such) in same rig as anything newer (CUDA throws dumb buggy unavailability errors)

All 34 comments

@maxammann Can you confirm that any OpenCL program runs on your machine? Just try clinfo for example.

It is important that you use both 32bit on clinfo and ethminer OR use both 64bit on clinfo and ethminer. You need to have the same programs in order to confirm that OpenCL is running in general.

This is the output of clinfo: https://gist.github.com/maxammann/b98366bffe625d88bdd10da307b1c270

clinfo and ethminer are 64bit.

@EoD I tried to run an opencl program which failed with the same error code. Any idea what I could check?

@maxammann sorry, I did not realise that you are on Linux. Can you please run ethminer -G -M -v 9? You can drop the sudo afaik.

Additionally, there are some bugs in the current amdgpu (kernel) driver, so you might need to work around those: https://bugs.freedesktop.org/buglist.cgi?quicksearch=ethminer

@EoD I get exactly the same output

This is the output when I use just amdgpu without properitary parts:

ℹ 19:51:19|ethminer Found suitable OpenCL device [ AMD TAHITI (DRM 3.15.0 / 4.12.3-1-ARCH, LLVM 4.0.1) ] with 3220066304 bytes of GPU memory
Benchmarking on platform: CL
Preparing DAG for block #0
cl 19:51:19|cl-0 No work. Pause.
Warming up...
cl 19:51:19|cl-0 Set work. Header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000
cl 19:51:19|cl-0 Initialising miner with seed #00000000…
cl 19:51:19|cl-0 Platform: Clover
cl 19:51:19|cl-0 Device: AMD TAHITI (DRM 3.15.0 / 4.12.3-1-ARCH, LLVM 4.0.1) / OpenCL 1.1 Mesa 17.1.6
cl 19:51:19|cl-0 OpenCL 1.1 not supported - minimum required version is 1.2
✘ 19:51:19|cl-0 OpenCL Error: clEnqueueWriteBuffer -36
Trial 1... 0
Trial 2... 0

@maxammann No, it's not exactly the same message :)

cl 19:51:19|cl-0 Platform: Clover
cl 19:51:19|cl-0 Device: AMD TAHITI (DRM 3.15.0 / 4.12.3-1-ARCH, LLVM 4.0.1) / OpenCL 1.1 Mesa 17.1.6
cl 19:51:19|cl-0 OpenCL 1.1 not supported - minimum required version is 1.2

The issue of Clover not being recognized at the current git-master is a known bug and it's tracked in #216. You can downgrade to https://github.com/ethereum-mining/ethminer/releases/tag/v0.12.0.dev1 in order to "fix" the issue.

I wouldn't be surprised if we have the same issue with AMD Accelerated Parallel Processing, but this would not cause a failure of OpenCL 1.1, as your clinfo reports OpenCL 1.2

  Platform Name                                   AMD Accelerated Parallel Processing
Number of devices                                 1
  Device Name                                     Tahiti
  Device Vendor                                   Advanced Micro Devices, Inc.
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 1.2 AMD-APP (2442.7)
  Driver Version                                  2442.7
  Device OpenCL C Version                         OpenCL C 1.2 

So it would be great to have a ethminer -G -M -v 9 with your proprietary amdgpu driver.

EDIT: added more info

sorry, but I meant the output of ethminer is the same with -v 9 or without. Should there be more information?

Thanks for the hint with the Clover bug, I'll look into that version :+1:

Yes, I was hoping there would be more information. Your error clCreateCommandQueue ( -6 ) basically means CL_OUT_OF_HOST_MEMORY, but I hoped -v 9 would add more information to that. I guess we need better error handling in such cases (as in "tell us how much is missing").

If you do ethminer --list-devices you should see CL_DEVICE_MAX_MEM_ALLOC_SIZE and I guess this is 2GB only, even though your devices has 3GB of memory in total. If this is the case, you are out of luck as ethereum mining requires >2GB at the moment.

EDIT: actually your clinfo already says so, but I missed it before.

My card has 2,64044544GB though. CL_DEVICE_GLOBAL_MEM_SIZE is a bit bigger. Seems like the proprietary has some issues as another opencl test program I compiled failed with the same error. Will look into it tomorrow and let you know :)

Hi, got the exact same issue on a 4GB RX480 ; my HD7950 works like a charm besides but apparently, APP got a problem. Anyone knows if it's an AMD-related bug?

To be more precise, when I run ethminer -G -M -v 9 get at the end: clSetKernelArg -49.

I'm also getting the clSetKernelArg -49 error after trial 5 on benchmark run.
Here is clinfo: https://gist.github.com/AntoniosHadji/79d9531519733fc49e63d08b633a21a6
Here is output from ethminer: https://gist.github.com/AntoniosHadji/383bd3b6edf3fe5d1be277d43a8d64b2

Machine is Ubuntu 16.04.3 LTS with hwe kernel. This issue was also happening before I upgraded the kernel. GPU is RX 570 8GB.

AMD APP SDK 3.0 is installed and amdgpu-pro drivers version 17.30
amdgpu-pro-core 17.30-465504
amdgpu-pro-dkms 17.30-465504
clinfo-amdgpu-pro 17.30-465504
ids-amdgpu-pro 1.0.0-465504
libdrm-amdgpu-pro-amdgpu1:amd64 1:2.4.70-465504
libdrm-amdgpu1:amd64 2.4.76-1ubuntu16.04.1
libdrm2-amdgpu-pro:amd64 1:2.4.70-465504
libopencl1-amdgpu-pro:amd64 17.30-465504
opencl-amdgpu-pro-icd:amd64 17.30-465504
xserver-xorg-video-amdgpu-hwe-16.04 1.3.0-0ubuntu1 16.04.1

Seen with RX 470. Latest amd-gpu-pro drivers. Trying the benchmark causes the process to become defunct/zombie. Let me know if there's any detail I can provide.

Getting this issue on Radeon HD 7870 (Pitcairn/GCN1.0) with ethminer v0.12.0 on Ubuntu 16.04 with AMDGPU-Pro drivers version 17.40-492261

sudo ./ethminer -v 9 -M -G:
ℹ 19:18:15|ethminer Found suitable OpenCL device [ Pitcairn ] with 1836769280 bytes of GPU memory Benchmarking on platform: CL Preparing DAG for block #0 cl 19:18:15|cl-0 No work. Pause for 3 s. Warming up... cl 19:18:18|cl-0 New work: header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000 cl 19:18:18|cl-0 New seed #00000000… cl 19:18:19|cl-0 Platform: AMD Accelerated Parallel Processing cl 19:18:19|cl-0 Device: Pitcairn / OpenCL 1.2 AMD-APP (2482.3) ✘ 19:18:19|cl-0 clCreateCommandQueue ( -6 ) ✘ 19:18:19|cl-0 OpenCL Error: clEnqueueWriteBuffer -36 Trial 1... 0 Trial 2... 0 Trial 3... 0 Trial 4... 0 Trial 5... 0 min/mean/max: 0/0/0 H/s inner mean: 0 H/s

glxinfo clinfo

Can provide any other requested logs/info

According to https://askubuntu.com/q/821341/95681, it looks like this could possibly be fixed by

sudo ln -vsf /opt/AMDAPPSDK-3.0/lib/x86_64/sdk/libamdocl64.so /usr/lib/x86_64-linux-gnu/

I will try this and report back with results once I get home; or if someone else could give it a go, perhaps this issue could be resolved.

If this doesn't, we may be out of luck; it looks like this issue has been buried.

No luck. Installing AMD APP SDK v3.0.130.136-GA does not seem to have fixed it.

Might be upstream's fault

https://community.amd.com/thread/214095 (from April! Several responses from people with Pitcairn)

Any call to clCreateCommandQueue triggers OpenCL error -6

https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/open-source-amd-linux/888909-what-is-the-state-of-opencl-on-ubuntu-16-04-for-gcn-1-0-cards

There is work being done extending support to gen. 1, but community work and no timeline.

you'd need to get amdgpu and libdrm working, the OpenCL blob would hook in and should support Pitcairn already. There is a new mailing list for AMD, you could say hello and ask for more info there

updated SI amdgpu tree yesterday - still in development but moving: https://cgit.freedesktop.org/~agd5f/linux/log/?h=drm-next-4.9-si

Such is the limbo hell of GCN1.0

Too new for proper Radeon support; too old for proper AMDGPU support

p.s. Smile, we're live! Apparently this thread is the forefront of research into this topic.
screenshot_2017-12-12_19-52-00

Found some helpful stuff: https://ethereum.stackexchange.com/a/24680/25345

GPU_FORCE_64BIT_PTR=1 allows it to proceed past the clCreateCommandQueue ( -6 ) and OpenCL Error: clEnqueueWriteBuffer -36 errors, but turns this into Issue #346 on my system (none of the other suggested environment variables seemingly had any effect when adding/removing them, but I've left them in for this run just for good measure)

GPU_MAX_HEAP_SIZE=100 GPU_SINGLE_ALLOC_PERCENT=100 GPU_FORCE_64BIT_PTR=1 GPU_USE_SYNC_OBJECTS=1 GPU_MAX_ALLOC_PERCENT=100 ./ethminer -G -M -v 9
ℹ 20:01:20|ethminer Found suitable OpenCL device [ Pitcairn ] with 1951195136 bytes of GPU memory Benchmarking on platform: CL Preparing DAG for block #0 cl 20:01:20|cl-0 No work. Pause for 3 s. Warming up... cl 20:01:23|cl-0 New work: header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000 cl 20:01:23|cl-0 New seed #00000000… cl 20:01:24|cl-0 Platform: AMD Accelerated Parallel Processing cl 20:01:24|cl-0 Device: Pitcairn / OpenCL 1.2 AMD-APP (2482.3) cl 20:01:24|cl-0 Build info: cl 20:01:24|cl-0 Creating light cache buffer, size 16776896 cl 20:01:24|cl-0 Creating DAG buffer, size 1073739904 cl 20:01:24|cl-0 Loading kernels cl 20:01:24|cl-0 Writing light cache buffer cl 20:01:24|cl-0 Creating buffer for header. cl 20:01:24|cl-0 Creating mining buffer cl 20:01:24|cl-0 Generating DAG cl 20:01:25|cl-0 DAG 0 % cl 20:01:25|cl-0 DAG 6 % cl 20:01:25|cl-0 DAG 12 % cl 20:01:25|cl-0 DAG 18 % cl 20:01:25|cl-0 DAG 25 % cl 20:01:26|cl-0 DAG 31 % cl 20:01:26|cl-0 DAG 37 % cl 20:01:26|cl-0 DAG 43 % cl 20:01:26|cl-0 DAG 50 % cl 20:01:27|cl-0 DAG 56 % cl 20:01:27|cl-0 DAG 62 % cl 20:01:27|cl-0 DAG 68 % cl 20:01:27|cl-0 DAG 75 % cl 20:01:27|cl-0 DAG 81 % cl 20:01:28|cl-0 DAG 87 % cl 20:01:28|cl-0 DAG 93 % cl 20:01:28|cl-0 Switch time 8290 ms / 5290475 us Trial 1... 16470878 Trial 2... 16993728 Trial 3... 16995428 Trial 4... 16995428 Trial 5... 16892208 ✘ 20:01:50|cl-0 OpenCL Error: clSetKernelArg -49 min/mean/max: 16470878/16869534/16995428 H/s inner mean: 16960454 H/s

Still, GPU_FORCE_64BIT_PTR might actually "solve" _this_ issue, anyway.

Hmmmmmmmmmmmmmmmmmmmmmm

it works with GPU_FORCE_64BIT_PTR=1

(—just not in test mode, which is broken, apparently)

env GPU_FORCE_64BIT_PTR=1 ./ethminer -G -v 9 -Z -F 127.0.0.1:8545
env GPU_FORCE_64BIT_PTR=1 ./ethminer -G -v 9 -F james-thinkcentre-m81:8545 ℹ 20:21:20|ethminer Found suitable OpenCL device [ Pitcairn ] with 1921572864 bytes of GPU memory cl 20:21:20|cl-0 No work. Pause for 3 s. m 20:21:20|ethminer Waiting for work package... m 20:21:20|ethminer Got work package: #9dca70b2 m 20:21:20|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:21|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:21|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:22|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:22|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:23|cl-0 New work: header #9dca70b2… target 0000000040080100200400801002004008010020040080100200400801002004 cl 20:21:23|cl-0 New seed #00000000… m 20:21:23|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:23|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:24|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:24|cl-0 Platform: AMD Accelerated Parallel Processing cl 20:21:24|cl-0 Device: Pitcairn / OpenCL 1.2 AMD-APP (2482.3) m 20:21:24|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:24|cl-0 Build info: cl 20:21:24|cl-0 Creating light cache buffer, size 16776896 cl 20:21:24|cl-0 Creating DAG buffer, size 1073739904 cl 20:21:24|cl-0 Loading kernels cl 20:21:24|cl-0 Writing light cache buffer cl 20:21:24|cl-0 Creating buffer for header. cl 20:21:24|cl-0 Creating mining buffer cl 20:21:24|cl-0 Generating DAG cl 20:21:25|cl-0 DAG 0 % m 20:21:25|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:25|cl-0 DAG 6 % cl 20:21:25|cl-0 DAG 12 % cl 20:21:25|cl-0 DAG 18 % m 20:21:25|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:26|cl-0 DAG 25 % cl 20:21:26|cl-0 DAG 31 % m 20:21:26|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:26|cl-0 DAG 37 % cl 20:21:26|cl-0 DAG 43 % m 20:21:26|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:26|cl-0 DAG 50 % cl 20:21:27|cl-0 DAG 56 % m 20:21:27|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:27|cl-0 DAG 62 % cl 20:21:27|cl-0 DAG 68 % cl 20:21:27|cl-0 DAG 75 % m 20:21:27|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:28|cl-0 DAG 81 % cl 20:21:28|cl-0 DAG 87 % m 20:21:28|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 cl 20:21:28|cl-0 DAG 93 % cl 20:21:28|cl-0 Switch time 8212 ms / 5287913 us m 20:21:28|ethminer Speed 0.00 Mh/s gpu/0 0.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:29|ethminer Speed 12.60 Mh/s gpu/0 12.60 [A0+0:R0+0:F0] Time: 00:00 m 20:21:29|ethminer Speed 12.60 Mh/s gpu/0 12.60 [A0+0:R0+0:F0] Time: 00:00 m 20:21:30|ethminer Speed 14.69 Mh/s gpu/0 14.69 [A0+0:R0+0:F0] Time: 00:00 m 20:21:30|ethminer Speed 14.69 Mh/s gpu/0 14.69 [A0+0:R0+0:F0] Time: 00:00 m 20:21:31|ethminer Speed 15.74 Mh/s gpu/0 15.74 [A0+0:R0+0:F0] Time: 00:00 m 20:21:31|ethminer Speed 15.74 Mh/s gpu/0 15.74 [A0+0:R0+0:F0] Time: 00:00 m 20:21:32|ethminer Speed 16.00 Mh/s gpu/0 16.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:32|ethminer Speed 16.00 Mh/s gpu/0 16.00 [A0+0:R0+0:F0] Time: 00:00 m 20:21:33|ethminer Speed 16.16 Mh/s gpu/0 16.16 [A0+0:R0+0:F0] Time: 00:00 m 20:21:33|ethminer Speed 16.16 Mh/s gpu/0 16.16 [A0+0:R0+0:F0] Time: 00:00 m 20:21:34|ethminer Speed 16.44 Mh/s gpu/0 16.44 [A0+0:R0+0:F0] Time: 00:00 m 20:21:34|ethminer Speed 16.44 Mh/s gpu/0 16.44 [A0+0:R0+0:F0] Time: 00:00 m 20:21:35|ethminer Speed 16.48 Mh/s gpu/0 16.48 [A0+0:R0+0:F0] Time: 00:00 m 20:21:35|ethminer Speed 16.48 Mh/s gpu/0 16.48 [A0+0:R0+0:F0] Time: 00:00 m 20:21:36|ethminer Speed 16.52 Mh/s gpu/0 16.52 [A0+0:R0+0:F0] Time: 00:00 m 20:21:37|ethminer Speed 16.52 Mh/s gpu/0 16.52 [A0+0:R0+0:F0] Time: 00:00 m 20:21:37|ethminer Speed 16.55 Mh/s gpu/0 16.55 [A0+0:R0+0:F0] Time: 00:00 m 20:21:38|ethminer Speed 16.55 Mh/s gpu/0 16.55 [A0+0:R0+0:F0] Time: 00:00 m 20:21:38|ethminer Speed 16.68 Mh/s gpu/0 16.68 [A0+0:R0+0:F0] Time: 00:00 m 20:21:39|ethminer Speed 16.68 Mh/s gpu/0 16.68 [A0+0:R0+0:F0] Time: 00:00 m 20:21:39|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:40|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:40|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:41|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:41|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:42|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:42|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00 m 20:21:43|ethminer Speed 17.10 Mh/s gpu/0 17.10 [A0+0:R0+0:F0] Time: 00:00

(Leaving off env GPU_FORCE_64BIT_PTR=1 causes it to "work" but continually hash at 0.00Mh/s)

Same here. GPU_FORCE_64BIT_PTR did not solve anything on my old HD7770. Tried with the latest padoka ppa (unstable) + ubuntu 17.10 + radeon disabled in kernel + amdgpu enabled. No changes.
I also tried with all the other workarounds listed here. None helped. This is mostly a problem with the drivers implementation, since they are still on development and clover clearly states that ethminer is requesting a version that it's not officially supported.

About the official drivers:
Tried AMDGPU-PRO + ubuntu 16.04. Only half of my card memory is reported for OpenCL (even when I include all the env variables listed above to change the memory to 100%), so ethminer won't start. (the memory report changes constantly, so I guess it's a driver bug on AMDGPU-PRO 17.50).

Does anyone have any other idea?

got the same problem on my RX 580 + HD 7950, 580 works fine while 7950 don't
solved by setting
env GPU_FORCE_64BIT_PTR=1

@EoD
I got the same error, I also even downgrade to the version you said but I got the following error:

~/cpuminer$ ethminer -M -G
  ℹ  10:16:52|ethminer  Found suitable OpenCL device [ GeForce 610M ] with 2081751040  bytes of GPU memory
Benchmarking on platform: CL
Preparing DAG for block #0
Warming up...
 cl  10:16:52|cl-0      Set work. Header #50c856ae… target 000000000000
 cl  10:16:52|cl-0      Initialising miner with seed #00000000…
 cl  10:16:56|cl-0      Platform: NVIDIA CUDA
 cl  10:16:56|cl-0      Device:   GeForce 610M  / OpenCL 1.1 CUDA
 cl  10:16:56|cl-0      OpenCL 1.1  not supported - minimum required version is 1.2
  ✘  10:16:56|cl-0      OpenCL Error: clEnqueueWriteBuffer -36
Trial 1... 0
Trial 2... 0
Trial 3... 0
Trial 4... 0
Trial 5... 0

And this is my clinfo output:

~/cpuminer$ clinfo
Number of platforms                               1
  Platform Name                                   NVIDIA CUDA
  Platform Vendor                                 NVIDIA Corporation
  Platform Version                                OpenCL 1.2 CUDA 9.0.282
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_nv_create_buffer
  Platform Extensions function suffix             NV

  Platform Name                                   NVIDIA CUDA
Number of devices                                 1
  Device Name                                     GeForce 610M
  Device Vendor                                   NVIDIA Corporation
  Device Vendor ID                                0x10de
  Device Version                                  OpenCL 1.1 CUDA
  Driver Version                                  384.111
  Device OpenCL C Version                         OpenCL C 1.1 
  Device Type                                     GPU
  Device Profile                                  FULL_PROFILE
  Device Topology (NV)                            PCI-E, 01:00.0
  Max compute units                               1
  Max clock frequency                             950MHz
  Compute Capability (NV)                         2.1
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x64
  Max work group size                             1024
  Preferred work group size multiple              32
  Warp size (NV)                                  32
  Preferred / native vector sizes                 
    char                                                 1 / 1       
    short                                                1 / 1       
    int                                                  1 / 1       
    long                                                 1 / 1       
    half                                                 0 / 0        (n/a)
    float                                                1 / 1       
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (n/a)
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  No
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  No
  Address bits                                    64, Little-Endian
  Global memory size                              2081751040 (1.939GiB)
  Error Correction support                        No
  Max memory allocation                           520437760 (496.3MiB)
  Unified memory for Host and Device              No
  Integrated memory (NV)                          No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       4096 bits (512 bytes)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        16384
  Global Memory cache line                        128 bytes
  Image support                                   Yes
    Max number of samplers per kernel             16
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             2048x2048x2048 pixels
    Max number of read image args                 128
    Max number of write image args                8
  Local memory type                               Local
  Local memory size                               49152 (48KiB)
  Registers per block (NV)                        32768
  Max constant buffer size                        65536 (64KiB)
  Max number of constant args                     9
  Max size of kernel argument                     4352 (4.25KiB)
  Queue properties                                
    Out-of-order execution                        Yes
    Profiling                                     Yes
  Profiling timer resolution                      1000ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Kernel execution timeout (NV)                 Yes
  Concurrent copy and kernel execution (NV)       Yes
    Number of async copy engines                  1
  Device Available                                Yes
  Compiler Available                              Yes
  Device Extensions                               cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_nv_create_buffer

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  NVIDIA CUDA
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   Success [NV]
  clCreateContext(NULL, ...) [default]            Success [NV]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  No platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  No platform

ICD loader properties
  ICD loader Name                                 OpenCL ICD Loader
  ICD loader Vendor                               OCL Icd free software
  ICD loader Version                              2.2.11
  ICD loader Profile                              OpenCL 2.1

@Alavi1412 Can you try 0.13.0rc4? There is also a new option for --cl-kernel, it might be worth playing with it as well.

@EoD
still the error exist:

ethminer -M -G 
  ℹ  03:14:58|ethminer  Found suitable OpenCL device [ GeForce 610M ] with 2081751040  bytes of GPU memory
Benchmarking on platform: CL
Preparing DAG for block #0
 cl  03:14:58|cl-0      No work. Pause for 3 s.
Warming up...
 cl  03:15:01|cl-0      New work: header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000
 cl  03:15:01|cl-0      New seed #00000000…
 cl  03:15:04|cl-0      Platform: NVIDIA CUDA
 cl  03:15:04|cl-0      Device:   GeForce 610M  / OpenCL 1.1 CUDA
 cl  03:15:04|cl-0      OpenCL 1.1  not supported - minimum required version is 1.2
  ✘  03:15:04|cl-0      OpenCL Error: clEnqueueWriteBuffer: CL_INVALID_COMMAND_QUEUE (-36)

I'm seeing the same CL_INVALID_ARG_INDEX (-49) error on the master tip, also tried v0.13.0rc6. I've tried all the environmental vars. This is an R9 390 using the 17.04 Ubuntu drivers from AMD. Running Ubuntu 16.04.3 LTS.

all of the output is here:
https://gist.github.com/edhemphill/1ac8e2fc4662493c60939befc3a256cd

I'm a systems developer and am happy to help out, if someone can point me in the right direction.

What I found weird was the clinfo reports "Platform Version" as OpenCL 2.0 but Driver Version and C libs as 1.2. What's up with that?

Update: at this version:
$ git status HEAD detached at v0.12.0.dev1
(as suggested above) no errors.

Affects me as well, with amdgpu-pro 17.40. Works with GPU_FORCE_64BIT_PTR=1, but fails on benchmark

I'm getting the same issue with a Vega 64 on the open-source ROCm stack. Ethminer built from source.

GPU_FORCE_64BIT_PTR=1 has no effect.

Output:

$ ethminer -G -M -v 9
  ℹ  15:41:11|ethminer  Found suitable OpenCL device [ gfx900 ] with 8573157376  bytes of GPU memory
Benchmarking on platform: CL
Preparing DAG for block #0
 cl  15:41:11|cl-0      No work. Pause for 3 s.
Warming up...
 cl  15:41:14|cl-0      New work: header #50c856ae… target 0000000000000002000000000000000000000000000000000000000000000000
 cl  15:41:14|cl-0      New seed #00000000…
 cl  15:41:15|cl-0      Platform: AMD Accelerated Parallel Processing
 cl  15:41:15|cl-0      Device:   gfx900  / OpenCL 1.2 
 cl  15:41:15|cl-0      OpenCL kernel: Stable kernel
 cl  15:41:15|cl-0      Build info: 
 cl  15:41:15|cl-0      Creating light cache buffer, size 16776896
 cl  15:41:15|cl-0      Creating DAG buffer, size 1073739904
 cl  15:41:15|cl-0      Loading kernels
 cl  15:41:15|cl-0      Writing light cache buffer
 cl  15:41:15|cl-0      Creating buffer for header.
 cl  15:41:15|cl-0      Creating mining buffer
 cl  15:41:15|cl-0      Generating DAG
 cl  15:41:15|cl-0      DAG 0 %
 cl  15:41:15|cl-0      DAG 6 %
 cl  15:41:15|cl-0      DAG 12 %
 cl  15:41:15|cl-0      DAG 18 %
 cl  15:41:16|cl-0      DAG 25 %
 cl  15:41:16|cl-0      DAG 31 %
 cl  15:41:16|cl-0      DAG 37 %
 cl  15:41:16|cl-0      DAG 43 %
 cl  15:41:16|cl-0      DAG 50 %
 cl  15:41:16|cl-0      DAG 56 %
 cl  15:41:16|cl-0      DAG 62 %
 cl  15:41:16|cl-0      DAG 68 %
 cl  15:41:17|cl-0      DAG 75 %
 cl  15:41:17|cl-0      DAG 81 %
 cl  15:41:17|cl-0      DAG 87 %
 cl  15:41:17|cl-0      DAG 93 %
 cl  15:41:17|cl-0      Switch time 6105 ms / 3105361 us
Trial 1... 36407431
Trial 2... 36407431
Trial 3... 36407431
Trial 4... 36298879
Trial 5... 36295247
  ✘  15:41:41|cl-0      OpenCL Error: clSetKernelArg: CL_INVALID_ARG_INDEX (-49)
min/mean/max: 36295247/36363283/36407431 H/s
inner mean: 24235436 H/s

Versions:

```$ ethminer --version
ethminer version 0.13.0.dev0
Build: Linux/g++/Release


$ uname -a
Linux shadow 4.13.0-25-generic #29~16.04.2-Ubuntu SMP Tue Jan 9 12:16:39 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux


$ apt-cache madison rocm-opencl
rocm-opencl | 1.2.0-2017121952 | http://repo.radeon.com/rocm/apt/debian xenial/main amd64 Packages

$ apt-cache madison rock-dkms
rock-dkms | 1.7.60-ubuntu | http://repo.radeon.com/rocm/apt/debian xenial/main amd64 Package

clinfo:

Number of platforms 1
Platform Name AMD Accelerated Parallel Processing
Platform Vendor Advanced Micro Devices, Inc.
Platform Version OpenCL 2.1 AMD-APP.internal (2545.0)
Platform Profile FULL_PROFILE
Platform Extensions cl_khr_icd cl_amd_object_metadata cl_amd_event_callback
Platform Host timer resolution 1ns
Platform Extensions function suffix AMD

Platform Name AMD Accelerated Parallel Processing
Number of devices 1
Device Name gfx900
Device Vendor Advanced Micro Devices, Inc.
Device Vendor ID 0x1002
Device Version OpenCL 1.2
Driver Version 2545.0 (HSA1.1,LC)
Device OpenCL C Version OpenCL C 2.0
Device Type GPU
Device Profile FULL_PROFILE
Device Board Name (AMD) Device 687f
Device Topology (AMD) PCI-E, 03:00.0
Max compute units 64
SIMD per compute unit (AMD) 4
SIMD width (AMD) 16
SIMD instruction width (AMD) 1
Max clock frequency 1630MHz
Graphics IP (AMD) 9.0
Device Partition (core)
Max number of sub-devices 64
Supported partition types none specified
Max work item dimensions 3
Max work item sizes 1024x1024x1024
Max work group size 256
Preferred work group size multiple 64
Wavefront width (AMD) 64
Preferred / native vector sizes
char 4 / 4
short 2 / 2
int 1 / 1
long 1 / 1
half 1 / 1 (cl_khr_fp16)
float 1 / 1
double 1 / 1 (cl_khr_fp64)
Half-precision Floating-point support (cl_khr_fp16)
Denormals No
Infinity and NANs No
Round to nearest No
Round to zero No
Round to infinity No
IEEE754-2008 fused multiply-add No
Support is emulated in software No
Correctly-rounded divide and sqrt operations No
Single-precision Floating-point support (core)
Denormals Yes
Infinity and NANs Yes
Round to nearest Yes
Round to zero Yes
Round to infinity Yes
IEEE754-2008 fused multiply-add Yes
Support is emulated in software No
Correctly-rounded divide and sqrt operations Yes
Double-precision Floating-point support (cl_khr_fp64)
Denormals Yes
Infinity and NANs Yes
Round to nearest Yes
Round to zero Yes
Round to infinity Yes
IEEE754-2008 fused multiply-add Yes
Support is emulated in software No
Correctly-rounded divide and sqrt operations No
Address bits 64, Little-Endian
Global memory size 8573157376 (7.984GiB)
Global free memory (AMD) 8370176 (7.982GiB)
Global memory channels (AMD) 64
Global memory banks per channel (AMD) 4
Global memory bank width (AMD) 256 bytes
Error Correction support No
Max memory allocation 7287183769 (6.787GiB)
Unified memory for Host and Device No
Minimum alignment for any data type 128 bytes
Alignment of base address 1024 bits (128 bytes)
Global Memory cache type Read/Write
Global Memory cache size 16384
Global Memory cache line 64 bytes
Image support Yes
Max number of samplers per kernel 26751
Max size for 1D images from buffer 65536 pixels
Max 1D or 2D image array size 2048 images
Max 2D image size 16384x16384 pixels
Max 3D image size 2048x2048x2048 pixels
Max number of read image args 128
Max number of write image args 8
Local memory type Local
Local memory size 65536 (64KiB)
Local memory syze per CU (AMD) 65536 (64KiB)
Local memory banks (AMD) 32
Max constant buffer size 7287183769 (6.787GiB)
Max number of constant args 8
Max size of kernel argument 1024
Queue properties
Out-of-order execution No
Profiling Yes
Prefer user sync for interop Yes
Profiling timer resolution 1ns
Profiling timer offset since Epoch (AMD) 0ns (Thu Jan 1 01:00:00 1970)
Execution capabilities
Run OpenCL kernels Yes
Run native kernels No
Thread trace supported (AMD) No
printf() buffer size 4194304 (4MiB)
Built-in kernels
Device Available Yes
Compiler Available Yes
Linker Available Yes
Device Extensions cl_khr_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_fp16 cl_khr_gl_sharing cl_amd_device_attribute_query cl_amd_media_ops cl_amd_media_ops2 cl_khr_subgroups cl_khr_depth_images cl_amd_copy_buffer_p2p

NULL platform behavior
clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...) AMD Accelerated Parallel Processing
clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...) Success [AMD]
clCreateContext(NULL, ...) [default] Success [AMD]
clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU) No devices found in platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU) Success (1)
Platform Name AMD Accelerated Parallel Processing
Device Name gfx900
clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR) No devices found in platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM) No devices found in platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL) Success (1)
Platform Name AMD Accelerated Parallel Processing
Device Name gfx900

ICD loader properties
ICD loader Name OpenCL ICD Loader
ICD loader Vendor OCL Icd free software
ICD loader Version 2.2.8
ICD loader Profile OpenCL 1.2
NOTE: your OpenCL library declares to support OpenCL 1.2,
but it seems to support up to OpenCL 2.1 too.
```

@anoother benchmark doesn't work in both cases. Try mining with a real pool

@Kukunin Aha, mining fine without any configuration :)

@anoother What did you DO though to fix the error in your previous comment?

@JamesTheAwesomeDude Didn't have to do anything. The benchmark is still broken.

I hadn't previously tested mining, thinking that the benchmark failure was indicative that it wouldn't work. But it works just fine.

I do have 9 AMD cards (it's a mix of RX 560 and RX 580) installed 5 of them is working fine after adding GPU_FORCE_64BIT_PTR=1 .
The remaining 3 don't mine.
I am on arch linux with linux 4.15 thus amdgpu not amdgpupro driver and opencl-amd 17.50.511655-2.
The first 5 cards have generated the DAG in approx 8 seconds. But the remaining ones did not. I have noticed no errors. Have you got some hints for me?

@pvagner you might want to open a separate bug report, as it does not sound related. If you have read and think this is the same issue, feel free to contribute more information here.

Try with latest Ethminer version and feedback please.
Thank you!

GCN1.0 and earlier do not like the new drivers, use 13.12 (best) or 14.xx at newest or they don't work correctly. There is no workaround, driver is bug city.

I run Ubuntu 14, downgraded kernel 3.2, and fglrx 13 and everything OpenCL works flawlessly at twice the speeds of any newer driver. May as well have made them deprecated after catalyst 13 as they don't work. This also means you probably can't run RX on the same rig as old ass cards, due to drivers. Same sort of deal as how you can't run CUDA 2.x platform (GTX5xx or such) in same rig as anything newer (CUDA throws dumb buggy unavailability errors)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Penziplays picture Penziplays  Â·  5Comments

rawsh picture rawsh  Â·  5Comments

gennadiv picture gennadiv  Â·  5Comments

unknown2this picture unknown2this  Â·  4Comments

sur1v picture sur1v  Â·  4Comments