ethereum-mining / ethminer

Ethereum miner with OpenCL, CUDA and stratum support
GNU General Public License v3.0
5.98k stars 2.28k forks source link

Segfault on OpenCL under Ubuntu 18.04 #1904

Open shadeofblue opened 5 years ago

shadeofblue commented 5 years ago

Describe the bug when trying to run ethminer 0.18.0-rc.0 on Ubuntu 18.04 LTE using OpenCL, I'm getting a segfault

To Reproduce

ethminer -G -M 7900888

Expected behavior Normal execution of the benchmark

Actual behavior


ethminer 0.18.0-rc.0
Build: linux/release/gnu

 i 20:48:36 ethminer Selected pool localhost:0
 i 20:48:36 ethminer Established connection to localhost:0
 i 20:48:36 ethminer Spinning up miners...
cl 20:48:36 cl-0     OpenCL OpenCL 1.1 Mesa 18.2.8 not supported, but platform Clover might work nevertheless. USE AT OWN RISK!
cl 20:48:36 cl-0     Using PciId :  AMD Radeon (TM) R9 380 Series (TONGA, DRM 3.25.0, 4.15.0-50-generic, LLVM 7.0.0) OpenCL 1.1 Mesa 18.2.8 Memory : 7.74 GB
cl 20:48:36 cl-1     Using PciId : 01:00.0 Tonga OpenCL 1.2 AMD-APP (2639.3) Memory : 3.69 GB
 i 20:48:36 cl-1     Adjusting CL work multiplier for 28 CUs. Adjusted work multiplier: 50�973
cl 20:48:36 cl-2     Using PciId : 04:00.0 Tonga OpenCL 1.2 AMD-APP (2639.3) Memory : 3.96 GB
 i 20:48:36 cl-2     Adjusting CL work multiplier for 28 CUs. Adjusted work multiplier: 50�973
 i 20:48:36 sim      Epoch : 263 Difficulty : 4.29 Gh
 i 20:48:36 sim      Job: 7e7340f7… block 7900888 localhost:0
cl 20:48:38 cl-0     Generating DAG + Light : 3.10 GB
cl 20:48:38 cl-1     Generating DAG + Light : 3.10 GB
cl 20:48:38 cl-2     Generating DAG + Light : 3.10 GB
cl 20:48:38 cl-0     OpenCL kernel
cl 20:48:38 cl-2     OpenCL kernel
cl 20:48:39 cl-1     OpenCL kernel
 X 20:48:39 cl-0     OpenCL kernel build log:
input.cl:321:9: warning: implicit declaration of function 'amd_bitalign' is invalid in OpenCL
input.cl:180:9: note: expanded from macro 'KECCAK_PROCESS'
input.cl:99:60: note: expanded from macro 'KECCAKF_1600_RND'
input.cl:87:24: note: expanded from macro 'ROTL64_1'
input.cl:433:5: warning: implicit declaration of function 'amd_bitalign' is invalid in OpenCL
input.cl:180:9: note: expanded from macro 'KECCAK_PROCESS'
input.cl:99:60: note: expanded from macro 'KECCAKF_1600_RND'
input.cl:87:24: note: expanded from macro 'ROTL64_1'
<unknown>:0:0: in function search void (%struct.SearchResults addrspace(1)*, <2 x i32> addrspace(4)*, <8 x i64> addrspace(1)*, i32, i64, i64): unsupported indirect call to function amd_bitalign

 X 20:48:39 cl-0     OpenCL kernel build error (-11):
clBuildProgram
SIGSEGV encountered ...
stack trace:
backtrace() returned 7 addresses
ethminer() [0x422af9]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f972087ef20]
ethminer() [0x6e0a61]
ethminer() [0x4bae96]
ethminer() [0x773aaf]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x76db) [0x7f97211f76db]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7f972096188f]
pure virtual method called
terminate called without an active exception

Environment (please complete the following information):

jgredt commented 5 years ago

Hello !

I don't have this problem, have you installed all the drivers corresponding to your machine ?

shadeofblue commented 5 years ago

@jgredt well, yeah, I'm running the AMD GPU Pro drivers ...

and I'm able to run ethminer 0.17.1 successfully on the same machine...

ddobreff commented 5 years ago

The output suggests that you are using clover opencl, not amdgpu one, please review your amdgpu-pro installation along with mesa-opencl one.

veox commented 5 years ago

I'm having this problem also; in v0.17.x, I used to be able to specify --opencl-platform 1, but now this option is gone. :/


To clarify, I don't have the -pro component of the drivers, and never had them. From my point of view, this is a regression.

davidebeatrici commented 3 years ago

Exact same behavior on Debian Buster.

hmpargi commented 3 years ago

I am getting same error

./ethminer() [0x49a016] ./ethminer() [0x48d03e] ./ethminer() [0x48eda9] ./ethminer() [0x48eff7] ./ethminer() [0x492071] ./ethminer() [0x4922cd] ./ethminer() [0x42a2d0] ./ethminer() [0x773aaf] /lib/x86_64-linux-gnu/libpthread.so.0(+0x76db) [0x7f63b7a696db] /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7f63b71dca3f]

I am runing latest eithminer stable version

ethminer 0.18.0