Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
2d1e3c32
Unverified
Commit
2d1e3c32
authored
Jul 09, 2024
by
Daniel Hiltgen
Committed by
GitHub
Jul 09, 2024
Browse files
Merge pull request #5503 from dhiltgen/dual_rocm
Workaround broken ROCm p2p copy
parents
4918fae5
0bacb300
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletion
+2
-1
llm/generate/gen_linux.sh
llm/generate/gen_linux.sh
+1
-1
llm/generate/gen_windows.ps1
llm/generate/gen_windows.ps1
+1
-0
No files found.
llm/generate/gen_linux.sh
View file @
2d1e3c32
...
@@ -254,7 +254,7 @@ if [ -z "${OLLAMA_SKIP_ROCM_GENERATE}" -a -d "${ROCM_PATH}" ]; then
...
@@ -254,7 +254,7 @@ if [ -z "${OLLAMA_SKIP_ROCM_GENERATE}" -a -d "${ROCM_PATH}" ]; then
ROCM_VARIANT
=
_v
$(
ls
${
ROCM_PATH
}
/lib/librocblas.so.
*
.
*
.????? |
cut
-f5
-d
.
||
true
)
ROCM_VARIANT
=
_v
$(
ls
${
ROCM_PATH
}
/lib/librocblas.so.
*
.
*
.????? |
cut
-f5
-d
.
||
true
)
fi
fi
init_vars
init_vars
CMAKE_DEFS
=
"
${
COMMON_CMAKE_DEFS
}
${
CMAKE_DEFS
}
-DGGML_HIPBLAS=on -DCMAKE_C_COMPILER=
$ROCM_PATH
/llvm/bin/clang -DCMAKE_CXX_COMPILER=
$ROCM_PATH
/llvm/bin/clang++ -DAMDGPU_TARGETS=
$(
amdGPUs
)
-DGPU_TARGETS=
$(
amdGPUs
)
"
CMAKE_DEFS
=
"
${
COMMON_CMAKE_DEFS
}
${
CMAKE_DEFS
}
-DGGML_HIPBLAS=on
-DLLAMA_CUDA_NO_PEER_COPY=on
-DCMAKE_C_COMPILER=
$ROCM_PATH
/llvm/bin/clang -DCMAKE_CXX_COMPILER=
$ROCM_PATH
/llvm/bin/clang++ -DAMDGPU_TARGETS=
$(
amdGPUs
)
-DGPU_TARGETS=
$(
amdGPUs
)
"
# Users building from source can tune the exact flags we pass to cmake for configuring llama.cpp
# Users building from source can tune the exact flags we pass to cmake for configuring llama.cpp
if
[
-n
"
${
OLLAMA_CUSTOM_ROCM_DEFS
}
"
]
;
then
if
[
-n
"
${
OLLAMA_CUSTOM_ROCM_DEFS
}
"
]
;
then
echo
"OLLAMA_CUSTOM_ROCM_DEFS=
\"
${
OLLAMA_CUSTOM_ROCM_DEFS
}
\"
"
echo
"OLLAMA_CUSTOM_ROCM_DEFS=
\"
${
OLLAMA_CUSTOM_ROCM_DEFS
}
\"
"
...
...
llm/generate/gen_windows.ps1
View file @
2d1e3c32
...
@@ -366,6 +366,7 @@ function build_rocm() {
...
@@ -366,6 +366,7 @@ function build_rocm() {
"-DCMAKE_C_COMPILER=clang.exe"
,
"-DCMAKE_C_COMPILER=clang.exe"
,
"-DCMAKE_CXX_COMPILER=clang++.exe"
,
"-DCMAKE_CXX_COMPILER=clang++.exe"
,
"-DGGML_HIPBLAS=on"
,
"-DGGML_HIPBLAS=on"
,
"-DLLAMA_CUDA_NO_PEER_COPY=on"
,
"-DHIP_PLATFORM=amd"
,
"-DHIP_PLATFORM=amd"
,
"-DGGML_AVX=on"
,
"-DGGML_AVX=on"
,
"-DGGML_AVX2=off"
,
"-DGGML_AVX2=off"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment