[ROCm][Spec] Route NGRAM tree reconstruction to the JIT kernel on HIP (#43328)
Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Thomas Wang <thomawan@amd.com>
This commit is contained in:
co-authored by
Cursor
Thomas Wang
parent
17c3b259f5
commit
603a05e6c0
@@ -31,7 +31,7 @@ from sglang.srt.speculative.spec_utils import (
|
||||
prepare_mamba_track_for_verify,
|
||||
record_stream_for_v2_verify,
|
||||
)
|
||||
from sglang.srt.utils import is_cpu, is_cuda, is_xpu
|
||||
from sglang.srt.utils import is_cpu, is_cuda, is_hip, is_xpu
|
||||
from sglang.srt.utils.async_probe import maybe_detect_inf, maybe_detect_nan
|
||||
|
||||
_is_cpu = is_cpu()
|
||||
@@ -40,7 +40,7 @@ if is_xpu():
|
||||
from sglang.kernels.ops.speculative.reconstruct_tree import (
|
||||
reconstruct_indices_from_tree_mask_triton as reconstruct_indices_from_tree_mask,
|
||||
)
|
||||
elif is_cuda():
|
||||
elif is_cuda() or is_hip():
|
||||
from sglang.kernels.ops.speculative.tree import reconstruct_indices_from_tree_mask
|
||||
else:
|
||||
from sgl_kernel.speculative import reconstruct_indices_from_tree_mask
|
||||
|
||||
Reference in New Issue
Block a user