[Bug]: Duration-limited benchmark crashes when no request completes

Đang mở
#23,250 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

@JunkaiWang-TheoPhy đang làm issue này rồi.

Từ ngày 2/12/2026.

  • #23251 của @JunkaiWang-TheoPhy — đang mở

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
python
Lĩnh vực
performance

Hướng nghiên cứu

Start with the trtllm-bench throughput worker and StatsKeeper.generate_statistics_summary, then trace how the worker handles a duration deadline when no request completes. Reproduce with the two-turn JSONL example and a deadline before the second turn; done when the run reports that no requests completed without computing statistics from an empty sample, while runs with completed requests still report those requests.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Inference runtime
System Info

TensorRT-LLM main at ef375f87565b89a5818e705c735ec59a182efb86. Reproduced on Python 3.12 / macOS ARM64 with real benchmark worker and statistics code, a controlled clock, and mocked LLM, tokenizer, and energy collection. No GPU inference or model downloads were needed.

Reproduction

Use a duration-limited trtllm-bench throughput run with one multi-turn request and choose a duration shorter than the time needed to reach the second turn. For example, a single two-turn JSONL record can use:

{"task_id":0,"input_ids":[1,2],"output_tokens":8,"turns":["First question","Follow-up question"]}

In the CPU reproducer, the first completion moves the clock to the one-second deadline. The real worker correctly discards the now-incomplete conversation, and no response reaches the statistics. Calling StatsKeeper().generate_statistics_summary(0, 1) reproduces the downstream division by zero.

Expected behavior

A run with no completed requests should stop with a message indicating that the deadline prevented any request from completing. Statistics should not be computed from the empty sample.

Actual behavior

The worker logs that it processed 0/1 requests, logs that the benchmark is complete, and returns empty statistics. Report generation then fails with ZeroDivisionError: division by zero.

Additional notes

The valid case where at least one request finishes should continue reporting only the completed requests. Searches for trtllm-bench, ZeroDivisionError, and a deadline with no completed requests did not identify an equivalent fix. #22049 is about no-output serving streams, which follows a different path.

OpenAI Codex assisted with reproducing the failure.

Ngôn ngữ chính
Python
Star
15.2k
Fork
3k
Merge trung bình
2 ngày 21 giờ
Pull request đã merge (30 ngày)
477

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của NVIDIA/TensorRT-LLM

Tất cả issue của NVIDIA/TensorRT-LLM

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.