Skip to content

Commit bdeb358

Browse files
committed
ggml-hexagon: sync from project kantv(make ggml-hexagon backend can works in a standard Android APP)
1 parent d3229f4 commit bdeb358

File tree

4 files changed

+138
-104
lines changed

4 files changed

+138
-104
lines changed

ggml/include/ggml-hexagon.h

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023-2025 The ggml authors
2+
* Copyright (c) 2024-2025 The ggml authors
33
*
44
* Permission is hereby granted, free of charge, to any person obtaining a copy
55
* of this software and associated documentation files (the "Software"), to
@@ -28,15 +28,15 @@
2828
extern "C" {
2929
#endif
3030

31-
#define GGML_HEXAGON_MAX_DEVICES 3
31+
#define GGML_HEXAGON_MAX_DEVICES 4
3232
#define GGML_HEXAGON_BACKEND_NAME "hexagon"
3333

3434
enum HEXAGONBackend {
3535
HEXAGON_BACKEND_QNNCPU = 0,
3636
HEXAGON_BACKEND_QNNGPU = 1,
3737
HEXAGON_BACKEND_QNNNPU = 2,
38-
HEXAGON_BACKEND_CDSP = 2,
39-
HEXAGON_BACKEND_GGML = 3, //"fake" QNN backend for compare performance between HEXAGON backend and ggml backend
38+
HEXAGON_BACKEND_CDSP = 3,
39+
HEXAGON_BACKEND_GGML = 4, //"fake" HEXAGON backend for compare performance between HEXAGON backend and ggml backend
4040
};
4141

4242
GGML_BACKEND_API ggml_backend_t ggml_backend_hexagon_init(size_t dev_num, const char * qnn_lib_path);

ggml/src/ggml-hexagon/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug")
2222
message("Debug mode:${DEBUG_FLAG}")
2323
else()
2424
set(DEBUG_FLAG "-DNDEBUG -Wall")
25-
#manually disable all foreground logs in ggml-hexagon/CMakeLists.txt to
25+
#manually disable all verbose logs in ggml-hexagon/CMakeLists.txt to
2626
#make compare NPU performance through llama-bench more clear
2727
#set(DEBUG_FLAG "-DNDEBUG -Wall -DDISABLE_ALL_LOG")
2828
message("Release mode:${DEBUG_FLAG}")

0 commit comments

Comments
 (0)