From e4896855096f90d5a22fca5d91f17499309a0609 Mon Sep 17 00:00:00 2001 From: Polisetty V R K Jyothendra Varma Date: Tue, 14 Jul 2026 06:50:50 +0530 Subject: [PATCH] [Intel GPU] DeepSeek V4 5/N: Use sgl-kernel implementation of fused_q_indexer_rope_hadamard_quant to run on XPU (#27873) Signed-off-by: P V R K Jyothendra Varma --- python/sglang/jit_kernel/dsv4/elementwise.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/python/sglang/jit_kernel/dsv4/elementwise.py b/python/sglang/jit_kernel/dsv4/elementwise.py index 8d17917b6..445d72eb3 100644 --- a/python/sglang/jit_kernel/dsv4/elementwise.py +++ b/python/sglang/jit_kernel/dsv4/elementwise.py @@ -171,6 +171,18 @@ def fused_q_indexer_rope_hadamard_quant( freqs_real, positions, ) + elif _is_xpu: + from sgl_kernel import fused_q_indexer_rope_hadamard_quant + + fused_q_indexer_rope_hadamard_quant( + q_input, + q_fp8, + weight, + weights_out, + float(weight_scale), + freqs_real, + positions, + ) else: module = _jit_main_q_indexer_rope_hadamard_quant_module(q_input.dtype) module.forward(