Skip to content

Commit adb3462

Browse files
committed
fix cmd order
1 parent c5861a8 commit adb3462

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

ggml/src/ggml-rpc/ggml-rpc.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,7 @@ static_assert(sizeof(rpc_tensor) % 8 == 0, "rpc_tensor size must be multiple of
9090

9191
// RPC commands
9292
enum rpc_cmd {
93-
RPC_CMD_DEVICE_COUNT = 0,
94-
RPC_CMD_ALLOC_BUFFER,
93+
RPC_CMD_ALLOC_BUFFER = 0,
9594
RPC_CMD_GET_ALIGNMENT,
9695
RPC_CMD_GET_MAX_SIZE,
9796
RPC_CMD_BUFFER_GET_BASE,
@@ -106,9 +105,12 @@ enum rpc_cmd {
106105
RPC_CMD_INIT_TENSOR,
107106
RPC_CMD_GET_ALLOC_SIZE,
108107
RPC_CMD_HELLO,
108+
RPC_CMD_DEVICE_COUNT,
109109
RPC_CMD_COUNT,
110110
};
111111

112+
static_assert(RPC_CMD_HELLO == 14, "RPC_CMD_HELLO must be always 14");
113+
112114
// Try RPC_CMD_SET_TENSOR_HASH first when data size is larger than this threshold
113115
const size_t HASH_THRESHOLD = 10 * 1024 * 1024;
114116

0 commit comments

Comments
 (0)