CryptoGraphics / VerthashMiner

GPU miner for the Verthash algorithm
GNU General Public License v3.0
76 stars 38 forks source link

Miner not detecting my GPU #50

Open karnetmp opened 3 years ago

karnetmp commented 3 years ago

I'm trying to mine on Ubuntu 20.04.2 with my RX 570. I have amdgpu-pro installed, OpenCL is working fine. VerthashMiner still doesn't detect my GPU.

$ clinfo
Number of platforms                               1
  Platform Name                                   Clover
  Platform Vendor                                 Mesa
  Platform Version                                OpenCL 1.1 Mesa 20.2.6
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             MESA

  Platform Name                                   Clover
Number of devices                                 1
  Device Name                                     Radeon RX 570 Series (POLARIS10, DRM 3.40.0, 5.4.0-54-generic, LLVM 11.0.0)
  Device Vendor                                   AMD
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 1.1 Mesa 20.2.6
  Driver Version                                  20.2.6
  Device OpenCL C Version                         OpenCL C 1.1 
  Device Type                                     GPU
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes
  Max compute units                               32
  Max clock frequency                             1284MHz
  Max work item dimensions                        3
  Max work item sizes                             256x256x256
  Max work group size                             256
  Preferred work group size multiple              64
  Preferred / native vector sizes                 
    char                                                16 / 16      
    short                                                8 / 8       
    int                                                  4 / 4       
    long                                                 2 / 2       
    half                                                 0 / 0        (n/a)
    float                                                4 / 4       
    double                                               2 / 2        (cl_khr_fp64)
  Half-precision Floating-point support           (n/a)
  Single-precision Floating-point support         (core)
    Denormals                                     No
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    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
  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
  Address bits                                    64, Little-Endian
  Global memory size                              16722415616 (15.57GiB)
  Error Correction support                        No
  Max memory allocation                           6871947673 (6.4GiB)
  Unified memory for Host and Device              No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       32768 bits (4096 bytes)
  Global Memory cache type                        None
  Image support                                   No
  Local memory type                               Local
  Local memory size                               32768 (32KiB)
  Max number of constant args                     16
  Max constant buffer size                        2147483392 (2GiB)
  Max size of kernel argument                     1024
  Queue properties                                
    Out-of-order execution                        No
    Profiling                                     Yes
  Profiling timer resolution                      0ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
  Device Extensions                               cl_khr_byte_addressable_store 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_fp64

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  Clover
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   Success [MESA]
  clCreateContext(NULL, ...) [default]            Success [MESA]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  Success (1)
    Platform Name                                 Clover
    Device Name                                   Radeon RX 570 Series (POLARIS10, DRM 3.40.0, 5.4.0-54-generic, LLVM 11.0.0)
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  Success (1)
    Platform Name                                 Clover
    Device Name                                   Radeon RX 570 Series (POLARIS10, DRM 3.40.0, 5.4.0-54-generic, LLVM 11.0.0)
  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                                 Clover
    Device Name                                   Radeon RX 570 Series (POLARIS10, DRM 3.40.0, 5.4.0-54-generic, LLVM 11.0.0)

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
$ glxinfo | grep "OpenGL version"
OpenGL version string: 4.6.14756 Compatibility Profile Context 20.50`
$ lspci -k | grep -EA3 'VGA|3D|Display' 
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X/590] (rev ef)
    Subsystem: Sapphire Technology Limited Radeon RX 570 Pulse 4GB
    Kernel driver in use: amdgpu
    Kernel modules: amdgpu
$ ./VerthashMiner --device-list
[2021-04-29 09:20:18] WARN  Platform doesn't meet version requirements (index: 0, Mesa)
[2021-04-29 09:20:18] WARN  OpenCL 1.2 or higher is required.
[2021-04-29 09:20:18] INFO  Found 0 OpenCL devices.
[2021-04-29 09:20:18] WARN  Failed to initialize CUDA. error code: 35
[2021-04-29 09:20:18] WARN  CUDA devices will be unavailable.

Device list:
==================
OpenCL devices: None

CUDA devices: None
CryptoGraphics commented 3 years ago

Hello. According to your logs, OpenCL ICD loader doesn't detect AMDGPU-Pro driver and uses Mesa Clover/Gallium compute, which reports OpenCL 1.1. VerthashMiner requires OpenCL 1.2+.

Mesa Clover has improved quite a lot recently. It doesn't report OCL 1.2 because printf and image support are missing. VerthashMiner doesn't use those, so you can force CL 1.2 using the following environment variables:

CLOVER_PLATFORM_VERSION_OVERRIDE=1.2 CLOVER_DEVICE_VERSION_OVERRIDE=1.2 CLOVER_DEVICE_CLC_VERSION_OVERRIDE=1.2 ./VerthashMiner "your parameters"