@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 66d1cc0c77
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 4, 06:15 UTC

fix(rocm): remove workaround causing invalid argument on Qwen3.5 with TP=2 (#40686)

Co-authored-by: Test User <test@example.com> Co-authored-by: TJian <tunjian.tan@embeddedllm.com>

Zhaodong Bing committed May 6, 2026 at 16:38 UTC 66d1cc0c77628e36df8e5e245c116e6aac3045fb
1 file changed -22
csrc/cumem_allocator.cpp
-22
@@ -232,28 +232,6 @@ void unmap_and_release(unsigned long long device, ssize_t size,
232 }
233 }
234
235 - // ROCm workaround: hipMemRelease does not return physical VRAM to the
236 - // free pool while the virtual-address reservation is still held.
237 - // Cycling cuMemAddressFree → cuMemAddressReserve (at the same address)
238 - // forces the driver to actually release the physical pages while keeping
239 - // the same VA available for a later create_and_map.
240 - if (first_error == no_error) {
241 - first_error = cuMemAddressFree(d_mem, size);
242 - if (first_error == no_error) {
243 - CUdeviceptr d_mem_new = 0;
244 - first_error = cuMemAddressReserve(&d_mem_new, size, 0, d_mem, 0);
245 - if (first_error == no_error && d_mem_new != d_mem) {
246 - cuMemAddressFree(d_mem_new, size);
247 - snprintf(error_msg, sizeof(error_msg),
248 - "ROCm: VA re-reserve got %p instead of %p", (void*)d_mem_new,
249 - (void*)d_mem);
250 - error_code = CUresult(1);
251 - std::cerr << error_msg << std::endl;
252 - return;
253 - }
254 - }
255 - }
256 -
235 if (first_error != no_error) {
236 CUDA_CHECK(first_error);
237 }