Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CUDA for MacOS #100

Merged
merged 9 commits into from
Aug 31, 2021
Merged

CUDA for MacOS #100

merged 9 commits into from
Aug 31, 2021

Conversation

Miner29974
Copy link

Hi

do it exist a plug-in for macOS?
If not is there a développer who can try do do it?

thank you

@Spudz76
Copy link
Contributor

Spudz76 commented May 10, 2021

Nvidia dropped MacOS support after CUDA Toolkit 10.2. (11.x has no MacOS support)

CUDA Toolkit 10.2 allegedly works on 10.13 High Sierra. Unknown if it works on anything newer. Unknown how to use it in a build if it's any different than Linux.

None of the devs here have Apple anything therefore the lack of much support other than guesses. But usually Apple does something that breaks things anyway, like deprecating OpenCL and not really wanting CUDA to work either (both in preference of everyone switching to Metal, which nobody has so far).

@Miner29974
Copy link
Author

Miner29974 commented May 10, 2021 via email

@Spudz76
Copy link
Contributor

Spudz76 commented May 14, 2021

I have successfully compiled for MacOS High Sierra 10.13 with CUDA Toolkit 10.2 (the last version of OSX, and the last version of CUDA to support any MacOS). It did not work out-of-the-box and took some changes, I will clean these up and submit as PR, even though it doesn't matter anymore, but in case someone wants to run old software to make it work. Perhaps the CUDA Toolkit 10.2 can be installed on newer OS but nVidia claims 10.13 is the only supported one. Probably the driver is broken in newer versions so having a plugin that can't talk to a GPU anyway would be a pointless success.

[100%] Linking CXX shared library libxmrig-cuda.dylib
[100%] Built target xmrig-cuda

@Miner29974
Copy link
Author

Miner29974 commented May 14, 2021 via email

@Spudz76
Copy link
Contributor

Spudz76 commented May 14, 2021

Minimum supported CUDA is 8.0 for any platform, and minimum GPU "capability level" (arch) of 2.0 (Fermi)

It should work with Sierra (10.12) with CUDA Toolkit 9.0 for sure since it says it supports 10.12 directly. Perhaps newer Toolkits still work but they all say 10.13.

Unless you mean arch 6.x such as Pascal based 60 or 61 (GTX1060 or such) then yes, CUDA 9.0 supports those.

@Spudz76
Copy link
Contributor

Spudz76 commented May 14, 2021

Working build fixes in #104

If you could test a build and then a run. You may have to set the cuda->loader path in config.json to where the libxmrig-cuda.dylib is located. null was trying to load OpenCL for some reason in my limited testing (with no GPU).

It should at least locate the GPU and possibly will even work.

EDIT: has been merged into dev branch

Fix build on MacOS 10.13 (last supported OSX for CUDA)
@Spudz76
Copy link
Contributor

Spudz76 commented May 14, 2021

Repaired the loader: null problem in main xmrig, pending PR. Then copying the libxmrig-cuda.dylib along side xmrig executable and null setting as default will work, same as other platforms.

EDIT: has been merged into main xmrig dev branch

@Spudz76
Copy link
Contributor

Spudz76 commented May 14, 2021

I see you are actually meaning to use 320M which is too old for mining. :(

@Miner29974
Copy link
Author

Miner29974 commented May 15, 2021 via email

@xmrig xmrig merged commit 8ee909d into master Aug 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants