Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit eceff6c

Browse files
Misieq01Rumble Fishstringhandlerleet4taribrianp
authored
feat: allow engine selection (#35)
## Branch created from #31 ### [ Summary ] - Added `multi_engine_wrapper` for managing used engine depending on user selection - Changed `gpu_status` file logic => Now we are creating one file per engine ( for example CUDA_gpu_status.json ) - Changed gpu_status file structure - We are now storing is_excluded flag inside gpu_status file and allow frontend to update it for easier tracking of which device should be disable --------- Signed-off-by: Rumble Fish <rumblefish@192.168.1.24> Signed-off-by: Misieq01 <bartosz2000walczak@gmail.com> Co-authored-by: Rumble Fish <rumblefish@192.168.1.24> Co-authored-by: stringhandler <stringhandler@protonmail.com> Co-authored-by: C.Lee Taylor <47312074+leet4tari@users.noreply.github.com> Co-authored-by: Brian Pearce <brianp@users.noreply.github.com> Co-authored-by: stringhandler <stringhandler@gmail.com>
1 parent 1b9738c commit eceff6c

17 files changed

+1452
-507
lines changed

.github/workflows/build_binaries.json

Lines changed: 63 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@
1313
"rust": "nightly-2024-07-07",
1414
"target": "x86_64-unknown-linux-gnu",
1515
"cross": false,
16-
"features": "opencl3"
16+
"features": "opencl"
1717
},
1818
{
1919
"name": "opencl-linux-arm64",
2020
"runs-on": "ubuntu-latest",
2121
"rust": "nightly-2024-07-07",
2222
"target": "aarch64-unknown-linux-gnu",
2323
"cross": true,
24-
"features": "opencl3",
24+
"features": "opencl",
2525
"build_enabled": true,
2626
"best_effort": true
2727
},
@@ -31,7 +31,25 @@
3131
"rust": "nightly-2024-07-07",
3232
"target": "riscv64gc-unknown-linux-gnu",
3333
"cross": true,
34-
"features": "opencl3",
34+
"features": "opencl",
35+
"build_enabled": true,
36+
"best_effort": true
37+
},
38+
{
39+
"name": "combined-linux-x86_64",
40+
"runs-on": "ubuntu-20.04",
41+
"rust": "nightly-2024-07-07",
42+
"target": "x86_64-unknown-linux-gnu",
43+
"cross": false,
44+
"features": "nvidia,opencl"
45+
},
46+
{
47+
"name": "combined-linux-arm64",
48+
"runs-on": "ubuntu-latest",
49+
"rust": "nightly-2024-07-07",
50+
"target": "aarch64-unknown-linux-gnu",
51+
"cross": true,
52+
"features": "nvidia,opencl",
3553
"build_enabled": true,
3654
"best_effort": true
3755
},
@@ -41,15 +59,31 @@
4159
"rust": "stable",
4260
"target": "x86_64-apple-darwin",
4361
"cross": false,
44-
"features": "opencl3"
62+
"features": "opencl"
63+
},
64+
{
65+
"name": "metal-macos-arm64",
66+
"runs-on": "macos-14",
67+
"rust": "stable",
68+
"target": "aarch64-apple-darwin",
69+
"cross": false,
70+
"features": "metal"
71+
},
72+
{
73+
"name": "combined-macos-x86_64",
74+
"runs-on": "macos-13",
75+
"rust": "stable",
76+
"target": "x86_64-apple-darwin",
77+
"cross": false,
78+
"features": "metal,opencl"
4579
},
4680
{
47-
"name": "opencl-macos-arm64",
81+
"name": "combined-macos-arm64",
4882
"runs-on": "macos-14",
4983
"rust": "stable",
5084
"target": "aarch64-apple-darwin",
5185
"cross": false,
52-
"features": "opencl3"
86+
"features": "metal,opencl"
5387
},
5488
{
5589
"name": "cuda-windows-x64",
@@ -66,7 +100,7 @@
66100
"target": "x86_64-pc-windows-msvc",
67101
"rustflags": "-L C:/vcpkg/packages/opencl_x64-windows/lib",
68102
"cross": false,
69-
"features": "opencl3"
103+
"features": "opencl"
70104
},
71105
{
72106
"name": "cuda-windows-arm64",
@@ -85,8 +119,28 @@
85119
"target": "aarch64-pc-windows-msvc",
86120
"rustflags": "-L C:/vcpkg/packages/opencl_x64-windows/lib",
87121
"cross": false,
88-
"features": "opencl3",
122+
"features": "opencl",
123+
"build_enabled": true,
124+
"best_effort": true
125+
},
126+
{
127+
"name": "combined-windows-x64",
128+
"runs-on": "windows-2019",
129+
"rust": "stable",
130+
"target": "x86_64-pc-windows-msvc",
131+
"rustflags": "-L C:/vcpkg/packages/opencl_x64-windows/lib",
132+
"cross": false,
133+
"features": "opencl,nvidia"
134+
},
135+
{
136+
"name": "combined-windows-arm64",
137+
"runs-on": "windows-latest",
138+
"rust": "stable",
139+
"target": "aarch64-pc-windows-msvc",
140+
"rustflags": "-L C:/vcpkg/packages/opencl_x64-windows/lib",
141+
"cross": false,
142+
"features": "opencl,nvidia",
89143
"build_enabled": true,
90144
"best_effort": true
91145
}
92-
]
146+
]

.github/workflows/build_binaries.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ jobs:
156156

157157
- name: Install nVida cuda toolkit
158158
uses: jimver/cuda-toolkit@v0.2.16
159-
if: ${{ matrix.builds.features == 'nvidia' }}
159+
if: contains(matrix.builds.features, 'nvidia')
160160
with:
161161
method: network
162162
sub-packages: '["nvcc", "cudart"]'
@@ -170,7 +170,7 @@ jobs:
170170
protobuf-compiler
171171
172172
- name: Install Linux dependencies - Ubuntu / OpenCL
173-
if: ${{ startsWith(runner.os,'Linux') && ( ! matrix.builds.cross ) && ( matrix.builds.features == 'opencl3' ) }}
173+
if: ${{ startsWith(runner.os,'Linux') && ( ! matrix.builds.cross ) && contains(matrix.builds.features, 'opencl') }}
174174
run: |
175175
sudo apt-get update
176176
sudo apt-get install --no-install-recommends --assume-yes \

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
/target
22
config.json
33
data
4+
xtrgpuminer/log/xtrgpuminer.log
5+
CUDA_gpu_status.json
6+
OpenCL_gpu_status.json
7+
Metal_gpu_status.json
8+
panic.log
49

510
# Ignore OS files
611
.DS_Store

0 commit comments

Comments
 (0)