- 23 Apr, 2024 1 commit
-
-
Daniel Hiltgen authored
This change adds support for multiple concurrent requests, as well as loading multiple models by spawning multiple runners. The default settings are currently set at 1 concurrent request per model and only 1 loaded model at a time, but these can be adjusted by setting OLLAMA_NUM_PARALLEL and OLLAMA_MAX_LOADED_MODELS.
-
- 16 Apr, 2024 2 commits
-
-
Michael Yang authored
-
Michael Yang authored
-
- 10 Apr, 2024 1 commit
-
-
Michael Yang authored
-
- 01 Apr, 2024 6 commits
-
-
Daniel Hiltgen authored
-
Daniel Hiltgen authored
Leaving the cudart library loaded kept ~30m of memory pinned in the GPU in the main process. This change ensures we don't hold GPU resources when idle.
-
Daniel Hiltgen authored
We may have users that run into problems with our current payload model, so this gives us an escape valve.
-
Daniel Hiltgen authored
"cudart init failure: 35" isn't particularly helpful in the logs.
-
Daniel Hiltgen authored
This should resolve a number of memory leak and stability defects by allowing us to isolate llama.cpp in a separate process and shutdown when idle, and gracefully restart if it has problems. This also serves as a first step to be able to run multiple copies to support multiple models concurrently.
-
Michael Yang authored
count each layer independently when deciding gpu offloading
-
- 28 Mar, 2024 1 commit
-
-
Michael Yang authored
-
- 25 Mar, 2024 1 commit
-
-
Jeremy authored
-
- 20 Mar, 2024 1 commit
-
-
Daniel Hiltgen authored
If expanding the runners fails, don't leave a corrupt/incomplete payloads dir We now write a pid file out to the tmpdir, which allows us to scan for stale tmpdirs and remove this as long as there isn't still a process running.
-
- 12 Mar, 2024 2 commits
-
-
Daniel Hiltgen authored
This fixes a few bugs in the new sysfs discovery logic. iGPUs are now correctly identified by their <1G VRAM reported. the sysfs IDs are off by one compared to what HIP wants due to the CPU being reported in amdgpu, but HIP only cares about GPUs.
-
mofanke authored
-
- 11 Mar, 2024 1 commit
-
-
Daniel Hiltgen authored
Putting the rocm symlink next to the runners is risky. This moves the payloads into a subdir to avoid potential clashes.
-
- 10 Mar, 2024 1 commit
-
-
Daniel Hiltgen authored
This allows people who package up ollama on their own to place the rocm dependencies in a peer directory to the ollama executable much like our windows install flow.
-
- 09 Mar, 2024 2 commits
-
-
Jeffrey Morgan authored
-
Daniel Hiltgen authored
The recent ROCm change partially removed idempotent payloads, but the ggml-metal.metal file for mac was still idempotent. This finishes switching to always extract the payloads, and now that idempotentcy is gone, the version directory is no longer useful.
-
- 07 Mar, 2024 2 commits
-
-
Daniel Hiltgen authored
This refines where we extract the LLM libraries to by adding a new OLLAMA_HOME env var, that defaults to `~/.ollama` The logic was already idempotenent, so this should speed up startups after the first time a new release is deployed. It also cleans up after itself. We now build only a single ROCm version (latest major) on both windows and linux. Given the large size of ROCms tensor files, we split the dependency out. It's bundled into the installer on windows, and a separate download on windows. The linux install script is now smart and detects the presence of AMD GPUs and looks to see if rocm v6 is already present, and if not, then downloads our dependency tar file. For Linux discovery, we now use sysfs and check each GPU against what ROCm supports so we can degrade to CPU gracefully instead of having llama.cpp+rocm assert/crash on us. For Windows, we now use go's windows dynamic library loading logic to access the amdhip64.dll APIs to query the GPU information.
-
Daniel Hiltgen authored
Until we get all the memory calculations correct, this can provide and escape valve for users to workaround out of memory crashes.
-
- 29 Feb, 2024 1 commit
-
-
tylinux authored
-
- 25 Feb, 2024 1 commit
-
-
peanut256 authored
* read iogpu.wired_limit_mb on macOS Fix for https://github.com/ollama/ollama/issues/1826 * improved determination of available vram on macOS read the recommended maximal vram on macOS via Metal API * Removed macOS-specific logging * Remove logging from gpu_darwin.go * release Core Foundation object fixes a possible memory leak
-
- 17 Feb, 2024 1 commit
-
-
Daniel Hiltgen authored
It looks like the version file doesnt exist on older(?) drivers
-
- 12 Feb, 2024 1 commit
-
-
Daniel Hiltgen authored
This wires up some new logic to start using sysfs to discover AMD GPU information and detects old cards we can't yet support so we can fallback to CPU mode.
-
- 28 Jan, 2024 2 commits
-
-
Daniel Hiltgen authored
AVX is an x86 feature, so ARM should be excluded from the check.
-
Daniel Hiltgen authored
At least with the ROCm libraries, its possible to have the library present with zero GPUs. This fix avoids a divide by zero bug in llm.go when we try to calculate GPU memory with zero GPUs.
-
- 27 Jan, 2024 1 commit
-
-
Jagadish Krishnamoorthy authored
-
- 26 Jan, 2024 3 commits
-
-
Daniel Hiltgen authored
We build the GPU libraries with AVX enabled to ensure that if not all layers fit on the GPU we get better performance in a mixed mode. If the user is using a virtualization/emulation system that lacks AVX this used to result in an illegal instruction error and crash before this fix. Now we will report a warning in the server log, and just use CPU mode to ensure we don't crash.
-
Daniel Hiltgen authored
Detect and ignore integrated GPUs reported by rocm.
-
Daniel Hiltgen authored
The new driver lookup code was triggering after init failure due to a missing return
-
- 24 Jan, 2024 1 commit
-
-
Daniel Hiltgen authored
Fix an ordering glitch of dlerr/dlclose and add more logging to help root cause some crashes users are hitting. This also refines the function pointer names to use the underlying function names instead of simplified names for readability.
-
- 23 Jan, 2024 1 commit
-
-
Daniel Hiltgen authored
This adds additional calls to both CUDA and ROCm management libraries to discover additional attributes about the GPU(s) detected in the system, and wires up runtime verbosity selection. When users hit problems with GPUs we can ask them to run with `OLLAMA_DEBUG=1 ollama serve` and share the results.
-
- 20 Jan, 2024 3 commits
-
-
Daniel Hiltgen authored
-
Jeffrey Morgan authored
-
Daniel Hiltgen authored
-
- 19 Jan, 2024 2 commits
-
-
Daniel Hiltgen authored
-
Self Denial authored
Update gpu.go initGPUHandles() to declare gpuHandles variable before reading it. This resolves an "invalid memory address or nil pointer dereference" error. Update dyn_ext_server.c to avoid setting the RTLD_DEEPBIND flag under __TERMUX__ (Android).
-
- 18 Jan, 2024 1 commit
-
-
Daniel Hiltgen authored
A few obvious levels were adjusted, but generally everything mapped to "info" level.
-
- 14 Jan, 2024 1 commit
-
-
Alexander F. Rødseth authored
-