Giter Club home page Giter Club logo

Comments (6)

SChernykh avatar SChernykh commented on June 20, 2024

It might be something wrong with your dependencies. Try to build using advanced build instructions, it will create the same binary as in official releases.

from xmrig.

YannChemin avatar YannChemin commented on June 20, 2024

I removed the previously used xmrig git directory and used these steps:

  1. sudo apt-get install git build-essential cmake automake libtool autoconf
  2. git clone https://github.com/xmrig/xmrig.git
  3. mkdir xmrig/build && cd xmrig/scripts
  4. ./build_deps.sh && cd ../build
  5. cmake .. -DXMRIG_DEPS=scripts/deps
  6. make -j$(nproc)

The result is the same:

free(): invalid pointer
Aborted

from xmrig.

SChernykh avatar SChernykh commented on June 20, 2024

Is it the full output in the terminal? Nothing else? Also, can you run it under gdb and get a call stack?
Run gdb --args ./xmrig then in console type run and when it crashes type bt

from xmrig.

YannChemin avatar YannChemin commented on June 20, 2024
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffee9ff6c0 (LWP 6016)]
[New Thread 0x7fffee1fe6c0 (LWP 6017)]
free(): invalid pointer
[Thread 0x7fffee1fe6c0 (LWP 6017) exited]

Thread 1 "xmrig" received signal SIGABRT, Aborted.
__pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0)
    at ./nptl/pthread_kill.c:44
44	./nptl/pthread_kill.c: No such file or directory.
(gdb) bt
#0  __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0)
    at ./nptl/pthread_kill.c:44
#1  0x00007ffff7d611cf in __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  0x00007ffff7d13472 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3  0x00007ffff7cfd4b2 in __GI_abort () at ./stdlib/abort.c:79
#4  0x00007ffff7cfe1ed in __libc_message (fmt=fmt@entry=0x7ffff7e7078c "%s\n") at ../sysdeps/posix/libc_fatal.c:150
#5  0x00007ffff7d6aae5 in malloc_printerr (str=str@entry=0x7ffff7e6e22c "free(): invalid pointer")
    at ./malloc/malloc.c:5658
#6  0x00007ffff7d6c864 in _int_free (av=<optimized out>, p=<optimized out>, have_lock=have_lock@entry=0)
    at ./malloc/malloc.c:4432
#7  0x00007ffff7d6f1df in __GI___libc_free (mem=<optimized out>) at ./malloc/malloc.c:3367
#8  0x00007ffff7c06ea0 in ?? () from /opt/rocm-6.0.1/lib/libamdocl64.so
#9  0x00007ffff7c1035d in ?? () from /opt/rocm-6.0.1/lib/libamdocl64.so
#10 0x00007ffff7bce525 in ?? () from /opt/rocm-6.0.1/lib/libamdocl64.so
#11 0x00007ffff7bfe43e in ?? () from /opt/rocm-6.0.1/lib/libamdocl64.so
#12 0x00007ffff7ba91b5 in ?? () from /opt/rocm-6.0.1/lib/libamdocl64.so
#13 0x00007ffff7d642d7 in __pthread_once_slow (once_control=0x7ffff7cc96a0, init_routine=0x7fffeeadd8d0 <__once_proxy>)
    at ./nptl/pthread_once.c:116
#14 0x00007ffff7baa23f in clIcdGetPlatformIDsKHR () from /opt/rocm-6.0.1/lib/libamdocl64.so
#15 0x00007ffff7f9c565 in ?? () from /opt/rocm-6.0.1/lib/libOpenCL.so
#16 0x00007ffff7f9e937 in ?? () from /opt/rocm-6.0.1/lib/libOpenCL.so
#17 0x00007ffff7d642d7 in __pthread_once_slow (once_control=0x7ffff7fa2100, init_routine=0x7ffff7f9e7a0)
    at ./nptl/pthread_once.c:116
#18 0x00007ffff7f9cbc6 in clGetPlatformIDs () from /opt/rocm-6.0.1/lib/libOpenCL.so
#19 0x00005555557e8ea8 in xmrig::OclLib::getPlatformIDs() ()
#20 0x00005555557e994b in xmrig::OclPlatform::get() ()
#21 0x00005555557d2ac9 in xmrig::OclConfig::platform() const ()
#22 0x00005555557d4c06 in xmrig::OclConfig::generate() ()
#23 0x000055555580689c in xmrig::Config::read(xmrig::IJsonReader const&, char const*) ()
#24 0x0000555555717a98 in xmrig::Base::Base(xmrig::Process*) ()
#25 0x0000555555814489 in xmrig::Controller::Controller(xmrig::Process*) ()
#26 0x0000555555805bce in xmrig::App::App(xmrig::Process*) ()
#27 0x00005555556dcf31 in main ()

from xmrig.

YannChemin avatar YannChemin commented on June 20, 2024

After changing opencl to false in .xmrig.conf, then it worked

from xmrig.

SChernykh avatar SChernykh commented on June 20, 2024
#18 0x00007ffff7f9cbc6 in clGetPlatformIDs () from /opt/rocm-6.0.1/lib/libOpenCL.so
#19 0x00005555557e8ea8 in xmrig::OclLib::getPlatformIDs() ()

XMRig just calls clGetPlatformIDs here, and then it crashes deep inside libamdocl64.so which is not a part of XMRig. Maybe (maybe) your OpenCL headers are incompatible with .so libraries you have there, which is why you have issues when compiling XMRig locally.

from xmrig.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.