llama : fix order of parameters (#8706)

usage of `aclrtGetMemInfo` is correct:

https://www.hiascend.com/doc_center/source/zh/canncommercial/63RC2/inferapplicationdev/aclcppdevg/aclcppdevg_03_0103.html

Co-authored-by: Judd <foldl@boxvest.com>
This commit is contained in:
Judd 2024-07-26 16:38:12 +08:00 committed by GitHub
parent 01aec4a631
commit 01245f5b16
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2905,7 +2905,7 @@ static size_t llama_get_device_memory(const llama_model & model, int device) {
#elif defined(GGML_USE_CANN)
size_t total;
size_t free;
ggml_backend_cann_get_device_memory(device, &total, &free);
ggml_backend_cann_get_device_memory(device, &free, &total);
return free;
#else
return 1;