vllm - ✅(Solved) Fix [Bug]: OffloadingConnector GPU->CPU KV offload crashes with cuMemcpyBatchAsync failed at index 1 (error 1 / CUDA_ERROR_INVALID_VALUE) [1 pull requests, 4 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
vllm-project/vllm#39491Fetched 2026-04-11 06:13:18
View on GitHub
Comments
4
Participants
3
Timeline
7
Reactions
0
Timeline (top)
commented ×4subscribed ×2labeled ×1

Error Message

-> cuMemcpyBatchAsync failed at index 1 with error 1

  • RuntimeError: cuMemcpyBatchAsync failed at index 1 with error 1

Fix Action

Fix / Workaround

============================== CPU Info

Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Address sizes: 46 bits physical, 57 bits virtual Byte Order: Little Endian CPU(s): 192 On-line CPU(s) list: 0-191 Vendor ID: GenuineIntel Model name: INTEL(R) XEON(R) PLATINUM 8568Y+ CPU family: 6 Model: 207 Thread(s) per core: 2 Core(s) per socket: 48 Socket(s): 2 Stepping: 2 CPU(s) scaling MHz: 34% CPU max MHz: 4000.0000 CPU min MHz: 800.0000 BogoMIPS: 4600.00 Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cat_l2 cdp_l3 intel_ppin cdp_l2 ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb intel_pt avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local split_lock_detect user_shstk avx_vnni avx512_bf16 wbnoinvd dtherm ida arat pln pts hfi vnmi avx512vbmi umip pku ospke waitpkg avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg tme avx512_vpopcntdq la57 rdpid bus_lock_detect cldemote movdiri movdir64b enqcmd fsrm md_clear serialize tsxldtrk pconfig arch_lbr ibt amx_bf16 avx512_fp16 amx_tile amx_int8 flush_l1d arch_capabilities ibpb_exit_to_user Virtualization: VT-x L1d cache: 4.5 MiB (96 instances) L1i cache: 3 MiB (96 instances) L2 cache: 192 MiB (96 instances) L3 cache: 600 MiB (2 instances) NUMA node(s): 2 NUMA node0 CPU(s): 0-47,96-143 NUMA node1 CPU(s): 48-95,144-191 Vulnerability Gather data sampling: Not affected Vulnerability Indirect target selection: Not affected Vulnerability Itlb multihit: Not affected Vulnerability L1tf: Not affected Vulnerability Mds: Not affected Vulnerability Meltdown: Not affected Vulnerability Mmio stale data: Not affected Vulnerability Reg file data sampling: Not affected Vulnerability Retbleed: Not affected Vulnerability Spec rstack overflow: Not affected Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl Vulnerability Spectre v1: Mitigation; usercopy/swapgs barriers and __user pointer sanitization Vulnerability Spectre v2: Mitigation; Enhanced / Automatic IBRS; IBPB conditional; PBRSB-eIBRS SW sequence; BHI BHI_DIS_S Vulnerability Srbds: Not affected Vulnerability Tsa: Not affected Vulnerability Tsx async abort: Not affected Vulnerability Vmscape: Mitigation; IBPB before exit to userspace

PR fix notes

PR #1: [Bugfix] Reject empty KV cache tensors in CPU offloading path (fixes #39491)

Description (problem / solution / changelog)

(No description)

Changed files

  • .buildkite/ci_config.yaml (modified, +2/-2)
  • .buildkite/ci_config_intel.yaml (added, +23/-0)
  • .buildkite/hardware_tests/amd.yaml (modified, +0/-8)
  • .buildkite/hardware_tests/cpu.yaml (modified, +4/-8)
  • .buildkite/image_build/image_build_xpu.sh (added, +34/-0)
  • .buildkite/intel_jobs/test-intel.yaml (added, +65/-0)
  • .buildkite/lm-eval-harness/configs/Meta-Llama-4-Maverick-17B-128E-Instruct-FP8.yaml (modified, +3/-0)
  • .buildkite/lm-eval-harness/configs/Qwen2.5-VL-3B-Instruct-FP8-dynamic.yaml (modified, +3/-0)
  • .buildkite/lm-eval-harness/configs/Qwen3-235B-A22B-Instruct-2507-FP8.yaml (modified, +3/-0)
  • .buildkite/lm-eval-harness/configs/SparseLlama3.1_2of4_fp8_compressed.yaml (removed, +0/-12)
  • .buildkite/lm-eval-harness/configs/models-large-rocm-fp8.txt (added, +1/-0)
  • .buildkite/lm-eval-harness/configs/models-small-rocm.txt (modified, +1/-0)
  • .buildkite/lm-eval-harness/test_lm_eval_correctness.py (modified, +32/-0)
  • .buildkite/performance-benchmarks/tests/serving-tests-arm64-cpu.json (modified, +2/-1)
  • .buildkite/performance-benchmarks/tests/serving-tests-cpu-asr.json (modified, +1/-0)
  • .buildkite/performance-benchmarks/tests/serving-tests-cpu-text.json (modified, +1/-0)
  • .buildkite/performance-benchmarks/tests/serving-tests-cpu.json (modified, +1/-0)
  • .buildkite/performance-benchmarks/tests/serving-tests-hpu.json (modified, +6/-0)
  • .buildkite/performance-benchmarks/tests/serving-tests.json (modified, +4/-0)
  • .buildkite/release-pipeline.yaml (modified, +229/-244)
  • .buildkite/scripts/annotate-release.sh (modified, +4/-2)
  • .buildkite/scripts/annotate-rocm-release.sh (modified, +6/-5)
  • .buildkite/scripts/cache-rocm-base-wheels.sh (modified, +7/-16)
  • .buildkite/scripts/check-ray-compatibility.sh (modified, +23/-1)
  • .buildkite/scripts/cleanup-nightly-builds.sh (modified, +10/-7)
  • .buildkite/scripts/generate-and-upload-nightly-index.sh (added, +84/-0)
  • .buildkite/scripts/hardware_ci/run-amd-test.sh (modified, +10/-30)
  • .buildkite/scripts/hardware_ci/run-cpu-distributed-smoke-test.sh (modified, +21/-20)
  • .buildkite/scripts/hardware_ci/run-cpu-test-arm.sh (modified, +7/-2)
  • .buildkite/scripts/hardware_ci/run-hpu-test.sh (modified, +1/-1)
  • .buildkite/scripts/hardware_ci/run-intel-test.sh (added, +292/-0)
  • .buildkite/scripts/hardware_ci/run-tpu-v1-test-part2.sh (modified, +1/-1)
  • .buildkite/scripts/hardware_ci/run-xpu-test.sh (modified, +4/-4)
  • .buildkite/scripts/push-nightly-builds-rocm.sh (added, +62/-0)
  • .buildkite/scripts/scheduled_integration_test/deepseek_v2_lite_prefetch_offload.sh (modified, +14/-2)
  • .buildkite/scripts/upload-nightly-wheels.sh (modified, +4/-65)
  • .buildkite/test-amd.yaml (modified, +2301/-3357)
  • .buildkite/test_areas/basic_correctness.yaml (modified, +1/-0)
  • .buildkite/test_areas/benchmarks.yaml (modified, +1/-8)
  • .buildkite/test_areas/compile.yaml (modified, +3/-1)
  • .buildkite/test_areas/cuda.yaml (modified, +1/-0)
  • .buildkite/test_areas/distributed.yaml (modified, +114/-30)
  • .buildkite/test_areas/engine.yaml (modified, +14/-0)
  • .buildkite/test_areas/entrypoints.yaml (modified, +36/-19)
  • .buildkite/test_areas/expert_parallelism.yaml (modified, +6/-4)
  • .buildkite/test_areas/kernels.yaml (modified, +63/-5)
  • .buildkite/test_areas/lm_eval.yaml (modified, +17/-0)
  • .buildkite/test_areas/lora.yaml (modified, +3/-2)
  • .buildkite/test_areas/misc.yaml (modified, +70/-13)
  • .buildkite/test_areas/model_executor.yaml (modified, +1/-1)
  • .buildkite/test_areas/model_runner_v2.yaml (modified, +8/-6)
  • .buildkite/test_areas/models_basic.yaml (modified, +2/-1)
  • .buildkite/test_areas/models_distributed.yaml (modified, +3/-2)
  • .buildkite/test_areas/models_language.yaml (modified, +4/-2)
  • .buildkite/test_areas/models_multimodal.yaml (modified, +25/-10)
  • .buildkite/test_areas/pytorch.yaml (modified, +15/-3)
  • .buildkite/test_areas/quantization.yaml (modified, +3/-3)
  • .buildkite/test_areas/ray_compat.yaml (modified, +1/-0)
  • .buildkite/test_areas/spec_decode.yaml (modified, +4/-0)
  • .github/CODEOWNERS (modified, +29/-15)
  • .github/mergify.yml (modified, +65/-12)
  • .github/scripts/cleanup_pr_body.sh (removed, +0/-50)
  • .github/workflows/cleanup_pr_body.yml (removed, +0/-32)
  • .github/workflows/issue_autolabel.yml (modified, +113/-5)
  • .github/workflows/macos-smoke-test.yml (modified, +4/-4)
  • .github/workflows/new_pr_bot.yml (added, +102/-0)
  • .github/workflows/pre-commit.yml (modified, +41/-0)
  • .github/workflows/reminder_comment.yml (removed, +0/-54)
  • .github/workflows/scripts/build.sh (modified, +1/-1)
  • .gitignore (modified, +5/-1)
  • .pre-commit-config.yaml (modified, +95/-5)
  • AGENTS.md (modified, +29/-15)
  • CMakeLists.txt (modified, +331/-297)
  • README.md (modified, +26/-19)
  • benchmarks/attention_benchmarks/benchmark.py (modified, +2/-8)
  • benchmarks/benchmark_long_document_qa_throughput.py (modified, +1/-2)
  • benchmarks/benchmark_prefix_caching.py (modified, +1/-1)
  • benchmarks/benchmark_prioritization.py (modified, +1/-2)
  • benchmarks/cutlass_benchmarks/sparse_benchmarks.py (removed, +0/-517)
  • benchmarks/cutlass_benchmarks/utils.py (modified, +0/-48)
  • benchmarks/fused_kernels/merge_attn_states_benchmarks.py (added, +264/-0)
  • benchmarks/fused_kernels/silu_mul_block_quant_benchmark.py (added, +211/-0)
  • benchmarks/kernels/benchmark_block_fp8_gemm.py (modified, +12/-7)
  • benchmarks/kernels/benchmark_fused_collective.py (modified, +19/-7)
  • benchmarks/kernels/benchmark_moe.py (modified, +35/-12)
  • benchmarks/kernels/benchmark_moe_align_block_size.py (modified, +2/-1)
  • benchmarks/kernels/benchmark_silu_mul_fp8_quant.py (modified, +1/-1)
  • benchmarks/kernels/benchmark_vit_bilinear_pos_embed.py (added, +162/-0)
  • benchmarks/kernels/cpu/benchmark_cpu_attn.py (modified, +1/-1)
  • benchmarks/kernels/cpu/benchmark_cpu_fused_moe.py (modified, +1/-1)
  • benchmarks/kernels/deepgemm/benchmark_fp8_block_dense_gemm.py (modified, +2/-3)
  • benchmarks/multi_turn/benchmark_serving_multi_turn.py (modified, +19/-0)
  • cmake/cpu_extension.cmake (modified, +4/-0)
  • cmake/external_projects/deepgemm.cmake (added, +151/-0)
  • cmake/external_projects/qutlass.cmake (modified, +4/-4)
  • cmake/external_projects/vllm_flash_attn.cmake (modified, +28/-16)
  • cmake/utils.cmake (modified, +41/-4)
  • csrc/async_util.cuh (added, +100/-0)
  • csrc/attention/dtype_fp8.cuh (modified, +16/-0)
  • csrc/attention/merge_attn_states.cu (modified, +164/-43)
RAW_BUFFERClick to expand / collapse

Your current environment

Collecting environment information...

    System Info

============================== OS : Ubuntu 24.04.3 LTS (x86_64) GCC version : (Ubuntu 13.3.0-6ubuntu2~24.04.1) 13.3.0 Clang version : Could not collect CMake version : version 3.28.3 Libc version : glibc-2.39

============================== PyTorch Info

PyTorch version : 2.11.0+cu130 Is debug build : False CUDA used to build PyTorch : 13.0 ROCM used to build PyTorch : N/A

============================== Python Environment

Python version : 3.12.3 (main, Mar 3 2026, 12:15:18) [GCC 13.3.0] (64-bit runtime) Python platform : Linux-6.8.0-106-generic-x86_64-with-glibc2.39

============================== CUDA / GPU Info

Is CUDA available : True CUDA runtime version : 12.9.86 CUDA_MODULE_LOADING set to : GPU models and configuration : GPU 0: NVIDIA H200 GPU 1: NVIDIA H200 GPU 2: NVIDIA H200 GPU 3: NVIDIA H200 GPU 4: NVIDIA H200 GPU 5: NVIDIA H200 GPU 6: NVIDIA H200 GPU 7: NVIDIA H200

Nvidia driver version : 595.58.03 cuDNN version : Could not collect HIP runtime version : N/A MIOpen runtime version : N/A Is XNNPACK available : True

============================== CPU Info

Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Address sizes: 46 bits physical, 57 bits virtual Byte Order: Little Endian CPU(s): 192 On-line CPU(s) list: 0-191 Vendor ID: GenuineIntel Model name: INTEL(R) XEON(R) PLATINUM 8568Y+ CPU family: 6 Model: 207 Thread(s) per core: 2 Core(s) per socket: 48 Socket(s): 2 Stepping: 2 CPU(s) scaling MHz: 34% CPU max MHz: 4000.0000 CPU min MHz: 800.0000 BogoMIPS: 4600.00 Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cat_l2 cdp_l3 intel_ppin cdp_l2 ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb intel_pt avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local split_lock_detect user_shstk avx_vnni avx512_bf16 wbnoinvd dtherm ida arat pln pts hfi vnmi avx512vbmi umip pku ospke waitpkg avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg tme avx512_vpopcntdq la57 rdpid bus_lock_detect cldemote movdiri movdir64b enqcmd fsrm md_clear serialize tsxldtrk pconfig arch_lbr ibt amx_bf16 avx512_fp16 amx_tile amx_int8 flush_l1d arch_capabilities ibpb_exit_to_user Virtualization: VT-x L1d cache: 4.5 MiB (96 instances) L1i cache: 3 MiB (96 instances) L2 cache: 192 MiB (96 instances) L3 cache: 600 MiB (2 instances) NUMA node(s): 2 NUMA node0 CPU(s): 0-47,96-143 NUMA node1 CPU(s): 48-95,144-191 Vulnerability Gather data sampling: Not affected Vulnerability Indirect target selection: Not affected Vulnerability Itlb multihit: Not affected Vulnerability L1tf: Not affected Vulnerability Mds: Not affected Vulnerability Meltdown: Not affected Vulnerability Mmio stale data: Not affected Vulnerability Reg file data sampling: Not affected Vulnerability Retbleed: Not affected Vulnerability Spec rstack overflow: Not affected Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl Vulnerability Spectre v1: Mitigation; usercopy/swapgs barriers and __user pointer sanitization Vulnerability Spectre v2: Mitigation; Enhanced / Automatic IBRS; IBPB conditional; PBRSB-eIBRS SW sequence; BHI BHI_DIS_S Vulnerability Srbds: Not affected Vulnerability Tsa: Not affected Vulnerability Tsx async abort: Not affected Vulnerability Vmscape: Mitigation; IBPB before exit to userspace

============================== Versions of relevant libraries

[pip3] flashinfer-python==0.6.7 [pip3] numpy==2.4.4 [pip3] nvidia-cublas==13.1.0.3 [pip3] nvidia-cuda-cupti==13.0.85 [pip3] nvidia-cuda-nvrtc==13.0.88 [pip3] nvidia-cuda-runtime==13.0.96 [pip3] nvidia-cudnn-cu13==9.19.0.56 [pip3] nvidia-cudnn-frontend==1.18.0 [pip3] nvidia-cufft==12.0.0.61 [pip3] nvidia-cufile==1.15.1.6 [pip3] nvidia-curand==10.4.0.35 [pip3] nvidia-cusolver==12.0.4.66 [pip3] nvidia-cusparse==12.6.3.3 [pip3] nvidia-cusparselt-cu13==0.8.0 [pip3] nvidia-cutlass-dsl==4.4.2 [pip3] nvidia-cutlass-dsl-libs-base==4.4.2 [pip3] nvidia-ml-py==13.595.45 [pip3] nvidia-nccl-cu13==2.28.9 [pip3] nvidia-nvjitlink==13.0.88 [pip3] nvidia-nvshmem-cu13==3.4.5 [pip3] nvidia-nvtx==13.0.85 [pip3] pyzmq==27.1.0 [pip3] torch==2.11.0 [pip3] torch_c_dlpack_ext==0.1.5 [pip3] torchaudio==2.11.0 [pip3] torchvision==0.26.0 [pip3] transformers==5.5.3 [pip3] triton==3.6.0 [conda] Could not collect

============================== vLLM Info

ROCM Version : Could not collect vLLM Version : 0.19.1rc1.dev96+g2488d1dca.d20260408 (git sha: 2488d1dca, date: 20260408) vLLM Build Flags: CUDA Archs: Not Set; ROCm: Disabled GPU Topology: GPU0 GPU1 GPU2 GPU3 GPU4 GPU5 GPU6 GPU7 NIC0 NIC1 NIC2 NIC3 NIC4 NIC5 NIC6 NIC7 NIC8 CPU Affinity NUMA Affinity GPU NUMA ID GPU0 X NV18 NV18 NV18 NV18 NV18 NV18 NV18 PIX NODE NODE NODE SYS SYS SYS SYS SYS 0-47,96-143 0 N/A GPU1 NV18 X NV18 NV18 NV18 NV18 NV18 NV18 NODE PIX NODE NODE SYS SYS SYS SYS SYS 0-47,96-143 0 N/A GPU2 NV18 NV18 X NV18 NV18 NV18 NV18 NV18 NODE NODE PIX NODE SYS SYS SYS SYS SYS 0-47,96-143 0 N/A GPU3 NV18 NV18 NV18 X NV18 NV18 NV18 NV18 NODE NODE NODE PIX SYS SYS SYS SYS SYS 0-47,96-143 0 N/A GPU4 NV18 NV18 NV18 NV18 X NV18 NV18 NV18 SYS SYS SYS SYS PIX NODE NODE NODE NODE 48-95,144-191 1 N/A GPU5 NV18 NV18 NV18 NV18 NV18 X NV18 NV18 SYS SYS SYS SYS NODE PIX NODE NODE NODE 48-95,144-191 1 N/A GPU6 NV18 NV18 NV18 NV18 NV18 NV18 X NV18 SYS SYS SYS SYS NODE NODE PIX NODE NODE 48-95,144-191 1 N/A GPU7 NV18 NV18 NV18 NV18 NV18 NV18 NV18 X SYS SYS SYS SYS NODE NODE NODE PIX NODE 48-95,144-191 1 N/A NIC0 PIX NODE NODE NODE SYS SYS SYS SYS X NODE NODE NODE SYS SYS SYS SYS SYS NIC1 NODE PIX NODE NODE SYS SYS SYS SYS NODE X NODE NODE SYS SYS SYS SYS SYS NIC2 NODE NODE PIX NODE SYS SYS SYS SYS NODE NODE X NODE SYS SYS SYS SYS SYS NIC3 NODE NODE NODE PIX SYS SYS SYS SYS NODE NODE NODE X SYS SYS SYS SYS SYS NIC4 SYS SYS SYS SYS PIX NODE NODE NODE SYS SYS SYS SYS X NODE NODE NODE NODE NIC5 SYS SYS SYS SYS NODE PIX NODE NODE SYS SYS SYS SYS NODE X NODE NODE NODE NIC6 SYS SYS SYS SYS NODE NODE PIX NODE SYS SYS SYS SYS NODE NODE X NODE NODE NIC7 SYS SYS SYS SYS NODE NODE NODE PIX SYS SYS SYS SYS NODE NODE NODE X NODE NIC8 SYS SYS SYS SYS NODE NODE NODE NODE SYS SYS SYS SYS NODE NODE NODE NODE X

Legend:

X = Self SYS = Connection traversing PCIe as well as the SMP interconnect between NUMA nodes (e.g., QPI/UPI) NODE = Connection traversing PCIe as well as the interconnect between PCIe Host Bridges within a NUMA node PHB = Connection traversing PCIe as well as a PCIe Host Bridge (typically the CPU) PXB = Connection traversing multiple PCIe bridges (without traversing the PCIe Host Bridge) PIX = Connection traversing at most a single PCIe bridge NV# = Connection traversing a bonded set of # NVLinks

NIC Legend:

NIC0: mlx5_0 NIC1: mlx5_1 NIC2: mlx5_2 NIC3: mlx5_3 NIC4: mlx5_4 NIC5: mlx5_5 NIC6: mlx5_6 NIC7: mlx5_7 NIC8: mlx5_bond_0

============================== Environment Variables

CUDA_HOME=/usr/local/cuda-12.9 CUDA_HOME=/usr/local/cuda-12.9 LD_LIBRARY_PATH=/data/glm-5/vllm/.venv/lib/python3.12/site-packages/cv2/../../lib64:/usr/local/cuda-12.9/lib64: PYTORCH_NVML_BASED_CUDA_CHECK=1 TORCHINDUCTOR_COMPILE_THREADS=1 TORCHINDUCTOR_CACHE_DIR=/tmp/torchinductor_ubuntu VLLM_WORKER_MULTIPROC_METHOD=spawn

🐛 Describe the bug

please see log

During generation with KV offloading enabled via OffloadingConnector, the engine crashes in the GPU->CPU KV preemption/offload path.

The failure happens in the batched copy path:

gpu_model_runner.execute_model -> get_kv_transfer_group().handle_preemptions(...) -> vllm/distributed/kv_transfer/kv_connector/v1/offloading_connector.py -> vllm/v1/kv_offload/worker/cpu_gpu.py -> swap_blocks_batch -> torch.ops._C_cache_ops.swap_blocks_batch -> cuMemcpyBatchAsync failed at index 1 with error 1

All TP workers hit the same failure and then the engine dies with:

  • RuntimeError: cuMemcpyBatchAsync failed at index 1 with error 1
  • AssertionError in vllm/distributed/kv_transfer/kv_connector/v1/offloading/worker.py:301
  • EngineDeadError

This does not look like a simple KV-capacity issue. At the time of failure, scheduler stats showed:

  • kv_cache_usage=0.008062758770974066

Relevant repeated debug lines across workers:

  • src_ids=[116] dst_ids=[113]
  • bsz=[ 8448 73728 8448 73728]

Environment where this reproduced:

  • vLLM: 0.19.1rc1.dev96+g2488d1dca.d20260408
  • Date collected: April 10, 2026
  • Model: zai-org/GLM-5.1-FP8
  • Quantization: fp8
  • dtype=torch.bfloat16
  • tensor_parallel_size=8
  • speculative decoding: mtp, num_spec_tokens=3
  • max_seq_len=202000
  • GPUs: NVIDIA H200 x8

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

extent analysis

TL;DR

The most likely fix for the crash in the GPU->CPU KV preemption/offload path is to investigate and resolve the cuMemcpyBatchAsync failure, potentially by checking CUDA versions, updating CUDA drivers, or adjusting memory allocation.

Guidance

  • Investigate the cuMemcpyBatchAsync failure at index 1 with error 1, which may indicate a CUDA-related issue.
  • Verify that the CUDA version (12.9) is compatible with the PyTorch version (2.11.0) and the NVIDIA driver version (595.58.03).
  • Check the memory allocation and usage patterns in the swap_blocks_batch function to ensure that it is not causing memory exhaustion or fragmentation.
  • Consider updating the CUDA drivers or adjusting the memory allocation settings to resolve the issue.

Example

No specific code example is provided, as the issue is related to a complex interaction between CUDA, PyTorch, and the vLLM library. However, the swap_blocks_batch function and the cuMemcpyBatchAsync call may need to be inspected and modified to resolve the issue.

Notes

The issue may be specific to the combination of hardware (NVIDIA H200 GPUs) and software (vLLM 0.19.1rc1.dev96+g2488d1dca.d20260408, PyTorch 2.11.0) used in the environment. The kv_cache_usage value of 0.008062758770974066 suggests that KV capacity is not the primary cause of the issue.

Recommendation

Apply a workaround by updating the CUDA drivers to the latest version compatible with the PyTorch version and the NVIDIA driver version, and adjust memory allocation settings as needed to resolve the cuMemcpyBatchAsync failure.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

vllm - ✅(Solved) Fix [Bug]: OffloadingConnector GPU->CPU KV offload crashes with cuMemcpyBatchAsync failed at index 1 (error 1 / CUDA_ERROR_INVALID_VALUE) [1 pull requests, 4 comments, 3 participants]