llama.cpp/ggml/src
Chenguang Li 2241453252
CANN: add support for ACL Graph (#15065)
* feat(cann): add optional support for ACL Graph execution

This commit adds support for executing ggml computational graphs using
Huawei's ACL graph mode via the USE_CANN_GRAPH flag. The support can be
enabled at compile time using the CMake option:

    -DUSE_CANN_GRAPH=ON

By default, ACL graph execution is **disabled**, and the fallback path
uses node-by-node execution.

Key additions:
- CMake option  to toggle graph mode
- Graph capture and execution logic using
- Tensor property matching to determine whether graph update is required
- Safe fallback and logging if the environment variable LLAMA_SET_ROWS
  is unset or invalid

This prepares the backend for performance improvements in repetitive graph
execution scenarios on Ascend devices.

Signed-off-by: noemotiovon <757486878@qq.com>

* Fix review comments

Signed-off-by: noemotiovon <757486878@qq.com>

* remane USE_CANN_GRAPH to USE_ACL_GRAPH

Signed-off-by: noemotiovon <757486878@qq.com>

* fix typo

Signed-off-by: noemotiovon <757486878@qq.com>

---------

Signed-off-by: noemotiovon <757486878@qq.com>
2025-08-06 14:12:42 +08:00
..
ggml-blas cmake : Fix broken CMake error messages (ggml/1252) 2025-06-01 13:43:57 +03:00
ggml-cann CANN: add support for ACL Graph (#15065) 2025-08-06 14:12:42 +08:00
ggml-cpu llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-cuda llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-hip HIP: add GGML_HIP_MMQ_MFMA option to allow disableing the MFMA path. (#14930) 2025-07-29 17:44:30 +02:00
ggml-metal llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-musa musa: upgrade musa sdk to rc4.2.0 (#14498) 2025-07-24 20:05:37 +01:00
ggml-opencl llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-rpc rpc : check for null buffers in get/set/copy tensor endpoints (#14868) 2025-07-25 12:17:02 +02:00
ggml-sycl llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-vulkan llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-webgpu ggml: WebGPU disable SET_ROWS for now (#15078) 2025-08-05 16:26:38 -07:00
CMakeLists.txt cmake: Add GGML_BACKEND_DIR option (#15074) 2025-08-04 21:29:14 +02:00
ggml-alloc.c llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-backend-impl.h ggml : upgrade init_tensor API to return a ggml_status (#11854) 2025-02-28 14:41:47 +01:00
ggml-backend-reg.cpp cmake: Add GGML_BACKEND_DIR option (#15074) 2025-08-04 21:29:14 +02:00
ggml-backend.cpp sched : fix multiple evaluations of the same graph with pipeline parallelism (#14855) 2025-07-25 11:07:26 +03:00
ggml-common.h llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-impl.h llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-opt.cpp mnist: fix segmentation fault (ggml/1227) 2025-05-19 13:29:56 +03:00
ggml-quants.c llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-quants.h llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml-threading.cpp ggml : build backends as libraries (#10256) 2024-11-14 18:04:35 +01:00
ggml-threading.h remove CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS (#10797) 2024-12-12 19:02:49 +01:00
ggml.c llama : add gpt-oss (#15091) 2025-08-05 22:10:36 +03:00
ggml.cpp ggml : Print backtrace on uncaught C++ exceptions (ggml/1232) 2025-06-01 13:43:57 +03:00
gguf.cpp ggml : prevent integer overflow in gguf tensor size calculation (#14595) 2025-07-09 14:33:53 +02:00