Skip to content

Commit 95425be

Browse files
Clement-Wang26Super User
authored andcommitted
feat:use shared memory for intra-process communication instead of BRPC
1 parent fcec9c9 commit 95425be

30 files changed

+2304
-547
lines changed

xllm/core/common/global_flags.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,13 @@ DEFINE_int32(sleep_time_second,
275275
3,
276276
"The sleep time for worker try to connect to server next time.");
277277

278+
DEFINE_bool(is_local,
279+
false,
280+
"whether the worker and master are on the same machine.");
281+
282+
DEFINE_bool(enable_shm,
283+
true,
284+
"Whether to enable shared memory for executing model.");
278285
// --- function call config ---
279286

280287
DEFINE_string(tool_call_parser,

xllm/core/common/global_flags.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,4 +199,8 @@ DECLARE_int64(cache_size_per_token);
199199

200200
DECLARE_int64(buffer_size_per_seq);
201201

202-
DECLARE_bool(enable_beam_search_kernel);
202+
DECLARE_bool(enable_beam_search_kernel);
203+
204+
DECLARE_bool(is_local);
205+
206+
DECLARE_bool(enable_shm);

xllm/core/distributed_runtime/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ cc_library(
2020
remote_worker.h
2121
worker_server.h
2222
worker_service.h
23+
comm_channel.h
24+
shm_channel.h
2325
SRCS
2426
disagg_pd_service.cpp
2527
disagg_pd_service_impl.cpp
@@ -29,6 +31,8 @@ cc_library(
2931
remote_worker.cpp
3032
worker_server.cpp
3133
worker_service.cpp
34+
comm_channel.cpp
35+
shm_channel.cpp
3236
DEPS
3337
:api_service
3438
:runtime

0 commit comments

Comments
 (0)