github ggml-org/llama.cpp b12819

latest releases: b12823, b12822, b12821...
pre-release3 hours ago
Details

CUDA: cache the device type at init (#33142)

  • CUDA: cache the device type at init

ggml_backend_cuda_device_get_type called cudaGetDeviceProperties on every
call, which takes ~0.7-1 ms with the CUDA 12 runtime. With tensor
overrides on multiple GPUs the scheduler queries the device type for every
split input, so this ran dozens of times per token.

Store the device type in ggml_cuda_device_info at init. It is derived from
prop.integrated, not from the integrated flag, which is forced off (#15034).

Ref #33132


Co-authored-by: Johannes Gäßler johannesg@5d6.de

Website:

Attestations:

macOS/iOS:

Linux:

Android:

Windows:

openEuler:

  • DISABLED
  • openEuler x86 (310p)
  • openEuler x86 (910b, ACL Graph)
  • openEuler aarch64 (310p)
  • openEuler aarch64 (910b, ACL Graph)

UI:

Don't miss a new llama.cpp release

NewReleases is sending notifications on new releases.