[Core] GC Debug callback (#24829)

Signed-off-by: Jialin Ouyang <jialino@meta.com>
Signed-off-by: Jialin Ouyang <Jialin.Ouyang@gmail.com>
Co-authored-by: Jialin Ouyang <jialino@meta.com>
This commit is contained in:
Jialin Ouyang
2025-09-27 10:53:31 -07:00
committed by GitHub
parent 5546acb463
commit c216119d64
5 changed files with 217 additions and 0 deletions

View File

@@ -29,6 +29,7 @@ from vllm.transformers_utils.config import (
maybe_register_config_serialize_by_value)
from vllm.utils import (decorate_logs, get_hash_fn_by_name, make_zmq_socket,
resolve_obj_by_qualname, set_process_title)
from vllm.utils.gc_utils import maybe_attach_gc_debug_callback
from vllm.v1.core.kv_cache_utils import (BlockHash,
generate_scheduler_kv_cache_config,
get_kv_cache_configs,
@@ -532,6 +533,9 @@ class EngineCoreProc(EngineCore):
gc.collect()
gc.freeze()
# If enable, attach GC debugger after static variable freeze.
maybe_attach_gc_debug_callback()
@contextmanager
def _perform_handshakes(
self,