Skip to content

fix: add disable flashinfer e2e benchmark - #1032

Closed
zhyncs wants to merge 3 commits into
sgl-project:mainfrom
zhyncs:tmp
Closed

zhyncs wants to merge 3 commits into
sgl-project:mainfrom
zhyncs:tmp

Conversation

@zhyncs

@zhyncs zhyncs commented Aug 11, 2024

Copy link
Copy Markdown
Contributor

Thank you for your contribution, we really appreciate it. The following instructions will help improve your pull request and make it easier to receive feedback. If there are any items you don't understand, don't worry. Just submit the pull request and ask the maintainers for help.

Motivation

Please explain the motivation behind this PR and the goal you aim to achieve with it.

Modification

Briefly describe the changes made in this PR.

Checklist

  1. Ensure pre-commit pre-commit run --all-files or other linting tools are used to fix potential lint issues.
  2. Confirm that modifications are covered by complete unit tests. If not, please add more unit tests for correctness.
  3. Modify documentation as needed, such as docstrings or example tutorials.

@zhyncs zhyncs added the wip label Aug 11, 2024
@zhyncs

zhyncs commented Aug 11, 2024

Copy link
Copy Markdown
Contributor Author

This is a naive CI verification to discover potential illegal memory issues when disable FlashInfer is enabled. ref #981

Traceback (most recent call last):
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 223, in exposed_step
    self.forward_step()
  File "/data/zhyncs/runner-v2/venv/lib/python3.10/site-packages/torch/utils/_contextlib.py", line 116, in decorate_context
    return func(*args, **kwargs)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 252, in forward_step
    self.forward_decode_batch(self.running_batch)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 608, in forward_decode_batch
    next_token_ids = batch.sample(output.next_token_logits)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/schedule_batch.py", line 766, in sample
    if not torch.all(success):
RuntimeError: CUDA error: an illegal memory access was encountered
CUDA kernel errors might be asynchronously reported at some other API call, so the stacktrace below might be incorrect.
For debugging consider passing CUDA_LAUNCH_BLOCKING=1
Compile with `TORCH_USE_CUDA_DSA` to enable device-side assertions.


Exception in ControllerSingle:
Traceback (most recent call last):
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/controller_single.py", line 166, in start_controller_process
    controller.loop_for_forward()
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/controller_single.py", line 103, in loop_for_forward
    out_pyobjs = self.tp_server.exposed_step(recv_reqs)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 223, in exposed_step
    self.forward_step()
  File "/data/zhyncs/runner-v2/venv/lib/python3.10/site-packages/torch/utils/_contextlib.py", line 116, in decorate_context
    return func(*args, **kwargs)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 252, in forward_step
    self.forward_decode_batch(self.running_batch)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/tp_worker.py", line 608, in forward_decode_batch
    next_token_ids = batch.sample(output.next_token_logits)
  File "/data/zhyncs/runner-v2/actions-runner/_work/sglang/sglang/python/sglang/srt/managers/schedule_batch.py", line 766, in sample
    if not torch.all(success):
RuntimeError: CUDA error: an illegal memory access was encountered
CUDA kernel errors might be asynchronously reported at some other API call, so the stacktrace below might be incorrect.
For debugging consider passing CUDA_LAUNCH_BLOCKING=1
Compile with `TORCH_USE_CUDA_DSA` to enable device-side assertions.

@merrymercy

Copy link
Copy Markdown
Contributor

move to #1039

@merrymercy merrymercy closed this Aug 12, 2024
@zhyncs
zhyncs deleted the tmp branch August 12, 2024 02:21
Hide-on-bushsh pushed a commit to Hide-on-bushsh/sgl-project that referenced this pull request Jul 20, 2026
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 1, 2026
…neither idle nor a stall

1068cap (2026-09-01): 4 group flip pairs, the SAME 3-request cohort seam-
re-prefilled from zero in every TP window (442840 tok total), zero decode
batches ever built. Two arm faces of one booking blind spot -- the policy
has no notion of 're-prefilling toward decode':
(A) windows 1+4: 'pending prefill > 0 ... nothing decoding' armed ~13 s in,
    while the cohort sat queued (bundle_is_mid_flight correctly answers
    False for queued-retracted per W37-E -- but not-decoding is not
    not-owed-this-layout's-service).
(B) windows 2+3: 'decode bundle STALLED, set has not shrunk for 51.8s'
    fired at a member whose prefix was actively growing -- the progress
    clock knew only bs-shrink (:4155).

One mechanism, two sites, no new ledger:
- observe_idle: sinking seam_cohort_pending_tokens credits the bundle
  progress clock (state marker last_seam_cohort_pending, phase-entry reset).
- the purity/pending tp_to_pp arm holds while seam_cohort_dwell_active()
  (same sgl-project#1032 FIX 1 bound: lapses after SEAM_COHORT_DWELL_ROUNDS, so it can
  never hold forever); named holding line is the metal instrument.

Desk-proven by execution: clock clause truth table (sink=progress,
flat/rise=not), dwell predicate arms both ways. Metal falsifier: driver
load must reach Decode batch > 0 with flips still reconciling.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants